public class ApplicationBuilderData extends Object implements BuilderData
The application specific default implementation of the BuilderData
interface.
This class provides meaningful implementations of all methods required by the
BuilderData interface. An instance can be obtained from the
ApplicationContext class that is already initialized with predefined
values for many fields. So a client need not bother with all of the data
supported by this interface, but has only to set the values it is specially
interested in.
Implementation note: this class is not thread-safe. The typical usage
scenario is that an instance is requested from ApplicationContext,
initialized with the properties required by the application and passed to a
builder.
ApplicationContext.initBuilderData()KEY_RESULT_WINDOW| Constructor and Description |
|---|
ApplicationBuilderData()
Creates a new instance of
ApplicationBuilderData. |
| Modifier and Type | Method and Description |
|---|---|
void |
addBeanCreationListener(BeanCreationListener l)
Adds the specified
BeanCreationListener to this object. |
void |
addBeanCreationListeners(Collection<? extends BeanCreationListener> listeners)
Adds all
BeanCreationListener objects contained in the given
collection to this object. |
void |
addProperty(String key,
Object value)
Adds an additional property for the builder operation.
|
ActionStore |
getActionStore()
Returns the action store.
|
BeanBuilderResult |
getBeanBuilderResult()
Returns the result object from the bean builder.
|
Collection<BeanCreationListener> |
getBeanCreationListeners()
Returns a collection with
BeanCreationListener objects to be
registered at the BeanContext created by the builder. |
BindingStrategy |
getBindingStrategy()
Returns the
BindingStrategy used by the current form. |
Builder |
getBuilder()
Returns a reference to the
Builder instance that processed this
object. |
BeanContext |
getBuilderContext()
Returns the bean context used by the builder.
|
String |
getBuilderName()
Returns the name of the builder.
|
CommandQueue |
getCommandQueue()
Returns the
CommandQueue. |
Object |
getDefaultResourceGroup()
Returns the default resource group.
|
Object |
getFormBean()
Returns the form bean.
|
FormValidator |
getFormValidator()
Returns the
FormValidator for validating the current form. |
InvocationHelper |
getInvocationHelper()
Returns the
InvocationHelper. |
MessageOutput |
getMessageOutput()
Returns the
MessageOutput object. |
BeanContext |
getParentContext()
Returns the parent bean context.
|
Window |
getParentWindow()
Returns the parent window.
|
Map<String,Object> |
getProperties()
Returns a map with additional properties for the builder operation.
|
BeanStore |
getRootStore()
Returns the root store populated by the builder.
|
TransformerContext |
getTransformerContext()
Returns the transformer context.
|
boolean |
isAutoRelease()
Returns the auto release flag.
|
boolean |
isMenuIcon()
Returns the menu icon flag.
|
boolean |
isToolbarText()
Returns the toolbar text flag.
|
void |
setActionStore(ActionStore actionStore)
Sets the action store.
|
void |
setAutoRelease(boolean autoRelease)
Sets the auto release flag.
|
void |
setBeanBuilderResult(BeanBuilderResult res)
Sets the result object for the bean builder.
|
void |
setBindingStrategy(BindingStrategy strat)
Sets the
BindingStrategy to be used by the current form. |
void |
setBuilder(Builder builder)
Sets the
Builder that processed this object. |
void |
setBuilderContext(BeanContext ctx)
Sets the bean context used by the builder.
|
void |
setBuilderName(String builderName)
Sets a name for the builder.
|
void |
setCommandQueue(CommandQueue commandQueue)
Sets the
CommandQueue. |
void |
setDefaultResourceGroup(Object defaultResourceGroup)
Sets the default resource group.
|
void |
setFormBean(Object formBean)
Sets the form bean.
|
void |
setFormValidator(FormValidator validator)
Sets the
FormValidator for validating the current form. |
void |
setInvocationHelper(InvocationHelper invocationHelper)
Sets the
InvocationHelper. |
void |
setMenuIcon(boolean menuIcon)
Sets the menu icon flag.
|
void |
setMessageOutput(MessageOutput messageOutput)
Sets the
MessageOutput object. |
void |
setParentContext(BeanContext ctx)
Sets the parent bean context.
|
void |
setParentWindow(Window parentWindow)
Sets the parent window.
|
void |
setProperties(Map<String,Object> props)
Sets additional properties for the builder operation.
|
void |
setToolbarText(boolean toolbarText)
Sets the toolbar text flag.
|
void |
setTransformerContext(TransformerContext transformerContext)
Sets the transformer context.
|
public ApplicationBuilderData()
ApplicationBuilderData.public ActionStore getActionStore()
getActionStore in interface BuilderDatapublic void setActionStore(ActionStore actionStore)
actionStore - the actionStorepublic Object getDefaultResourceGroup()
getDefaultResourceGroup in interface BuilderDatapublic void setDefaultResourceGroup(Object defaultResourceGroup)
defaultResourceGroup - the default resource grouppublic Object getFormBean()
getFormBean in interface BuilderDatapublic void setFormBean(Object formBean)
formBean - the form beanpublic BindingStrategy getBindingStrategy()
BindingStrategy used by the current form.getBindingStrategy in interface BuilderDataBindingStrategyBuilderData.getFormBean()public void setBindingStrategy(BindingStrategy strat)
BindingStrategy to be used by the current form.strat - the BindingStrategypublic FormValidator getFormValidator()
FormValidator for validating the current form.getFormValidator in interface BuilderDataFormValidatorpublic void setFormValidator(FormValidator validator)
FormValidator for validating the current form. If no
FormValidator is set, no form-level validation is performed. The
form's fields may be validated though if corresponding validators have
been defined.validator - the FormValidatorpublic boolean isMenuIcon()
isMenuIcon in interface BuilderDatapublic void setMenuIcon(boolean menuIcon)
menuIcon - the flag valuepublic Window getParentWindow()
getParentWindow in interface BuilderDatapublic void setParentWindow(Window parentWindow)
parentWindow - the parent windowpublic boolean isToolbarText()
isToolbarText in interface BuilderDatapublic void setToolbarText(boolean toolbarText)
toolbarText - the toolbar text flagpublic TransformerContext getTransformerContext()
getTransformerContext in interface BuilderDatapublic void setTransformerContext(TransformerContext transformerContext)
transformerContext - the transformer contextpublic BeanBuilderResult getBeanBuilderResult()
getBeanBuilderResult in interface BuilderDatapublic void setBeanBuilderResult(BeanBuilderResult res)
setBeanBuilderResult in interface BuilderDatares - the results of the bean builderpublic BeanContext getParentContext()
getParentContext in interface BuilderDatapublic void setParentContext(BeanContext ctx)
ctx - the parent bean contextpublic BeanStore getRootStore()
getRootStore in interface BuilderDataIllegalStateException - if no builder results are available yetBuilderData.getBeanBuilderResult()public BeanContext getBuilderContext()
getBuilderContext in interface BuilderDatapublic void setBuilderContext(BeanContext ctx)
setBuilderContext in interface BuilderDatactx - the builder's bean contextpublic InvocationHelper getInvocationHelper()
InvocationHelper.getInvocationHelper in interface BuilderDataInvocationHelperpublic void setInvocationHelper(InvocationHelper invocationHelper)
InvocationHelper.invocationHelper - the InvocationHelperpublic MessageOutput getMessageOutput()
MessageOutput object.getMessageOutput in interface BuilderDatapublic void setMessageOutput(MessageOutput messageOutput)
MessageOutput object.messageOutput - the message output objectpublic CommandQueue getCommandQueue()
CommandQueue.getCommandQueue in interface BuilderDatapublic void setCommandQueue(CommandQueue commandQueue)
CommandQueue.commandQueue - the command queuepublic Collection<BeanCreationListener> getBeanCreationListeners()
BeanCreationListener objects to be
registered at the BeanContext created by the builder. Note: this
collection cannot be modified.getBeanCreationListeners in interface BuilderDataBeanCreationListener objectspublic void addBeanCreationListener(BeanCreationListener l)
BeanCreationListener to this object. It will
be registered at the BeanContext created by the builder and thus
notified for all bean created by the
dependency injection framework.l - the BeanCreationListener to be added (must not be
null)IllegalArgumentException - if the BeanCreationListener is
nullpublic void addBeanCreationListeners(Collection<? extends BeanCreationListener> listeners)
BeanCreationListener objects contained in the given
collection to this object. They will be registered at the BeanContext created by the builder and thus notified for all bean
created by the dependency injection framework.listeners - the collection with BeanCreationListener objects
(must not be null)IllegalArgumentException - if the collection is null or
contains null elementspublic Builder getBuilder()
Builder instance that processed this
object. This value is available only after the Builder was
called.getBuilder in interface BuilderDataBuilder that processed this BuilderData
objectpublic void setBuilder(Builder builder)
Builder that processed this object. This method is
called by the Builder instance during the builder operation.setBuilder in interface BuilderDatabuilder - the Builderpublic String getBuilderName()
getBuilderName in interface BuilderDatapublic void setBuilderName(String builderName)
ComponentBuilderData object). It can be used
for conditional execution of builder scripts.builderName - the name of the builderpublic boolean isAutoRelease()
isAutoRelease in interface BuilderDatapublic void setAutoRelease(boolean autoRelease)
Builder.release(BuilderData) on the Builder responsible.
Note that the default value of this flag is true, so auto release
is enabled per default.autoRelease - the value of the auto release flagpublic Map<String,Object> getProperties()
setProperties(Map)
or the one that was created automatically when #addProperty() was
called. Result may also be null if no properties have been set.getProperties in interface BuilderDatasetProperties(Map),
addProperty(String, Object)public void setProperties(Map<String,Object> props)
props - the map with additional propertiespublic void addProperty(String key, Object value)
getProperties(). If no map with properties has been set yet, a
new one is created (getProperties() will return this new map).
Otherwise, the property is added to the existing map.key - the key of the propertyvalue - the value of the propertyCopyright © 2016 The JGUIraffe Team. All rights reserved.