/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * The inherit operation is overridden to exclude redefined properties. * The query inherit() defines how to inherit a set of elements. Here the operation is defined to inherit them all. It is intended to be redefined in circumstances where inheritance is affected by redefinition. * result = inhs * @param classifier The receiving '<em><b>Classifier</b></em>' model object. * <!-- end-model-doc --> * @generated NOT */ public static EList<NamedElement> inherit(Classifier classifier, EList<NamedElement> inhs) { return ECollections.unmodifiableEList(inhs); }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * Utility returning the set of realized interfaces of a component: * result = (classifier.clientDependency-> * select(dependency|dependency.oclIsKindOf(Realization) and dependency.supplier.oclIsKindOf(Interface)))-> * collect(dependency|dependency.client) * @param component The receiving '<em><b>Component</b></em>' model object. * <!-- end-model-doc --> * @generated NOT */ public static EList<Interface> realizedInterfaces(Component component, Classifier classifier) { return ECollections.unmodifiableEList(realizedInterfaces(component, classifier, true)); }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * Utility returning the set of used interfaces of a component: * result = (classifier.supplierDependency-> * select(dependency|dependency.oclIsKindOf(Usage) and dependency.supplier.oclIsKindOf(interface)))-> * collect(dependency|dependency.supplier) * @param component The receiving '<em><b>Component</b></em>' model object. * <!-- end-model-doc --> * @generated NOT */ public static EList<Interface> usedInterfaces(Component component, Classifier classifier) { return ECollections.unmodifiableEList(usedInterfaces(component, classifier, true)); }
/** * Get the list of classes that this package contains. * Since this is a derived relationship, we need to implement * it here. It will get the metaobjects list. These are the * java classes this package contains. * * If this is the primitives package, then it must return * an empty list because it doesn't contain any classes. */ public EList getJavaClasses() { return !PRIMITIVE_PACKAGE_NAME.equals(getName()) ? ECollections.unmodifiableEList(getEClassifiers()) : ECollections.EMPTY_ELIST; } /**
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * Retrieves the operations of this classifier. * @param classifier The receiving '<em><b>Classifier</b></em>' model object. * <!-- end-model-doc --> * @generated NOT */ public static EList<Operation> getOperations(Classifier classifier) { EList<Operation> operations = new UniqueEList.FastCompare<Operation>(); for (Feature feature : classifier.getFeatures()) { if (feature instanceof Operation) { operations.add((Operation) feature); } } return ECollections.unmodifiableEList(operations); }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * The query allOwnedElements() gives all of the direct and indirect owned elements of an element. * result = ownedElement->union(ownedElement->collect(e | e.allOwnedElements())) * @param element The receiving '<em><b>Element</b></em>' model object. * <!-- end-model-doc --> * @generated NOT */ public static EList<Element> allOwnedElements(Element element) { return ECollections.unmodifiableEList(allOwnedElements(element, new UniqueEList.FastCompare<Element>())); }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * The query allParents() gives all of the direct and indirect ancestors of a generalized Classifier. * result = self.parents()->union(self.parents()->collect(p | p.allParents()) * @param classifier The receiving '<em><b>Classifier</b></em>' model object. * <!-- end-model-doc --> * @generated NOT */ public static EList<Classifier> allParents(Classifier classifier) { return ECollections.unmodifiableEList(allParents(classifier, new UniqueEList.FastCompare<Classifier>())); }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * Retrieves the extensions owned by this profile, excluding non-required extensions if indicated. * @param profile The receiving '<em><b>Profile</b></em>' model object. * @param requiredOnly Whether to retrieve only required extensions. * <!-- end-model-doc --> * @generated NOT */ public static EList<Extension> getOwnedExtensions(Profile profile, boolean requiredOnly) { return ECollections.unmodifiableEList(getOwnedExtensions(profile, requiredOnly, new UniqueEList.FastCompare<Extension>())); }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * The query allIncludedUseCases() returns the transitive closure of all use cases (directly or indirectly) included by this use case. * result = self.include->union(self.include->collect(in | in.allIncludedUseCases())) * @param useCase The receiving '<em><b>Use Case</b></em>' model object. * <!-- end-model-doc --> * @generated NOT */ public static EList<UseCase> allIncludedUseCases(UseCase useCase) { return ECollections.unmodifiableEList(allIncludedUseCases(useCase, new UniqueEList.FastCompare<UseCase>())); }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * Retrieves the metaclasses extended by this stereotype. * @param stereotype The receiving '<em><b>Stereotype</b></em>' model object. * <!-- end-model-doc --> * @generated NOT */ public static EList<org.eclipse.uml2.uml.Class> getExtendedMetaclasses( Stereotype stereotype) { return ECollections.unmodifiableEList(getExtendedMetaclasses( stereotype, new UniqueEList.FastCompare<org.eclipse.uml2.uml.Class>())); }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * The query allNamespaces() gives the sequence of namespaces in which the NamedElement is nested, working outwards. * result = if self.namespace->isEmpty() * then Sequence{} * else self.namespace.allNamespaces()->prepend(self.namespace) * endif * @param namedElement The receiving '<em><b>Named Element</b></em>' model object. * <!-- end-model-doc --> * @generated NOT */ public static EList<Namespace> allNamespaces(NamedElement namedElement) { return ECollections.unmodifiableEList(allNamespaces(namedElement, new UniqueEList.FastCompare<Namespace>())); }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * <!-- begin-model-doc --> * Retrieves the packages imported by this namespace. * @param namespace The receiving '<em><b>Namespace</b></em>' model object. * <!-- end-model-doc --> * @generated NOT */ public static EList<org.eclipse.uml2.uml.Package> getImportedPackages( Namespace namespace) { EList<org.eclipse.uml2.uml.Package> importedPackages = new UniqueEList.FastCompare<org.eclipse.uml2.uml.Package>(); for (PackageImport packageImport : namespace.getPackageImports()) { org.eclipse.uml2.uml.Package importedPackage = packageImport .getImportedPackage(); if (importedPackage != null) { importedPackages.add(importedPackage); } } return ECollections.unmodifiableEList(importedPackages); }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public EList<ReferenceEmbed> getEmbedHierarchy() { EObject container = eContainer(); if (container instanceof ReferenceRealization) { // use containers of the parent ReferenceRealization container = container.eContainer(); } if (container instanceof ReferenceEmbed) { ReferenceEmbed parentEmbed = (ReferenceEmbed)container; List<ReferenceEmbed> hierarchy = Lists.newArrayList(parentEmbed.getEmbedHierarchy()); hierarchy.add(parentEmbed); return ECollections.unmodifiableEList(hierarchy); } return ECollections.emptyEList(); }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated NOT */ @SuppressWarnings("unchecked") public <S extends Segment> EList<S> getChildren() { SegmentChildren segmentChildren = getSegmentChildren(); FeatureMap segments = segmentChildren.getSegments(); EList<S> list = new BasicEList<S>(); for (FeatureMap.Entry entry: segments) { list.add((S) entry.getValue()); } return ECollections.unmodifiableEList(list); }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * * @generated NOT */ @Override public EList<InputSpecification> getKnownInputs () { if ( this.knownInputs == null ) { final BasicEList<InputSpecification> inputs = ECollections.newBasicEList (); inputs.add ( Components.createInput ( "input" ) ); this.knownInputs = ECollections.unmodifiableEList ( inputs ); } return this.knownInputs; }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * * @generated NOT */ @Override public EList<OutputSpecification> getKnownOutputs () { if ( this.knownOutputs == null ) { final BasicEList<OutputSpecification> outputs = ECollections.newBasicEList (); outputs.add ( Components.createOutput ( "output", null ) ); this.knownOutputs = ECollections.unmodifiableEList ( outputs ); } return this.knownOutputs; }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * * @generated NOT */ @Override public EList<InputSpecification> getKnownInputs () { if ( this.knownInputs == null ) { final BasicEList<InputSpecification> inputs = ECollections.newBasicEList (); inputs.add ( Components.createInput ( "input" ) ); this.knownInputs = ECollections.unmodifiableEList ( inputs ); } return this.knownInputs; }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * * @generated NOT */ @Override public EList<InputSpecification> getKnownInputs () { if ( this.knownInputs == null ) { final BasicEList<InputSpecification> inputs = ECollections.newBasicEList (); inputs.add ( Components.createInput ( "input" ) ); this.knownInputs = ECollections.unmodifiableEList ( inputs ); } return this.knownInputs; }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * * @generated NOT */ @Override public EList<InputSpecification> getKnownInputs () { if ( this.knownInputs == null ) { final BasicEList<InputSpecification> inputs = ECollections.newBasicEList (); inputs.add ( Components.createInput ( "input" ) ); this.knownInputs = ECollections.unmodifiableEList ( inputs ); } return this.knownInputs; }
/** * <!-- begin-user-doc --> * <!-- end-user-doc --> * * @generated NOT */ @Override public EList<OutputSpecification> getKnownOutputs () { if ( this.knownOutputs == null ) { final BasicEList<OutputSpecification> outputs = ECollections.newBasicEList (); outputs.add ( Components.createOutput ( "output", null ) ); this.knownOutputs = ECollections.unmodifiableEList ( outputs ); } return this.knownOutputs; }