| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
DEFAULT_PORTLET_MODE |
static java.lang.String |
PORTLETCONTEXT_NONE |
static java.util.regex.Pattern |
PORTLETNAME_PATTERN |
static java.lang.String |
REQATTRIB_FIRED_PORTLET_EVENTS |
TMLContext |
tmlContext |
| Constructor and Description |
|---|
TMLPortlet() |
TMLPortlet(TMLContext tmlContext,
TMLUserProfile profile,
de.innovationgate.webgate.api.WGPortlet portlet) |
| Modifier and Type | Method and Description |
|---|---|
void |
changeDesign(java.lang.String tml) |
TMLPortlet |
child(java.lang.String name)
Returns a child portlet of the given name
|
void |
cleanup()
Clears the portlet configuration and state
|
void |
cleanup(java.lang.String portletKey) |
void |
clearchildstate(java.lang.String name)
Clears the state of a child portlet
|
void |
clearstate()
Clears the portlet state
|
boolean |
equals(java.lang.Object obj) |
void |
fireevent(PortletEvent event)
Fires a portlet event
|
void |
fireevent(java.lang.String eventname)
Fires a new portlet event of the given name
|
void |
fireevent(java.lang.String eventName,
java.util.Map<java.lang.String,java.lang.Object> params)
Fires a new portlet event of the given name with the given parameters
|
void |
forcestate()
Forces a state on a portlet
|
de.innovationgate.webgate.api.WGDocument |
getapiobject() |
java.util.List<java.lang.String> |
getchildrenkeys() |
java.util.List<java.lang.String> |
getchildrennames()
Returns the names of registered child portlets
|
TMLContext |
getcontext()
Gets the portlet context
|
java.lang.Object |
getcontroller() |
Design |
getControllerDesign() |
java.util.List<java.lang.String> |
getdescendantkeys() |
java.util.List<java.lang.String> |
getdescendantnames() |
java.lang.String |
getDesign() |
static org.apache.commons.collections.map.LinkedMap |
getFiredEventsQueue(javax.servlet.http.HttpSession session)
Queue that stores the last 1000 fired portlet events, so portlets can
react on them with serverside code.
|
java.util.List<java.lang.String> |
getitemnames()
Returns the names of items on this portlet configuration
|
java.lang.String |
getmode()
Returns the current portlet mode
|
java.lang.String |
getname()
Returns the name of the portlet
|
java.lang.String |
getparentkey() |
TMLPortlet |
getparentportlet() |
TMLPortlet |
getportlet(java.lang.String key) |
TMLPortlet |
getportletforname(java.lang.String name) |
java.lang.String |
getportletkey()
Returns the title.
|
java.lang.String |
getportletpath()
Returns the absolute path of this portlet, consisting of a path of from names of all portlets up to the root
|
de.innovationgate.webgate.api.WGPortlet |
getPortletRegistration(java.lang.String key) |
TMLUserProfile |
getProfile() |
de.innovationgate.webgate.api.WGPortlet |
getReg() |
TMLPortlet |
getroot()
Retrieves the root portlet
|
java.lang.Object |
getsessionvar(java.lang.String name)
Retrieves the value of a WebTML portlet session variable
|
TMLPortlet |
getsourceportlet(PortletEvent event)
Returns the portlet that threw a portlet event
|
TMLPortletState |
getState() |
java.lang.String |
gettitle() |
java.lang.String |
gettml()
Returns the name of the layout WebTML module for this portlet
|
java.lang.String |
gettmldb()
Returns the key of the application containing the layout module of this portlet
|
java.lang.Object |
getvar(java.lang.String name)
Retrieves the value of a normal WebTML portlet variable
|
java.lang.String |
getVarPrefix() |
static java.lang.String |
getVarPrefix(java.lang.String portletKey) |
int |
hashCode() |
boolean |
hasitem(java.lang.String name)
Tests if an item exists on the portlet configuration
|
boolean |
hassessionvar(java.lang.String name) |
boolean |
iscontextset() |
boolean |
isprovisionalstate() |
boolean |
isroot()
Shows if this portlet is the root portlet
|
java.lang.Object |
item(java.lang.String name)
Returns the value of an item from portlet configuration as a single value
|
java.util.List<java.lang.Object> |
itemlist(java.lang.String name)
Returns the value of an item from portlet configuration as a list value
|
void |
markedited() |
java.lang.Object |
meta(java.lang.String name) |
java.util.List<java.lang.Object> |
metalist(java.lang.String name) |
TMLPortlet |
parent()
Returns the parent portlet.
|
void |
prepareEventProcessing(Base tag) |
java.lang.String |
registerportlet(java.lang.String tmlCode,
java.lang.String title) |
java.lang.String |
registerportlet(java.lang.String tmlDb,
java.lang.String tmlCode,
java.lang.String title) |
java.lang.String |
registerportletforname(java.lang.String name,
DesignResourceReference ref,
boolean overwrite) |
java.lang.String |
registerportletforname(java.lang.String name,
java.lang.String module)
Registers a new child portlet
|
java.lang.String |
registerportletforname(java.lang.String name,
java.lang.String module,
boolean overwrite)
Registers a new child portlet
|
java.lang.String |
registerportletforname(java.lang.String name,
java.lang.String moduleDb,
java.lang.String module)
Registers a new child portlet
|
java.lang.String |
registerportletforname(java.lang.String name,
java.lang.String appDbKey,
java.lang.String resourceName,
boolean overwrite)
Registers a new child portlet
|
void |
removeitem(java.lang.String name)
Removes an item from portlet configuration
|
void |
removesessionvar(java.lang.String name)
Removes a WebTML portlet session variable
|
void |
removevar(java.lang.String name)
Removes a WebTML portlet variable
|
java.lang.Object |
retrieveSessionVar(java.lang.String name) |
boolean |
save() |
void |
setcontext(Context context)
Sets the portlet context
|
boolean |
setitem(java.lang.String name,
java.lang.Object value)
Sets an item in portlet configuration
|
void |
setmode(java.lang.String mode)
Sets the current portlet mode
|
void |
setsessionvar(java.lang.String name,
java.lang.Object value)
Sets a WebTML portlet session variable.
|
void |
setsessionvar(java.lang.String name,
java.lang.Object value,
boolean allowSerialization)
Sets a WebTML portlet session variable
|
void |
setsessionvar(java.lang.String name,
java.lang.Object value,
boolean allowSerialization,
boolean keepList) |
void |
setvar(java.lang.String name,
java.lang.Object value)
Sets a WebTML portlet variable
|
void |
unregister()
Removes the current portlet from portlet registry.
|
void |
unregisterchildportlets()
Removes all child portlets from portlet registry
|
boolean |
unregisterportlet(java.lang.String portletKey) |
void |
unregisterportletforname(java.lang.String name)
Removes a child portlet from portlet registry
|
public static final java.lang.String DEFAULT_PORTLET_MODE
public static final java.util.regex.Pattern PORTLETNAME_PATTERN
public static final java.lang.String REQATTRIB_FIRED_PORTLET_EVENTS
public static final java.lang.String PORTLETCONTEXT_NONE
public TMLContext tmlContext
public TMLPortlet(TMLContext tmlContext, TMLUserProfile profile, de.innovationgate.webgate.api.WGPortlet portlet) throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic TMLPortlet()
public static org.apache.commons.collections.map.LinkedMap getFiredEventsQueue(javax.servlet.http.HttpSession session)
session - public de.innovationgate.webgate.api.WGDocument getapiobject()
getapiobject in interface TMLObjectde.innovationgate.wgpublisher.webtml.utils.TMLObject#getAPIObject()public java.lang.Object item(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
Portletpublic java.util.List<java.lang.Object> itemlist(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
Portletpublic boolean hasitem(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
Portletpublic java.lang.Object meta(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic java.util.List<java.lang.Object> metalist(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic boolean save()
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic boolean setitem(java.lang.String name,
java.lang.Object value)
throws de.innovationgate.webgate.api.WGAPIException
Portletpublic void setvar(java.lang.String name,
java.lang.Object value)
throws de.innovationgate.webgate.api.WGAPIException
Portletpublic java.lang.Object getvar(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
Portletpublic void removevar(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
Portletpublic void setsessionvar(java.lang.String name,
java.lang.Object value)
throws de.innovationgate.webgate.api.WGAPIException
Portletsetsessionvar in interface Portletname - Name of the variablevalue - Value of the variablede.innovationgate.webgate.api.WGAPIExceptionpublic java.lang.Object getsessionvar(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
Portletgetsessionvar in interface Portletname - Name of the variablede.innovationgate.webgate.api.WGAPIExceptionpublic boolean hassessionvar(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic java.lang.Object retrieveSessionVar(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic void setsessionvar(java.lang.String name,
java.lang.Object value,
boolean allowSerialization)
throws de.innovationgate.webgate.api.WGAPIException
Portletsetsessionvar in interface Portletname - Name of the variablevalue - Value of the variableallowSerialization - Controls if this variable should be serialized to other cluster nodes in a server cluster. This is only possible if the value type is serializable.de.innovationgate.webgate.api.WGAPIExceptionpublic void setsessionvar(java.lang.String name,
java.lang.Object value,
boolean allowSerialization,
boolean keepList)
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic void removesessionvar(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
Portletremovesessionvar in interface Portletname - Name of the variablede.innovationgate.webgate.api.WGAPIExceptionpublic void removeitem(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
Portletremoveitem in interface Portletname - Name of the itemde.innovationgate.webgate.api.WGAPIExceptionpublic TMLPortlet getportlet(java.lang.String key) throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic de.innovationgate.webgate.api.WGPortlet getPortletRegistration(java.lang.String key)
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic TMLPortlet getparentportlet() throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic java.util.List<java.lang.String> getchildrenkeys()
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic java.util.List<java.lang.String> getdescendantkeys()
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic java.util.List<java.lang.String> getchildrennames()
throws de.innovationgate.webgate.api.WGAPIException
Portletgetchildrennames in interface Portletde.innovationgate.webgate.api.WGAPIExceptionpublic java.util.List<java.lang.String> getdescendantnames()
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic java.lang.String registerportlet(java.lang.String tmlDb,
java.lang.String tmlCode,
java.lang.String title)
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic java.lang.String registerportlet(java.lang.String tmlCode,
java.lang.String title)
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic boolean unregisterportlet(java.lang.String portletKey)
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic void unregister()
throws de.innovationgate.webgate.api.WGAPIException
Portletunregister in interface Portletde.innovationgate.webgate.api.WGAPIExceptionpublic void cleanup()
throws de.innovationgate.webgate.api.WGAPIException
Portletpublic void clearstate()
throws de.innovationgate.webgate.api.WGAPIException
Portletclearstate in interface Portletde.innovationgate.webgate.api.WGAPIExceptionpublic void forcestate()
throws de.innovationgate.webgate.api.WGAPIException
Portletforcestate in interface Portletde.innovationgate.webgate.api.WGAPIExceptionpublic void clearchildstate(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
Portletclearchildstate in interface Portletname - The portlet namede.innovationgate.webgate.api.WGAPIExceptionpublic void cleanup(java.lang.String portletKey)
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic java.lang.String getportletkey()
public java.lang.String getparentkey()
public java.lang.String gettml()
Portletpublic java.lang.String gettmldb()
Portletpublic java.util.List<java.lang.String> getitemnames()
throws de.innovationgate.webgate.api.WGAPIException
Portletgetitemnames in interface Portletde.innovationgate.webgate.api.WGAPIExceptionpublic java.lang.String gettitle()
public java.lang.String getname()
Portletpublic java.lang.String getmode()
throws de.innovationgate.webgate.api.WGAPIException
Portletpublic TMLPortletState getState() throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic java.lang.Object getcontroller()
throws de.innovationgate.webgate.api.WGAPIException,
de.innovationgate.webgate.api.WGException
getcontroller in interface Portletde.innovationgate.webgate.api.WGAPIExceptionde.innovationgate.webgate.api.WGExceptionpublic static java.lang.String getVarPrefix(java.lang.String portletKey)
public void setmode(java.lang.String mode)
throws de.innovationgate.webgate.api.WGAPIException
Portletpublic void changeDesign(java.lang.String tml)
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic java.lang.String getDesign()
public void fireevent(PortletEvent event)
Portletpublic void fireevent(java.lang.String eventname)
Portletpublic void fireevent(java.lang.String eventName,
java.util.Map<java.lang.String,java.lang.Object> params)
Portletpublic java.lang.String registerportletforname(java.lang.String name,
DesignResourceReference ref,
boolean overwrite)
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic java.lang.String registerportletforname(java.lang.String name,
java.lang.String appDbKey,
java.lang.String resourceName,
boolean overwrite)
throws de.innovationgate.webgate.api.WGException
Portletregisterportletforname in interface Portletname - Name by which the portlet is registered. May consist of alphanumeric characters, dots, underlines and colons.appDbKey - Database key of the application that hosts the WebTML module to use for portlet layout. Omit to use the current WebTML design application.resourceName - Name of the WebTML module to use for portlet layoutoverwrite - Controls if an already existing portlet registration may be overwritten. If false an error is thrown when the given name is already registered.de.innovationgate.webgate.api.WGExceptionpublic java.lang.String registerportletforname(java.lang.String name,
java.lang.String module,
boolean overwrite)
throws de.innovationgate.webgate.api.WGException
Portletregisterportletforname in interface Portletname - Name by which the portlet is registered. May consist of alphanumeric characters, dots, underlines and colons.module - Name of the WebTML module to use for portlet layoutoverwrite - Controls if an already existing portlet registration may be overwritten. If false an error is thrown when the given name is already registered.de.innovationgate.webgate.api.WGExceptionpublic java.lang.String registerportletforname(java.lang.String name,
java.lang.String module)
throws de.innovationgate.webgate.api.WGException
Portletregisterportletforname in interface Portletname - Name by which the portlet is registered. May consist of alphanumeric characters, dots, underlines and colons.module - Name of the WebTML module to use for portlet layout.de.innovationgate.webgate.api.WGExceptionpublic java.lang.String registerportletforname(java.lang.String name,
java.lang.String moduleDb,
java.lang.String module)
throws de.innovationgate.webgate.api.WGException
Portletregisterportletforname in interface Portletname - Name by which the portlet is registered. May consist of alphanumeric characters, dots, underlines and colons.moduleDb - Database key of the application that hosts the WebTML module to use for portlet layout. Omit to use the current WebTML design application.module - Name of the WebTML module to use for portlet layoutde.innovationgate.webgate.api.WGExceptionpublic TMLPortlet getportletforname(java.lang.String name) throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic void unregisterportletforname(java.lang.String name)
throws de.innovationgate.webgate.api.WGAPIException
Portletunregisterportletforname in interface Portletname - Name of the child portletde.innovationgate.webgate.api.WGAPIExceptionpublic void unregisterchildportlets()
throws de.innovationgate.webgate.api.WGAPIException
Portletunregisterchildportlets in interface Portletde.innovationgate.webgate.api.WGAPIExceptionpublic void prepareEventProcessing(Base tag) throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic boolean isroot()
Portletpublic TMLPortlet getroot() throws de.innovationgate.webgate.api.WGAPIException
Portletpublic TMLPortlet parent() throws de.innovationgate.webgate.api.WGAPIException
Portletpublic TMLPortlet child(java.lang.String name) throws de.innovationgate.webgate.api.WGAPIException
Portletpublic TMLContext getcontext() throws de.innovationgate.webgate.api.WGAPIException
Portletgetcontext in interface Portletde.innovationgate.webgate.api.WGAPIExceptionpublic boolean iscontextset()
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic boolean isprovisionalstate()
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic void setcontext(Context context) throws de.innovationgate.webgate.api.WGAPIException
Portletsetcontext in interface Portletde.innovationgate.webgate.api.WGAPIExceptionpublic java.lang.String getVarPrefix()
public TMLPortlet getsourceportlet(PortletEvent event) throws de.innovationgate.webgate.api.WGAPIException
Portletgetsourceportlet in interface Portletevent - The portlet eventde.innovationgate.webgate.api.WGAPIExceptionpublic de.innovationgate.webgate.api.WGPortlet getReg()
public java.lang.String getportletpath()
throws de.innovationgate.webgate.api.WGAPIException
Portletgetportletpath in interface Portletde.innovationgate.webgate.api.WGAPIExceptionpublic TMLUserProfile getProfile()
public boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic void markedited()
throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIExceptionpublic Design getControllerDesign() throws de.innovationgate.webgate.api.WGAPIException
de.innovationgate.webgate.api.WGAPIException