public abstract class LwComponent extends java.lang.Object implements IComponent
Modifier and Type | Field and Description |
---|---|
protected java.util.HashMap |
myClientProperties |
protected java.util.HashMap |
myDelegeeClientProperties |
Constructor and Description |
---|
LwComponent(java.lang.String className) |
Modifier and Type | Method and Description |
---|---|
boolean |
accept(ComponentVisitor visitor) |
boolean |
areChildrenExclusive()
Returns true if only one of the children of the component can be visible at a time
(for example, the component is a tabbed pane or a container with CardLayout).
|
LwIntrospectedProperty[] |
getAssignedIntrospectedProperties() |
java.lang.String |
getBinding() |
java.awt.Rectangle |
getBounds() |
java.lang.Object |
getClientProperty(java.lang.Object key) |
java.lang.String |
getComponentClassName() |
GridConstraints |
getConstraints() |
java.lang.Object |
getCustomLayoutConstraints() |
java.util.HashMap |
getDelegeeClientProperties() |
Element |
getErrorComponentProperties() |
java.lang.String |
getId() |
IProperty[] |
getModifiedProperties() |
LwContainer |
getParent() |
IContainer |
getParentContainer() |
java.lang.Object |
getPropertyValue(LwIntrospectedProperty property) |
boolean |
isCustomCreate() |
boolean |
isDefaultBinding() |
void |
putClientProperty(java.lang.Object key,
java.lang.Object value) |
abstract void |
read(Element element,
PropertiesProvider provider) |
protected void |
readBase(Element element)
'id' is required attribute
'binding' is optional attribute
|
protected void |
readConstraints(Element element)
Delegates reading of constraints to the parent container
|
protected void |
readProperties(Element element,
PropertiesProvider provider)
'properties' is not required subtag
|
void |
setBinding(java.lang.String binding) |
void |
setBounds(java.awt.Rectangle bounds) |
void |
setCustomLayoutConstraints(java.lang.Object customLayoutConstraints) |
void |
setId(java.lang.String id) |
protected void |
setParent(LwContainer parent) |
void |
setPropertyValue(LwIntrospectedProperty property,
java.lang.Object value) |
protected final java.util.HashMap myClientProperties
protected final java.util.HashMap myDelegeeClientProperties
public final java.lang.String getId()
getId
in interface IComponent
public final void setId(java.lang.String id)
public final java.lang.String getBinding()
getBinding
in interface IComponent
null
if the component is not bound to any field.public final void setBinding(java.lang.String binding)
public final java.lang.Object getCustomLayoutConstraints()
getCustomLayoutConstraints
in interface IComponent
public final void setCustomLayoutConstraints(java.lang.Object customLayoutConstraints)
public final java.lang.String getComponentClassName()
getComponentClassName
in interface IComponent
public IProperty[] getModifiedProperties()
getModifiedProperties
in interface IComponent
public final java.awt.Rectangle getBounds()
null
.public final GridConstraints getConstraints()
getConstraints
in interface IComponent
null
.public boolean isCustomCreate()
isCustomCreate
in interface IComponent
public boolean isDefaultBinding()
public boolean accept(ComponentVisitor visitor)
accept
in interface IComponent
public boolean areChildrenExclusive()
IComponent
areChildrenExclusive
in interface IComponent
public final LwContainer getParent()
public IContainer getParentContainer()
getParentContainer
in interface IComponent
protected final void setParent(LwContainer parent)
public final void setBounds(java.awt.Rectangle bounds)
public final java.lang.Object getPropertyValue(LwIntrospectedProperty property)
public final void setPropertyValue(LwIntrospectedProperty property, java.lang.Object value)
public final Element getErrorComponentProperties()
null
only if component class is not valid.
Class validation is performed with Utils.validateJComponentClass(ClassLoader,String,boolean)
public final LwIntrospectedProperty[] getAssignedIntrospectedProperties()
protected final void readBase(Element element)
protected final void readProperties(Element element, PropertiesProvider provider)
provider
- can be null if no properties should be readprotected final void readConstraints(Element element)
public abstract void read(Element element, PropertiesProvider provider) throws java.lang.Exception
provider
- can be null if no component classes should not be createdjava.lang.Exception
public final java.lang.Object getClientProperty(java.lang.Object key)
getClientProperty
in interface IComponent
JComponent.getClientProperty(Object)
public final void putClientProperty(java.lang.Object key, java.lang.Object value)
putClientProperty
in interface IComponent
JComponent.putClientProperty(Object, Object)
public java.util.HashMap getDelegeeClientProperties()