Package org.zkoss.bind.sys
Interface BinderCtrl
-
- All Known Subinterfaces:
ClientBinder
- All Known Implementing Classes:
AnnotateBinder
,AnnotateBinderEx
,BinderImpl
,DefaultBinder
,DefaultClientBinder
public interface BinderCtrl
An addition interface toBinder
that is used for implementation or tools.
Application developers rarely need to access methods in this interface.- Since:
- 6.0.0
- Author:
- dennis, jumperchen
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
ACTIVATOR
static java.lang.String
BINDCTX
static java.lang.String
BINDER
static java.lang.String
BINDING
static java.lang.String
BINDRENDERING
static java.lang.String
CHILDREN_ATTR
static java.lang.String
CHILDREN_BINDING_MODEL
static java.lang.String
CHILDREN_BINDING_MODEL_LISTENER
static java.lang.String
CHILDREN_BINDING_RENDERED_COMPONENTS
static java.lang.String
CLIENT_INFO
static java.lang.String
CLIENT_UPLOAD_INFO
static java.lang.String
DEFAULT_QUEUE_NAME
Default queue name of a binder to share the bean notification and global commandsstatic java.lang.String
DEFAULT_QUEUE_SCOPE
Default queue scope of a binder to share the bean notification and global commandsstatic java.lang.String
DEPENDS_ON_COMP
static java.lang.String
FORM_ID
static java.lang.String
IGNORE_REF_VALUE
static java.lang.String
IGNORE_TRACKER
static java.lang.String
INVALIDATE_REF_VALUE
static java.lang.String
IS_TEMPLATE_MODEL_ENABLED_ATTR
static java.lang.String
LOAD_FORM_COMPONENT
static java.lang.String
LOAD_FORM_EXPRESSION
static java.lang.String
MATCHMEDIAVALUE_PREFIX
static java.lang.String
MODEL
static java.lang.String
NOTIFYS
static java.lang.String
ON_BIND_CLEAN
static java.lang.String
ON_BIND_INIT
static java.lang.String
PHASE_LISTENER_CLASS_KEY
PhaseListener keystatic java.lang.String
REMOVE_BINDINGS
static java.lang.String
RENDERER_INSTALLED
static java.lang.String
SAVE_BASE
static java.lang.String
SRCPATH
static java.lang.String
VALIDATES
static java.lang.String
VAR
static java.lang.String
VIEWMODELID_BINDER_MAP_KEY
Key of the relation from viewmodel id to binderstatic java.lang.String
VM
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
addFormAssociatedSaveBinding(Component associatedComp, java.lang.String formId, SaveBinding saveBinding, java.lang.String fieldName)
Add a association between formId and a associated save binding(save binding inside a form), the form has to exist in the parent componentsvoid
addPhaseListener(PhaseListener listener)
Add thePhaseListener
void
addSaveFormFieldName(Form form, java.lang.String fieldName)
Adds a field name for saving with the given Form.void
addSaveFormFieldName(Form form, java.util.Set<java.lang.String> fieldNames)
Adds all field names for saving with the given Form.BindingAnnotationInfoChecker
getBindingAnnotationInfoChecker()
get binding annotation info checkerBindingExecutionInfoCollector
getBindingExecutionInfoCollector()
get binding execution info collectorForm
getForm(Component comp, java.lang.String id)
Get the form of the componentjava.util.Set<SaveBinding>
getFormAssociatedSaveBindings(Component formComp)
Get associated save bindings of a form in a componentjava.util.List<Binding>
getLoadPromptBindings(Component comp, java.lang.String attr)
get all load prompt binding of the component and attributejava.util.Map<java.lang.String,java.lang.reflect.Method>
getMatchMediaValue()
Returns an unmodifiable Map containing all the MatchMedia annotation values of this binder.java.util.List<PhaseListener>
getPhaseListeners()
get the firstPhaseListener
java.lang.String
getQueueName()
Returns the queue name of this binderjava.lang.String
getQueueScope()
Returns the queue scope of this binderjava.util.Set<java.lang.String>
getSaveFormFieldNames(Form self)
Returns all field names for saving with the given Form.TemplateResolver
getTemplateResolver(Component comp, java.lang.String attr)
get the template resolver that sets byBinder.setTemplate(Component, String, String, java.util.Map)
Tracker
getTracker()
Returns associated dependency tracker of this binder.ValidationMessages
getValidationMessages()
Get theValidationMessages
boolean
hasValidator(Component comp, java.lang.String attr)
is there a validator on the attribute of componentvoid
initActivator()
Internal use only.void
initQueue()
Internal use only.boolean
isActivating()
check if binder is in activating statejava.util.Set<java.lang.String>
removeSaveFormFieldNames(Form self)
Remove all field names for saving with the given Form.void
setValidationMessages(ValidationMessages messages)
Set theValidationMessages
void
storeForm(Component comp, java.lang.String id, Form form)
Store the form in the component with id
-
-
-
Field Detail
-
DEFAULT_QUEUE_NAME
static final java.lang.String DEFAULT_QUEUE_NAME
Default queue name of a binder to share the bean notification and global commands- See Also:
- Constant Field Values
-
DEFAULT_QUEUE_SCOPE
static final java.lang.String DEFAULT_QUEUE_SCOPE
Default queue scope of a binder to share the bean notification and global commands- See Also:
- Constant Field Values
-
PHASE_LISTENER_CLASS_KEY
static final java.lang.String PHASE_LISTENER_CLASS_KEY
PhaseListener key- See Also:
- Constant Field Values
-
VIEWMODELID_BINDER_MAP_KEY
static final java.lang.String VIEWMODELID_BINDER_MAP_KEY
Key of the relation from viewmodel id to binder- See Also:
- Constant Field Values
-
BINDING
static final java.lang.String BINDING
- See Also:
- Constant Field Values
-
BINDER
static final java.lang.String BINDER
- See Also:
- Constant Field Values
-
BINDCTX
static final java.lang.String BINDCTX
- See Also:
- Constant Field Values
-
VAR
static final java.lang.String VAR
- See Also:
- Constant Field Values
-
VM
static final java.lang.String VM
- See Also:
- Constant Field Values
-
NOTIFYS
static final java.lang.String NOTIFYS
- See Also:
- Constant Field Values
-
VALIDATES
static final java.lang.String VALIDATES
- See Also:
- Constant Field Values
-
SRCPATH
static final java.lang.String SRCPATH
- See Also:
- Constant Field Values
-
DEPENDS_ON_COMP
static final java.lang.String DEPENDS_ON_COMP
- See Also:
- Constant Field Values
-
RENDERER_INSTALLED
static final java.lang.String RENDERER_INSTALLED
- See Also:
- Constant Field Values
-
REMOVE_BINDINGS
static final java.lang.String REMOVE_BINDINGS
- See Also:
- Constant Field Values
-
IS_TEMPLATE_MODEL_ENABLED_ATTR
static final java.lang.String IS_TEMPLATE_MODEL_ENABLED_ATTR
- See Also:
- Constant Field Values
-
LOAD_FORM_EXPRESSION
static final java.lang.String LOAD_FORM_EXPRESSION
- See Also:
- Constant Field Values
-
LOAD_FORM_COMPONENT
static final java.lang.String LOAD_FORM_COMPONENT
- See Also:
- Constant Field Values
-
IGNORE_TRACKER
static final java.lang.String IGNORE_TRACKER
- See Also:
- Constant Field Values
-
IGNORE_REF_VALUE
static final java.lang.String IGNORE_REF_VALUE
- See Also:
- Constant Field Values
-
INVALIDATE_REF_VALUE
static final java.lang.String INVALIDATE_REF_VALUE
- See Also:
- Constant Field Values
-
SAVE_BASE
static final java.lang.String SAVE_BASE
- See Also:
- Constant Field Values
-
ON_BIND_INIT
static final java.lang.String ON_BIND_INIT
- See Also:
- Constant Field Values
-
ON_BIND_CLEAN
static final java.lang.String ON_BIND_CLEAN
- See Also:
- Constant Field Values
-
MODEL
static final java.lang.String MODEL
- See Also:
- Constant Field Values
-
FORM_ID
static final java.lang.String FORM_ID
- See Also:
- Constant Field Values
-
CHILDREN_ATTR
static final java.lang.String CHILDREN_ATTR
- See Also:
- Constant Field Values
-
ACTIVATOR
static final java.lang.String ACTIVATOR
- See Also:
- Constant Field Values
-
BINDRENDERING
static final java.lang.String BINDRENDERING
- See Also:
- Constant Field Values
-
CHILDREN_BINDING_RENDERED_COMPONENTS
static final java.lang.String CHILDREN_BINDING_RENDERED_COMPONENTS
- See Also:
- Constant Field Values
-
CHILDREN_BINDING_MODEL
static final java.lang.String CHILDREN_BINDING_MODEL
- See Also:
- Constant Field Values
-
CHILDREN_BINDING_MODEL_LISTENER
static final java.lang.String CHILDREN_BINDING_MODEL_LISTENER
- See Also:
- Constant Field Values
-
CLIENT_INFO
static final java.lang.String CLIENT_INFO
- See Also:
- Constant Field Values
-
MATCHMEDIAVALUE_PREFIX
static final java.lang.String MATCHMEDIAVALUE_PREFIX
- See Also:
- Constant Field Values
-
CLIENT_UPLOAD_INFO
static final java.lang.String CLIENT_UPLOAD_INFO
- See Also:
- Constant Field Values
-
-
Method Detail
-
addFormAssociatedSaveBinding
void addFormAssociatedSaveBinding(Component associatedComp, java.lang.String formId, SaveBinding saveBinding, java.lang.String fieldName)
Add a association between formId and a associated save binding(save binding inside a form), the form has to exist in the parent components- Parameters:
associatedComp
- associated component inside a form bindingformId
- the form idsaveBinding
- the nested save binding in side a form bindingfieldName
- the associated form fieldName for the associated save binding- Since:
- 6.0.1
-
getFormAssociatedSaveBindings
java.util.Set<SaveBinding> getFormAssociatedSaveBindings(Component formComp)
Get associated save bindings of a form in a component- Parameters:
formComp
- the component that contains the form- Returns:
- all associated save binding in the form
-
storeForm
void storeForm(Component comp, java.lang.String id, Form form)
Store the form in the component with id- Parameters:
comp
- the component to store the formid
- the form idform
- the form instance
-
getForm
Form getForm(Component comp, java.lang.String id)
Get the form of the component- Parameters:
comp
- the component has the formid
- the form id- Returns:
- the form if there is a form inside the component with the id
-
getTracker
Tracker getTracker()
Returns associated dependency tracker of this binder.- Returns:
- associated dependency tracker of this binder.
-
getValidationMessages
ValidationMessages getValidationMessages()
Get theValidationMessages
- Returns:
- null if no one set the instance by
setValidationMessages(ValidationMessages)
-
setValidationMessages
void setValidationMessages(ValidationMessages messages)
Set theValidationMessages
- Parameters:
messages
- theValidationMessages
-
hasValidator
boolean hasValidator(Component comp, java.lang.String attr)
is there a validator on the attribute of component- Parameters:
comp
- the component to checkattr
- the attribute to check- Returns:
- true if there is a validator
-
getTemplateResolver
TemplateResolver getTemplateResolver(Component comp, java.lang.String attr)
get the template resolver that sets byBinder.setTemplate(Component, String, String, java.util.Map)
- Parameters:
comp
- the component has resolversattr
- the attribute to get the resolver- Returns:
- the resolver, null if not existed.
-
getLoadPromptBindings
java.util.List<Binding> getLoadPromptBindings(Component comp, java.lang.String attr)
get all load prompt binding of the component and attribute- Parameters:
comp
- the component is relative to the bindingsattr
- the attribute is relative to the bindings- Returns:
- the prompt-load-bindings
-
getPhaseListeners
java.util.List<PhaseListener> getPhaseListeners()
get the firstPhaseListener
- Returns:
- the
PhaseListener
-
addPhaseListener
void addPhaseListener(PhaseListener listener)
Add thePhaseListener
- Parameters:
listener
-- Since:
- 8.0.0
-
isActivating
boolean isActivating()
check if binder is in activating state- Returns:
- true if binder is currently in activating state
- Since:
- 6.0.1
-
initQueue
void initQueue()
Internal use only. Check and init queue- Since:
- 10.0.0
-
initActivator
void initActivator()
Internal use only. Check and init Activator- Since:
- 10.0.0
-
getBindingExecutionInfoCollector
BindingExecutionInfoCollector getBindingExecutionInfoCollector()
get binding execution info collector- Returns:
- the collector instance or null if no collector is existed
- Since:
- 6.5.2
-
getBindingAnnotationInfoChecker
BindingAnnotationInfoChecker getBindingAnnotationInfoChecker()
get binding annotation info checker- Returns:
- the collector instance or null if no collector is existed
- Since:
- 6.5.2
-
getQueueName
java.lang.String getQueueName()
Returns the queue name of this binder- Since:
- 8.0.0
-
getQueueScope
java.lang.String getQueueScope()
Returns the queue scope of this binder- Since:
- 8.0.0
-
addSaveFormFieldName
void addSaveFormFieldName(Form form, java.lang.String fieldName)
Adds a field name for saving with the given Form.- Parameters:
fieldName
- field name to be saved into.- Since:
- 8.0.0
-
addSaveFormFieldName
void addSaveFormFieldName(Form form, java.util.Set<java.lang.String> fieldNames)
Adds all field names for saving with the given Form.- Parameters:
fieldNames
- field name to be saved into.- Since:
- 8.0.0
-
getSaveFormFieldNames
java.util.Set<java.lang.String> getSaveFormFieldNames(Form self)
Returns all field names for saving with the given Form.- Since:
- 8.0.0
-
removeSaveFormFieldNames
java.util.Set<java.lang.String> removeSaveFormFieldNames(Form self)
Remove all field names for saving with the given Form.- Since:
- 8.0.0
-
getMatchMediaValue
java.util.Map<java.lang.String,java.lang.reflect.Method> getMatchMediaValue()
Returns an unmodifiable Map containing all the MatchMedia annotation values of this binder. If there's no MatchMedia annotation, it returns an empty Map.- Since:
- 8.0.2
-
-