|
Web Dynpro API Documentation | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Functionality that is common to all elements in any context node and that can be used by Web Dynpro applications. While this class is used when programming dynamically, more convenient, typed subinterfaces of this interface are generated for context nodes whose structure is declared within the Web Dynpro Development Workbench.
| Method Summary | |
void |
changed(java.lang.String attributeName)
Sets the changed flag for this element. |
java.lang.String |
getAttributeAsText(java.lang.String attributeName)
Returns the value of the attribute with the given name formatted using the session locale. |
java.lang.Object |
getAttributeValue(java.lang.String attributeName)
Returns the value of the attribute with the given name as an Object. |
boolean |
hasModel()
Returns true if this element has a model object |
int |
index()
Returns the index of this element in the collection of its node or -1 if the element has not been assigned to a node. |
boolean |
isChanged()
Returns true if the changed flag has been set for
this element. |
boolean |
isChangedByClient()
Returns true if the changedByClient has been set
for this element. |
java.lang.Object |
model()
Returns the model object contained in this element. |
IWDNode |
node()
Returns the node this element belongs to. |
void |
setAttributeValue(java.lang.String attributeName,
java.lang.Object value)
Sets the value of the attribute with the given name to the given value. |
| Method Detail |
public IWDNode node()
null is returned.null, if
the element has been created but not yet assigned to a nodepublic int index()
public void changed(java.lang.String attributeName)
changed flag for this element. The Web Dynpro
Runtime uses that flag to determine those elements that have been changed
in a request/response cycle.
setAttributeValue(String, Object) and generated mutator methods in
generated sub interfaces of IWDNodeElement will call changed()
automatically. So applications that modify node elements don't have to call
changed() explicitly.
attributeName - The name of the changed attribute or null
to mark all attributes changed.public boolean isChanged()
true if the changed flag has been set for
this element.
Note: This flag will be used and reset by the Web Dynpro Runtime.
true if the changed has been set
for this element or false otherwise.public boolean isChangedByClient()
true if the changedByClient has been set
for this element. This flag will be set by the framework when an update
from the client arrives. It remains true until you reset all
flags in the complete context via IWDContext.resetChangedByClient().
Since this flag is kept per element, but each attribute may actually live
in a different element, Web Dynpro always marks both the mapped element and
the origin element marked if an attribute is changed. This has the
consequence that IWDContext.resetChangedByClient() must always be
called from the context in which you will look for client changes.
true if the changedByClient has been set
for this element or false otherwise.public java.lang.Object getAttributeValue(java.lang.String attributeName)
Object.attributeName - the name of the attributeObjectContextException - if no attribute with that name existssetAttributeValue(String, Object)public java.lang.String getAttributeAsText(java.lang.String attributeName)
attributeName - ContextException - if no attribute with that name existsgetAttributeValue(String)
public void setAttributeValue(java.lang.String attributeName,
java.lang.Object value)
attributeName - the name of the attributevalue - the attribute value with the given name as an ObjectContextException - if no attribute with that name existsClassCastException - if the class of value does not
match the declared class for the attributegetAttributeValue(String)public boolean hasModel()
true if this element has a model objecttrue if this element has a model objectpublic java.lang.Object model()
ContextException - if this element is not a model node element
|
Web Dynpro API Documentation | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||