Package org.nuiton.jaxx.runtime
Interface JAXXObject
-
- All Superinterfaces:
JAXXContext,Serializable
public interface JAXXObject extends JAXXContext, Serializable
TheJAXXObjectinterface is implemented by all classes produced by the JAXX compiler.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddPropertyChangeListener(PropertyChangeListener listener)Register a generalPropertyChangeListener.voidaddPropertyChangeListener(String property, PropertyChangeListener listener)Register aPropertyChangeListener. for the givenpropertyName.voidapplyDataBinding(String id)Apply the data bind by name and then process it.Map<String,Object>get$objectMap()Pretrieves the dictonary of knwon objects indexed by their ids.JAXXBindinggetDataBinding(String bindingId)Obtain a binding given his id.JAXXBinding[]getDataBindings()JAXXContextgetDelegateContext()ObjectgetObjectById(String id)Retrieves an object defined in an XML tag by its ID.<O extends Container>
OgetParentContainer(Class<O> clazz)Return parent's container corresponding to the Class clazz<O extends Container>
OgetParentContainer(Object top, Class<O> clazz)Return parent's container corresponding to the Class clazzvoidprocessDataBinding(String dest)Processes a data binding by name.voidprocessDataBinding(String dest, boolean force)Processes a data binding by name.voidregisterDataBinding(JAXXBinding binding)Register a new binding in the jaxx object.voidremoveDataBinding(String id)Remove a databinding by name.voidremovePropertyChangeListener(PropertyChangeListener listener)Unregister a generalPropertyChangeListener.voidremovePropertyChangeListener(String property, PropertyChangeListener listener)Unregister aPropertyChangeListener. for the givenpropertyName.-
Methods inherited from interface org.nuiton.jaxx.runtime.JAXXContext
getContextValue, getContextValue, removeContextValue, removeContextValue, setContextValue, setContextValue
-
-
-
-
Method Detail
-
getObjectById
Object getObjectById(String id)
Retrieves an object defined in an XML tag by its ID.- Parameters:
id- the id of the component to retrieve- Returns:
- the object
-
get$objectMap
Map<String,Object> get$objectMap()
Pretrieves the dictonary of knwon objects indexed by their ids.- Returns:
- the dictonary of objects.
-
getDelegateContext
JAXXContext getDelegateContext()
- Returns:
- the
JAXXContextattached to the object
-
getDataBindings
JAXXBinding[] getDataBindings()
- Returns:
- all the databinding registred on the jaxx object
-
registerDataBinding
void registerDataBinding(JAXXBinding binding)
Register a new binding in the jaxx object.- Parameters:
binding- the binding to add
-
applyDataBinding
void applyDataBinding(String id)
Apply the data bind by name and then process it.- Parameters:
id- the id of the databinding
-
processDataBinding
void processDataBinding(String dest)
Processes a data binding by name. Data binding names are comprised of an object ID and a property name: for example, the data binding in the tag<JLabel id='label' text='{foo.getText()}'/>is named"label.text". Processing a data binding causes it to reevaluate its expression, in this casefoo.getText().- Parameters:
dest- the name of the data binding to run
-
processDataBinding
void processDataBinding(String dest, boolean force)
Processes a data binding by name. Data binding names are comprised of an object ID and a property name: for example, the data binding in the tag<JLabel id='label' text='{foo.getText()}'/>is named"label.text". Processing a data binding causes it to reevaluate its expression, in this casefoo.getText().- Parameters:
dest- the name of the data binding to runforce- flag to force binding, even if already on run
-
removeDataBinding
void removeDataBinding(String id)
Remove a databinding by name.- Parameters:
id- the name of databinding to remove
-
getDataBinding
JAXXBinding getDataBinding(String bindingId)
Obtain a binding given his id.- Parameters:
bindingId- the id of the binding- Returns:
- the binding, or
nullif not found. - Since:
- 2.4.2
- See Also:
JAXXBinding
-
addPropertyChangeListener
void addPropertyChangeListener(PropertyChangeListener listener)
Register a generalPropertyChangeListener.- Parameters:
listener- the listener to register
-
addPropertyChangeListener
void addPropertyChangeListener(String property, PropertyChangeListener listener)
Register aPropertyChangeListener. for the givenpropertyName.- Parameters:
property- the property name to listenlistener- the listener to register
-
removePropertyChangeListener
void removePropertyChangeListener(PropertyChangeListener listener)
Unregister a generalPropertyChangeListener.- Parameters:
listener- the listener to unregister
-
removePropertyChangeListener
void removePropertyChangeListener(String property, PropertyChangeListener listener)
Unregister aPropertyChangeListener. for the givenpropertyName.- Parameters:
property- the property name to listenlistener- the listener to unregister
-
getParentContainer
<O extends Container> O getParentContainer(Class<O> clazz)
Return parent's container corresponding to the Class clazz- Type Parameters:
O- type of container to obtain from context- Parameters:
clazz- clazz desired- Returns:
- parent's container
-
-