org.eclipse.tigerstripe.workbench.plugins
Interface IExpander


public interface IExpander


Field Summary
static java.lang.String PROP_TAG
          The tag that is used to identify a pluginProperty
 
Method Summary
 java.lang.String expandVar(java.lang.String inString)
          This does the actual expansion, using the syntax below.
 java.lang.String expandVar(java.lang.String inString, ITigerstripeModelProject project)
          As for the simple expandVar case, but passing in teh project to be used.
 java.lang.String getWrapperName()
          Get the "name" of the model.
 void setCurrentArtifact(IAbstractArtifact currentArtifact)
          Allows to set a "current artifact" for this expander.
 void setCurrentModel(IArtifactModel currentModel)
          Deprecated. - use setCurrentWrapper instead.
 void setCurrentModel(IArtifactModel currentModel, java.lang.String modelName)
          Deprecated. - use setCurrentWrapper instead.
 void setCurrentWrapper(IArtifactWrapper wrapper)
          As for current Artifact, can set a "Current Wrapper" for this expander This can be used to extract things like the TargetPackage from the wrapper - especially useful for making file names!
 void setCurrentWrapper(IArtifactWrapper wrapper, java.lang.String modelName)
          As for current Artifact, can set a "Current Wrapper" for this expander This can be used to extract things like the TargetPackage from the wrapper - especially useful for making file names! This variant is necessary in case the wrapper has been named something other than "wrapper"
 void setPluginConfig(IPluginConfig pluginConfig)
          Sets the pluginConfig for the expander.
 void setWrapperName(java.lang.String modelName)
          Set the "name" of the model.
 

Field Detail

PROP_TAG

static final java.lang.String PROP_TAG
The tag that is used to identify a pluginProperty

See Also:
Constant Field Values
Method Detail

setPluginConfig

void setPluginConfig(IPluginConfig pluginConfig)
Sets the pluginConfig for the expander. This is needed in all cases unless you want to just get the project properties.

Parameters:
pluginConfig -

setCurrentArtifact

void setCurrentArtifact(IAbstractArtifact currentArtifact)
Allows to set a "current artifact" for this expander. When a current artifact is set, additional variable may expanded. This is used in the context of Artifact-based plugin rules so that the user can get access to details about the current artifact

Parameters:
currentArtifact -
Since:
1.2

setCurrentModel

void setCurrentModel(IArtifactModel currentModel)
Deprecated. - use setCurrentWrapper instead.

As for current Artifact, can set a "Current Model" for this expander This can be used to extract things like the TargetPackage from the model - especially useful for making file names!

Parameters:
currentModel -

setCurrentModel

void setCurrentModel(IArtifactModel currentModel,
                     java.lang.String modelName)
Deprecated. - use setCurrentWrapper instead.

As for current Artifact, can set a "Current Model" for this expander This can be used to extract things like the TargetPackage from the model - especially useful for making file names! This variant is necessary in case the model has been named something other than "model"

Parameters:
currentModel -

setCurrentWrapper

void setCurrentWrapper(IArtifactWrapper wrapper)
As for current Artifact, can set a "Current Wrapper" for this expander This can be used to extract things like the TargetPackage from the wrapper - especially useful for making file names!

Parameters:
currentModel -

setCurrentWrapper

void setCurrentWrapper(IArtifactWrapper wrapper,
                       java.lang.String modelName)
As for current Artifact, can set a "Current Wrapper" for this expander This can be used to extract things like the TargetPackage from the wrapper - especially useful for making file names! This variant is necessary in case the wrapper has been named something other than "wrapper"

Parameters:
currentModel -

expandVar

java.lang.String expandVar(java.lang.String inString)
This does the actual expansion, using the syntax below. Expander Variable Syntax ${project.Version} and ${project.Name}: This returns will replace your Version and Name properties of your current project. ${artifact.Name}, ${artifact.Package} and ${artifact.Path}: This returns a name, package, and a path-like String for your package (eg com/mycompany/myPackage) of the current Artifact. This variable is only useful for Artifact based rules. ${ppProp.propertyName}: This returns the value of the Global Property named propertyName in your plug-in. ${model.attributeName}: This returns the value of the attribute named attributeName in your model. Note: The Model should be replaced with the name of the model set in the rule specification.

Parameters:
inString -
Returns:

expandVar

java.lang.String expandVar(java.lang.String inString,
                           ITigerstripeModelProject project)
As for the simple expandVar case, but passing in teh project to be used.

Parameters:
inString -
project -
Returns:

setWrapperName

void setWrapperName(java.lang.String modelName)
Set the "name" of the model. This is only necessary if the default has been change in a rule defintion.

Parameters:
modelName -

getWrapperName

java.lang.String getWrapperName()
Get the "name" of the model.

Returns: