Interface JAXXObject

    • Method Detail

      • initialize

        static void initialize​(JAXXObject ui,
                               Supplier<UIHandler<? extends JAXXObject>> createHandler,
                               Runnable createComponents,
                               Runnable registerDataBindings,
                               Runnable finalizeCreateComponents,
                               Runnable registerActions,
                               Runnable applyDataBindings,
                               Runnable setProperties,
                               Runnable finalizeInitialize)
        Initialize a JAXXObject. This method is always
        Parameters:
        ui - jaxx object to initialize
        createHandler - to create handler (can return null, for ui without handler)
        createComponents - to create components
        registerDataBindings - to register data bindings
        finalizeCreateComponents - to finalize components
        registerActions - to register actions
        applyDataBindings - to apply data bindings
        setProperties - to set properties
        finalizeInitialize - to finalize init
      • 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.
      • 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 case foo.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 case foo.getText().
        Parameters:
        dest - the name of the data binding to run
        force - 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 null if not found.
        Since:
        2.4.2
        See Also:
        JAXXBinding
      • addPropertyChangeListener

        void addPropertyChangeListener​(String property,
                                       PropertyChangeListener listener)
        Register a PropertyChangeListener. for the given propertyName.
        Parameters:
        property - the property name to listen
        listener - the listener to register
      • removePropertyChangeListener

        void removePropertyChangeListener​(String property,
                                          PropertyChangeListener listener)
        Unregister a PropertyChangeListener. for the given propertyName.
        Parameters:
        property - the property name to listen
        listener - 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
      • getParentContainer

        <O extends Container> O getParentContainer​(Object top,
                                                   Class<O> clazz)
        Return parent's container corresponding to the Class clazz
        Type Parameters:
        O - type of container to obtain from context
        Parameters:
        top - the top container
        clazz - desired
        Returns:
        parent's container