|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.cc.framework.ui.model.imp.ClientHandlerImp com.cc.framework.ui.model.imp.DesignRuleImp
A design rule is used to modify the properties of a design model at runtime based on a rule
Field Summary | |
private DeferredEnvironment |
env
Expression Language Environment. |
private java.lang.String |
rule
The rule. |
private static long |
serialVersionUID
Serial Version UID |
private DeferredValue |
style
Html-Style |
private DeferredValue |
styleClass
Style Class -> HTML class Attribut |
private DeferredValue |
styleId
Style ID |
Fields inherited from class com.cc.framework.ui.model.imp.ClientHandlerImp |
|
Constructor Summary | |
DesignRuleImp()
Constructor |
Method Summary | |
void |
applyDesign(javax.servlet.jsp.PageContext ctx,
org.apache.ecs.ConcreteElement element,
java.lang.Object bean)
This method searches for all matching rules and applies the design to the given HTML element |
DeferredEnvironment |
getEnvironment()
retrieves the current EL Environment for the current row |
java.lang.String |
getRule()
Returns the rule |
java.lang.String |
getStyle()
Returns the Style |
java.lang.String |
getStyleClass()
Returns the StyleClass |
java.lang.String |
getStyleId()
returns the StyleId |
boolean |
match()
Matches the rule against the beans properties. |
void |
setEnvironment(DeferredEnvironment env)
Sets the EL Environment to evaluate EL Expressions in the context of the current row bean |
DesignRule |
setRule(java.lang.String rule)
Sets the rule. |
DesignRule |
setStyle(java.lang.String style)
Sets the Style |
DesignRule |
setStyleClass(java.lang.String styleClass)
Sets the StyleClass |
DesignRule |
setStyleId(java.lang.String styleId)
Sets the StyleId |
Methods inherited from class com.cc.framework.ui.model.imp.ClientHandlerImp |
evaluate, getHandler, getHandlers, setHandler |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.cc.framework.ui.model.ClientHandler |
getHandler, getHandlers, setHandler |
Field Detail |
private static final long serialVersionUID
private transient DeferredEnvironment env
private java.lang.String rule
private DeferredValue styleId
private DeferredValue styleClass
private DeferredValue style
Constructor Detail |
public DesignRuleImp()
Method Detail |
public void setEnvironment(DeferredEnvironment env)
setEnvironment
in interface DesignRule
env
- Environmentpublic DeferredEnvironment getEnvironment()
getEnvironment
in interface DesignRule
null
public java.lang.String getRule()
DesignRule
getRule
in interface DesignRule
DesignRule.getRule()
public DesignRule setRule(java.lang.String rule)
DesignRule
setRule
in interface DesignRule
rule
- The rule to set
DesignRule.setRule(java.lang.String)
public boolean match() throws java.lang.Exception
DesignRule
match
in interface DesignRule
true
if the bean matches the rule
java.lang.Exception
- is thrown in case of an errorDesignRule.match()
public void applyDesign(javax.servlet.jsp.PageContext ctx, org.apache.ecs.ConcreteElement element, java.lang.Object bean) throws java.lang.Exception
DesignRule
applyDesign
in interface DesignRule
ctx
- JSP Page contextelement
- the HTML element to modifybean
- the bean that holds the values to check
java.lang.Exception
- is thrown in case of an errorDesignRule.applyDesign(javax.servlet.jsp.PageContext, org.apache.ecs.ConcreteElement, java.lang.Object)
public java.lang.String getStyle()
DesignRule
getStyle
in interface DesignRule
DesignRule.getStyle()
public java.lang.String getStyleClass()
DesignRule
getStyleClass
in interface DesignRule
DesignRule.getStyleClass()
public java.lang.String getStyleId()
DesignRule
getStyleId
in interface DesignRule
DesignRule.getStyleId()
public DesignRule setStyle(java.lang.String style)
DesignRule
setStyle
in interface DesignRule
style
- style constant
DesignRule.setStyle(java.lang.String)
public DesignRule setStyleClass(java.lang.String styleClass)
DesignRule
setStyleClass
in interface DesignRule
styleClass
- StyleClass
DesignRule.setStyleClass(java.lang.String)
public DesignRule setStyleId(java.lang.String styleId)
DesignRule
setStyleId
in interface DesignRule
styleId
- HTML-Id of the element
DesignRule.setStyleId(java.lang.String)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |