public interface IInfrastructureModelFactory
New model elements can easily be created using createXxxxx() methods where Xxxxx is the name of the metaclass for which an instance has to be created. At least one method createXxxxx() exists for model Element. i.e.:
IModelFactory#createElement(Class)
. This method only create an instance of the metaclass. The instance will have to be attached to the model and eventually named to be valid for the current transaction.
ModuleParameter createConfigParam()
ModuleParameter
.Dependency createDependency()
Dependency
.Dependency createDependency(ModelElement source, ModelElement destination, Stereotype stereotype)
source
- the origin of the dependency.destination
- the destination of the dependency.stereotype
- the Stereotype that extends the dependency.Dependency createDependency(ModelElement source, ModelElement destination, java.lang.String moduleName, java.lang.String stereotypeName) throws ExtensionNotFoundException
ExtensionNotFoundException
DiagramSet createDiagramSet()
DiagramSet
.DiagramSet createDiagramSet(java.lang.String name, DiagramSet owner)
name
- the name of the DiagramSet to create.owner
- the DiagramSet that will own the DiagramSet. f null, the created DiagramSet is owned at the project level.Document createDocument()
Call AbstractResource.createEmbeddedResource(String)
or AbstractResource.createExternalResource(String)
on the returned resource to initialize it.
Document
.EnumeratedPropertyType createEnumeratedPropertyType()
EnumeratedPropertyType
.@Deprecated Document createExternDocument()
ExternDocument
.@Deprecated Document createExternDocument(ResourceType resourceType, ModelElement owner, java.lang.String mimeType)
Call AbstractResource.createEmbeddedResource(String)
or AbstractResource.createExternalResource(String)
on the returned resource to initialize it.
resourceType
- the role played by the resource.owner
- the composition owner of the resource.mimeType
- the MIME type of the rich note.Document
representing the rich note in the model.@Deprecated Document createExternDocument(java.lang.String moduleName, java.lang.String ownerName, java.lang.String documentRole, ModelElement owner, java.lang.String mimeType) throws ExtensionNotFoundException
ExtensionNotFoundException
@Deprecated ResourceType createExternDocumentType()
ResourceType
.ExternProcessor createExternProcessor()
ExternProcessor
.GraphDiagram createGraphDiagram()
GraphDiagram
.GraphDiagram createGraphDiagram(java.lang.String name, ModelElement owner)
name
- the name of the ActivityDiagram to be created.owner
- the new element's composition owner.GraphDiagram
.ImpactDiagram createImpactDiagram()
ImpactDiagram
.ImpactDiagram createImpactDiagram(ImpactModel owner)
owner
- the new element's composition owner.ImpactDiagram
.ImpactLink createImpactLink()
ImpactLink
.ImpactLink createImpactLink(ImpactModel owner, ModelElement source, ModelElement target)
owner
- the new element's composition owner.source
- the link's source.target
- the link's target.ImpactLink
.ImpactModel createImpactModel()
ImpactModel
.ImpactModel createImpactModel(ImpactProject owner)
owner
- the new element's composition owner.ImpactModel
.ImpactProject createImpactProject(IRepository repository)
ImpactProject
.repository
- the repository where the model object will be stored.ImpactProject
.LocalPropertyTable createLocalPropertyTable()
LocalPropertyTable
.MatrixDefinition createMatrixDefinition()
MatrixDefinition
.MatrixValueDefinition createMatrixValueDefinition()
MatrixValueDefinition
.MetaclassReference createMetaclassReference()
MetaclassReference
.ModuleComponent createModuleProject(IRepository repository)
repository
- the repository where the model object will be stored.ModuleComponent
.Note createNote(NoteType noteType, ModelElement owner, java.lang.String content)
noteType
- the type of the Note.owner
- the composition owner of the Note.content
- the text of the Note.Note createNote(java.lang.String moduleName, java.lang.String ownerName, java.lang.String noteTypeName, ModelElement owner, java.lang.String content) throws ExtensionNotFoundException
ExtensionNotFoundException
PropertyDefinition createPropertyDefinition()
PropertyDefinition
.PropertyEnumerationLitteral createPropertyEnumerationLitteral()
PropertyEnumerationLitteral
.PropertyTable createPropertyTable()
PropertyTable
.PropertyTableDefinition createPropertyTableDefinition()
PropertyTableDefinition
.PropertyType createPropertyType()
PropertyType
.QueryDefinition createQueryDefinition()
QueryDefinition
.ResourceType createResourceType()
ResourceType
.Stereotype createStereotype()
Stereotype
.TagParameter createTagParameter()
TagParameter
.TagParameter createTagParameter(java.lang.String value, TaggedValue owner)
value
- the value of the tag parameter.owner
- the owner tagged value of the tag parameterTaggedValue createTaggedValue()
TaggedValue
.TaggedValue createTaggedValue(TagType tagType, ModelElement owner)
tagType
- the type of the TaggedValue.owner
- the ModelElement that contains the Taggedvalue.TaggedValue createTaggedValue(java.lang.String moduleName, java.lang.String ownerName, java.lang.String tagTypeName, ModelElement owner) throws ExtensionNotFoundException
ExtensionNotFoundException
TypedPropertyTable createTypedPropertyTable()
TypedPropertyTable
.IResourceBuilder resourceBuilder()
Document
or Resource
.void setDefaultValue(java.lang.String key, java.lang.Object value)