예제 #1
0
 private static bool IsValidExtensionPoint(
     Product product,
     IEnumerable <IExtensionPointInfo> extensionPoints,
     IPatternManager patternManager)
 {
     return(extensionPoints.Any(x => patternManager.GetCandidateExtensionPoints(x.RequiredExtensionPointId)
                                .Any(f => f.Id == product.ExtensionId && f.Schema.Pattern.Id == product.DefinitionId)));
 }
예제 #2
0
 private static bool HasSingletonExtensionPointsInView(
     IGrouping <Guid, Product> group,
     IEnumerable <IExtensionPointInfo> extensionPoints,
     IPatternManager patternManager)
 {
     return(extensionPoints.Any(x =>
                                (x.Cardinality == Cardinality.OneToOne || x.Cardinality == Cardinality.ZeroToOne) &&
                                patternManager.GetCandidateExtensionPoints(x.RequiredExtensionPointId)
                                .Any(f => f.Schema.Pattern.Id == group.Key && f.Id == group.First().ExtensionId)));
 }
예제 #3
0
 private static bool HasSingletonExtensionPointsInView(
     IGrouping<Guid, Product> group,
     IEnumerable<IExtensionPointInfo> extensionPoints,
     IPatternManager patternManager)
 {
     return extensionPoints.Any(x =>
         (x.Cardinality == Cardinality.OneToOne || x.Cardinality == Cardinality.ZeroToOne) &&
         patternManager.GetCandidateExtensionPoints(x.RequiredExtensionPointId)
             .Any(f => f.Schema.Pattern.Id == group.Key && f.Id == group.First().ExtensionId));
 }
예제 #4
0
 private static bool IsValidExtensionPoint(
     Product product,
     IEnumerable<IExtensionPointInfo> extensionPoints,
     IPatternManager patternManager)
 {
     return extensionPoints.Any(x => patternManager.GetCandidateExtensionPoints(x.RequiredExtensionPointId)
             .Any(f => f.Id == product.ExtensionId && f.Schema.Pattern.Id == product.DefinitionId));
 }