|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.servlet.jsp.tagext.SimpleTagSupport
nl.gx.webmanager.taglib.ObjectTag
public class ObjectTag
Implements the wm:object tag. Retrieves an object from the content database.
In GX WebManager, the content database is filled with objects that have an id and a type.
For GX WebManager objects that are exposed through the Java API, wrapper classes are available
that encapsulate the data that is stored in the content database. The public API of these wrapper
classes is defined in interfaces. The < wm:object > tag can be used as a factory for
creating wrapper objects based on the type and objectid. The type is the fully qualified class
name of the wrapper interface. If no wrapper object can be created (either the id or the type
is wrong), the value null is used.
Example of usage:
< wm:object var="message" objectId="${param.message}"
objectType="nl.gx.webmanager.cms.forum.ForumMessage" />
< wm:render object="${message}" />
The example above assigns a ForumMessage object to the variable 'message'. Some tags like,
for example, < wm:render > have an attribute object. The variable may be used in such tags.
| Constructor Summary | |
|---|---|
ObjectTag()
|
|
| Method Summary | |
|---|---|
void |
doTag()
|
protected int |
getObjectId()
Return the numerical id of the object to retrieve. |
protected java.lang.String |
getObjectType()
Return the Java class of the object to retrieve. |
protected java.lang.String |
getVar()
Return the JSP variable to store the result in. |
void |
setObjectId(int objectId)
Sets the numerical id of the object to retrieve. |
void |
setObjectType(java.lang.String objectType)
Specifies the Java class of the object to retrieve. |
void |
setVar(java.lang.String var)
Specifies the JSP variable to store the result in. |
| Methods inherited from class javax.servlet.jsp.tagext.SimpleTagSupport |
|---|
findAncestorWithClass, getJspBody, getJspContext, getParent, setJspBody, setJspContext, setParent |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ObjectTag()
| Method Detail |
|---|
public void setVar(java.lang.String var)
var - name of the jsp variable to which the object will be assigned.protected java.lang.String getVar()
public void setObjectId(int objectId)
objectId - the numerical id of the object to retrieve.protected int getObjectId()
public void setObjectType(java.lang.String objectType)
objectType - the objecttype of the objectprotected java.lang.String getObjectType()
public void doTag()
doTag in interface javax.servlet.jsp.tagext.SimpleTagdoTag in class javax.servlet.jsp.tagext.SimpleTagSupport
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||