|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.andromda.core.namespace.BaseNamespaceComponent
org.andromda.core.common.BasePlugin
org.andromda.core.cartridge.Cartridge
public class Cartridge
The AndroMDA Cartridge implementation of the Plugin. Cartridge instances are configured from
META-INF/andromda/cartridge.xml files discovered on the classpath.
| Constructor Summary | |
|---|---|
Cartridge()
|
|
| Method Summary | |
|---|---|
void |
addCondition(java.lang.String name,
java.lang.String value)
Adds the outputCondition given the name and value
to the outputConditions map. |
void |
addResource(Resource resource)
Adds a resource to the list of defined resources. |
java.util.Map |
getConditions()
Gets the current outputConditions defined within this cartridge |
java.util.List |
getResources()
Returns the list of templates configured in this cartridge. |
protected void |
populateTemplateContext(java.util.Map templateContext)
Populates the templateContext with the properties and template objects defined in the
plugin's descriptor. |
void |
processModelElements(MetafacadeFactory factory)
Processes all model elements with relevant stereotypes by retrieving the model elements from the model facade contained within the context. |
protected void |
processResource(Resource resource)
Processes the given resource |
protected void |
processTemplate(MetafacadeFactory factory,
Template template)
Processes the given template. |
protected void |
processTemplateWithMetafacades(MetafacadeFactory factory,
Template template)
Processes all modelElements for this template. |
protected void |
processTemplateWithoutMetafacades(Template template)
Processes the template without metafacades. |
void |
shutdown()
Override to provide cartridge specific shutdown ( |
| Methods inherited from class org.andromda.core.common.BasePlugin |
|---|
addMacrolibrary, addPropertyReference, addTemplateObject, getContents, getLogger, getMergeLocation, getPropertyReferences, getTemplateEngine, getTemplateObjects, initialize, setTemplateEngineClass, toString |
| Methods inherited from class org.andromda.core.namespace.BaseNamespaceComponent |
|---|
getNamespace, getResource, setNamespace, setResource |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.andromda.core.namespace.NamespaceComponent |
|---|
getNamespace, getResource, setNamespace, setResource |
| Constructor Detail |
|---|
public Cartridge()
| Method Detail |
|---|
public void processModelElements(MetafacadeFactory factory)
factory - the metafacade factory (which is used to manage the lifecycle of metafacades).
protected void processTemplate(MetafacadeFactory factory,
Template template)
template.
factory - the metafacade factory instance.template - the Template instance to process.
protected void processTemplateWithMetafacades(MetafacadeFactory factory,
Template template)
modelElements for this template.
factory - the metafacade factorytemplate - the template to processprotected void processTemplateWithoutMetafacades(Template template)
template without metafacades. This is useful if you need to generate something that
is part of your cartridge, however you only need to use a property passed in from a namespace or a template
object defined in your cartridge descriptor.
template - the template to process.protected void processResource(Resource resource)
resource
resource - the resource to process.public java.util.List getResources()
public void addResource(Resource resource)
resource - the new resource to addprotected void populateTemplateContext(java.util.Map templateContext)
templateContext with the properties and template objects defined in the
plugin's descriptor. If the templateContext is null, a new Map instance will be created
before populating the context.
populateTemplateContext in class BasePlugintemplateContext - the context of the template to populate.
public void addCondition(java.lang.String name,
java.lang.String value)
name and value
to the outputConditions map.
name - the name of the outputCondition.value - the value of the outputCondition.public java.util.Map getConditions()
public void shutdown()
shutdown in interface Pluginshutdown in class BasePluginPlugin.shutdown()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||