public static IEnumerable <MetaEnumerationLiteral> GetEnumerationLiteralsFor(MetaClassifier enumeration) { foreach (MetaEnumerationLiteral enumerationLiteral in Instance.enumerationLiterals.All) { if (enumerationLiteral.ContainingEnumerationType == enumeration) { yield return(enumerationLiteral); } } }
public static IEnumerable <MetaDependency> GetDependenciesFor(MetaClassifier classifier) { foreach (MetaDependency dependency in Instance.dependencies.All) { if (dependency.SourceClassifierType == classifier) { yield return(dependency); } } }
public static IEnumerable <MetaAttribute> GetAttributesFor(MetaClassifier classifier) { foreach (MetaAttribute attribute in Instance.attributes.All) { if (attribute.ContainingClassifierType == classifier) { yield return(attribute); } } }
public static bool HasDependencies(MetaClassifier classifier) { return(GetDependenciesFor(classifier).Count() > 0); }
public static bool IsAssociatedClassifier(MetaClassifier classifier) { return(GetAssociationsForAssociatedClassifier(classifier).Count() > 0); }
public static IEnumerable <MetaAssociation> GetAssociationsForAssociatedClassifier(MetaClassifier classifier) { foreach (var relation in Instance.associations.All) { if (relation.AssociatedClassifierType == classifier) { yield return(relation); } } }
public static bool HasEnumerationLiterals(MetaClassifier classifier) { return(GetEnumerationLiteralsFor(classifier).Count() > 0); }
public static bool HasAttributes(MetaClassifier classifier) { return(GetAttributesFor(classifier).Count() > 0); }
public static bool HasPackages(MetaClassifier classifier) { return(GetPackageRelationsFor(classifier).Count() > 0); }
public static IEnumerable <MetaPackageClassifierRelation> GetPackageRelationsFor(MetaClassifier classifier) { foreach (MetaPackageClassifierRelation relation in Instance.packageClassifierRelations.All) { if (relation.ClassifierType == classifier) { yield return(relation); } } }