public class DeclarationFunctor<T> extends Object implements IFunctor<T>, IElementConfigurable, IElementSerializable, IDeclarationSupport, IContextSupport, IPresentationSupport
ATTR_DESCRIPTION, ATTR_ICON, ATTR_LABEL, ATTR_TIP| Constructor and Description |
|---|
DeclarationFunctor() |
DeclarationFunctor(IFunctor functor) |
| Modifier and Type | Method and Description |
|---|---|
void |
configure(IElement pElement) |
Object |
getContext() |
IDeclarationBlock |
getDeclarationBlock()
The block of declarations available so far for this.
|
String |
getDescription()
A long, descriptive string representation.
|
IFunctor |
getFunctor() |
String |
getIconName()
A name for an icon.
|
String |
getLabel()
A short string representation (suitable for example for use with an icon
or menu item).
|
String |
getTip()
An "intermediate" length description (suitable for example with a
tooltip).
|
T |
perform(IFunctorCall call)
Perform the encapsulated business logic in the context defined in "call".
|
void |
serialize(IElement element)
Serialize the state in
element. |
void |
setContext(Object context) |
public DeclarationFunctor()
public DeclarationFunctor(IFunctor functor)
public void configure(IElement pElement) throws ConfigurationException
configure in interface IElementConfigurableConfigurationExceptionpublic Object getContext()
public IDeclarationBlock getDeclarationBlock()
IDeclarationSupportgetDeclarationBlock in interface IDeclarationSupportpublic String getDescription()
IPresentationSupportgetDescription in interface IPresentationSupportpublic IFunctor getFunctor()
public String getIconName()
IPresentationSupportgetIconName in interface IPresentationSupportpublic String getLabel()
IPresentationSupportgetLabel in interface IPresentationSupportpublic String getTip()
IPresentationSupportgetTip in interface IPresentationSupportpublic T perform(IFunctorCall call) throws FunctorInvocationException
IFunctorperform in interface IFunctor<T>call - The call contextFunctorInvocationException - An exception that raised while executing the business logic
will be wrapped in a FunctorInvocationException.public void serialize(IElement element) throws ElementSerializationException
IElementSerializableelement. element
represents the receiver immediately, it contains the state information
directly, not as a child element. This means most of the time you have to
change the element name itself and add child elements.serialize in interface IElementSerializableElementSerializationExceptionpublic void setContext(Object context) throws ConfigurationException
setContext in interface IContextSupportConfigurationExceptionCopyright © 2013 intarsys consulting GmbH. All Rights Reserved.