functions.BreakingChange.ext Maven / Gradle / Ivy
extension java::GeneratorCommons;
extension functions::NamedElement;
cached List[uml::NamedElement] getAllBreakingChanges(uml::Package package):
package.allOwnedElements().typeSelect(uml::NamedElement).select(e|e.isInGeneratorWhitelist()).select(e|e.isBreakingChange()).sortBy(e|e.getBreakingChangeActiveWith());
cached List[uml::NamedElement] getBreakingChanges(uml::Package package):
package.allOwnedElements().typeSelect(uml::NamedElement).select(e|e.isInGeneratorWhitelist()).select(e|e.isBreakingChange() && e.getNearestPackage() == package).sortBy(e|e.getBreakingChangeActiveWith());
cached List[uml::Package] getPackagesForBreakingChangesReport(uml::Model model):
model.getAllBreakingChanges().getNearestPackage().toSet().sortBy(e|e.qualifiedName());
cached boolean isBreakingChange(uml::Element element):
element.isStereotypeApplied("BreakingChange");
cached String getBreakingChangeDescription(uml::NamedElement change):
change.getStereotypeValue("BreakingChange", "description").replaceAll("\n", "
");
cached String getBreakingChangeActiveWith(uml::NamedElement change):
change.getStereotypeValue("BreakingChange", "activeWith");