コード例 #1
0
 public static void ValidateAttributes(IProjection projection)
 {
     if (projection.Attributes.Any(a => !a.Metadata.Identity.Schema.Equals(projection.Metadata.Identity.Schema)))
     {
         throw ProjectionException.FromProjection(projection, "All attributes must belong to the same projection schema.");
     }
 }
コード例 #2
0
 public static void ValidateMetadata(IProjection projection)
 {
     if (!projection.Identity.Schema.Equals(projection.Metadata.Identity.Schema))
     {
         throw ProjectionException.FromProjection(projection, "Metadata and identity must belong to the same schema.");
     }
 }
コード例 #3
0
 public static void ValidateField(IProjection projection)
 {
     if (projection.Source != null && !projection.Identity.Schema.Equals(projection.Source.Identity.Schema))
     {
         throw ProjectionException.FromProjection(projection, "Field and identity must belong to the same schema.");
     }
 }