templates.library
Interface Template

All Known Implementing Classes:
FSATemplate

public interface Template

Describes a template (available in a template library).

Author:
Lenko Grigorov

Field Summary
static java.awt.datatransfer.DataFlavor fsaFlavor
          The DataFlavor for an FSAModel.
static java.lang.String TEMPLATE_DESC
          The key to be used when a TemplateDescriptor is added as an annotation.
static java.awt.datatransfer.DataFlavor templateFlavor
          The DataFlavor for a Template.
 
Method Summary
 java.lang.String getDescription()
          Retrieve the description of the template.
 EntityIcon getIcon()
          Retrieve the icon of the template.
 ides.api.model.fsa.FSAModel getModel()
          Retrieve the FSAModel on which the template is based.
 java.lang.String getName()
          Retrieve the "ID" of the template.
 ides.api.model.fsa.FSAModel instantiate()
          Create a new instance of the template.
 

Field Detail

TEMPLATE_DESC

static final java.lang.String TEMPLATE_DESC
The key to be used when a TemplateDescriptor is added as an annotation.

See Also:
Annotable, Constant Field Values

templateFlavor

static final java.awt.datatransfer.DataFlavor templateFlavor
The DataFlavor for a Template.


fsaFlavor

static final java.awt.datatransfer.DataFlavor fsaFlavor
The DataFlavor for an FSAModel.

Method Detail

getName

java.lang.String getName()
Retrieve the "ID" of the template. This is a short string which can be used to identify the template, e.g., by displaying it inside the template icon.

Returns:
the "ID" of the template

getIcon

EntityIcon getIcon()
Retrieve the icon of the template. This icon can be used when visualizing the template.

Returns:
the icon of the template

getDescription

java.lang.String getDescription()
Retrieve the description of the template. This can be a longer piece of text including any notes about the template.

Returns:
the description of the template

getModel

ides.api.model.fsa.FSAModel getModel()
Retrieve the FSAModel on which the template is based.

Returns:
the FSAModel on which the template is based

instantiate

ides.api.model.fsa.FSAModel instantiate()
Create a new instance of the template. The instance is a copy of the underlying model.

Returns:
a new instance of the template