Commit dd36cc5d authored by Simon Barner's avatar Simon Barner
Browse files

Add AllocationTable.getAllocationEntries()

refs 2950
parent a4cf16ed
......@@ -19,6 +19,15 @@
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="documentation" value="Base class for allocation / mapping between a source model and a target view. The relation is defined using specializations of {@link org.fortiss.af3.allocation.model.AllocationEntry}."/>
</eAnnotations>
<eOperations name="getAllocationEntries">
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="documentation" value="Returns all contained {@link org.fortiss.af3.allocation.model.AllocationEntry}s."/>
<details key="body" value="return AllocationTableStaticImpl.getAllocationEntries(this);"/>
</eAnnotations>
<eGenericType eClassifier="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EEList">
<eTypeArguments eClassifier="#//OneToOneAllocationEntry"/>
</eGenericType>
</eOperations>
<eOperations name="getOneToOneAllocationEntries">
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="documentation" value="Returns all allocation entries specializing {@link org.fortiss.af3.allocation.model.OneToOneAllocationEntry}."/>
......
......@@ -16,6 +16,7 @@
<genClasses ecoreClass="allocation.ecore#//AllocationTable">
<genFeatures notify="false" createChild="false" propertySortChoices="true" ecoreFeature="ecore:EReference allocation.ecore#//AllocationTable/sourceView"/>
<genFeatures notify="false" createChild="false" propertySortChoices="true" ecoreFeature="ecore:EReference allocation.ecore#//AllocationTable/targetView"/>
<genOperations ecoreOperation="allocation.ecore#//AllocationTable/getAllocationEntries"/>
<genOperations ecoreOperation="allocation.ecore#//AllocationTable/getOneToOneAllocationEntries"/>
<genOperations ecoreOperation="allocation.ecore#//AllocationTable/getOneToManyAllocationEntries"/>
<genOperations ecoreOperation="allocation.ecore#//AllocationTable/getManyToOneAllocationEntries"/>
......
......@@ -24,6 +24,7 @@ import java.util.TreeSet;
import org.eclipse.emf.common.util.EList;
import org.eclipse.emf.ecore.EOperation;
import org.fortiss.af3.allocation.model.AllocationEntry;
import org.fortiss.af3.allocation.model.AllocationTable;
import org.fortiss.af3.allocation.model.ManyToOneAllocationEntry;
import org.fortiss.af3.allocation.model.OneToManyAllocationEntry;
......@@ -36,10 +37,24 @@ import org.fortiss.tooling.base.model.element.IModelElement;
* @author barner
* @author $Author$
* @version $Rev$
* @ConQAT.Rating YELLOW Hash: 53CF4A0CD26AC7B5F582033920F838C9
* @ConQAT.Rating YELLOW Hash: 13B0907F44070E6A4C9311E5F87203B8
*/
public class AllocationTableStaticImpl {
/**
* Returns the {@link AllocationEntry}s contained by the given {@link AllocationTable}.
*
* @param allocationTable
* {@link AllocationTable} for which to the return the contained
* {@link AllocationEntry}s.
*
* @return {@link AllocationEntry}s contained by the given {@link AllocationTable}.
*/
public static EList<AllocationEntry> getAllocationEntries(AllocationTable allocationTable) {
return pickInstanceOf(AllocationEntry.class, allocationTable.getContainedElements());
}
/**
* Returns the {@link OneToOneAllocationEntry}s contained by the given {@link AllocationTable}.
*
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment