public class ContextTag extends javax.servlet.jsp.tagext.TagSupport implements javax.servlet.jsp.tagext.TryCatchFinally, NavigatorPageIF
Use this tag as root tag for all tags defined in the Tag Libraries of the Ontopia Navigator Framework (2nd Generation).
Modifier and Type | Field and Description |
---|---|
static String |
TOPICMAPID_REQUEST_ATTRIBUTE |
Constructor and Description |
---|
ContextTag() |
Modifier and Type | Method and Description |
---|---|
void |
_setTopicMap(TopicMapIF topicmap)
Special setter used only for unit testing purposes.
|
void |
doCatch(Throwable t) |
int |
doEndTag()
Process the end tag for this instance.
|
void |
doFinally() |
int |
doStartTag()
Process the start tag for this instance.
|
ContextManagerIF |
getContextManager()
INTERNAL: Get the Context Manager.
|
DeclarationContextIF |
getDeclarationContext()
INTERNAL: Gets the tolog declaration context.
|
FunctionIF |
getFunction(String name)
INTERNAL: Get a function out of the register.
|
NavigatorApplicationIF |
getNavigatorApplication()
INTERNAL: Get the navigator application which allows
accessing all kind of configuration.
|
NavigatorConfigurationIF |
getNavigatorConfiguration()
INTERNAL: Get the navigator configuration for getting access
to the application.xml settings.
|
String[] |
getObjectIDs()
Get Topic map object identifiers.
|
Collection |
getObjects()
Gets the topic map objects retrieved by the context tag.
|
String |
getObjparam() |
javax.servlet.jsp.PageContext |
getPageContext()
INTERNAL: Gets the JSP page context which allows to have access
to further request relevant information.
|
QueryProcessorIF |
getQueryProcessor()
INTERNAL: Get the tolog query processor the context tag is working with.
|
QueryResultIF |
getQueryResult(String name) |
String |
getTmparam() |
TopicMapIF |
getTopicMap()
INTERNAL: Get the topicmap object the context tag is working with.
|
String |
getTopicMapId() |
TopicMapRepositoryIF |
getTopicMapRepository() |
void |
registerFunction(FunctionIF function)
INTERNAL: Add a function to the registry.
|
void |
registerFunction(String name,
FunctionIF function)
INTERNAL: Add a named function to the registry.
|
void |
registerQueryResult(String name,
QueryResultIF queryResult) |
void |
setContextManager(ContextManagerIF ctxtmgr)
Special setter used only for unit testing purposes.
|
void |
setDeclarationContext(DeclarationContextIF declarationContext) |
void |
setObjparam(String objParam)
If set, it tells the tag what request parameter contains
the object ID of the object to set as the value of the default
variable.
|
void |
setReadonly(boolean readonly)
A boolean flag to tell the tag to fetch a read-only or a
read-write topic map.
|
void |
setSet(String varObjName)
The variable name which the object will be set as the
value of.
|
void |
setSettm(String varTMName)
The variable name which the topic map will be set as the
value of.
|
void |
setTmparam(String tmParam)
Tells the tag which request parameter contains the
ID of the topic map in the context.
|
void |
setTopicmap(String topicmap)
If set, the ID taken from this attribute is the ID of
the topic map.
|
public static String TOPICMAPID_REQUEST_ATTRIBUTE
public int doStartTag() throws javax.servlet.jsp.JspTagException
doStartTag
in interface javax.servlet.jsp.tagext.Tag
doStartTag
in class javax.servlet.jsp.tagext.TagSupport
javax.servlet.jsp.JspTagException
public int doEndTag() throws javax.servlet.jsp.JspTagException
doEndTag
in interface javax.servlet.jsp.tagext.Tag
doEndTag
in class javax.servlet.jsp.tagext.TagSupport
javax.servlet.jsp.JspTagException
public void setTmparam(String tmParam)
tmParam
- String which specifies a
Request parameter name.public String getTmparam()
public void setObjparam(String objParam)
objParam
- String which specifies a
Request parameter name.public String getObjparam()
public void setSet(String varObjName)
varObjName
- String which specifies a variable name
for the object.public void setSettm(String varTMName)
varTMName
- String which specifies a variable name
for the topicmap.public void setTopicmap(String topicmap)
topicmap
- String which specifies a Topic map ID.public void setReadonly(boolean readonly)
readonly
- boolean value; true if read-only. The default is true.public String[] getObjectIDs()
public Collection getObjects()
public ContextManagerIF getContextManager()
NavigatorPageIF
getContextManager
in interface NavigatorPageIF
public void registerFunction(FunctionIF function)
NavigatorPageIF
registerFunction
in interface NavigatorPageIF
function
- The function to be added to the internal registry;
An object implementing FunctionIF.public void registerFunction(String name, FunctionIF function)
NavigatorPageIF
registerFunction
in interface NavigatorPageIF
name
- The name with which the function is to be registered.function
- The function to be added to the internal registry;
An object implementing FunctionIF.public FunctionIF getFunction(String name)
NavigatorPageIF
getFunction
in interface NavigatorPageIF
name
- The string which identifies the name of the function.public void registerQueryResult(String name, QueryResultIF queryResult)
public QueryResultIF getQueryResult(String name)
public TopicMapRepositoryIF getTopicMapRepository()
public NavigatorApplicationIF getNavigatorApplication()
NavigatorPageIF
getNavigatorApplication
in interface NavigatorPageIF
public NavigatorConfigurationIF getNavigatorConfiguration()
NavigatorPageIF
getNavigatorConfiguration
in interface NavigatorPageIF
public TopicMapIF getTopicMap()
NavigatorPageIF
getTopicMap
in interface NavigatorPageIF
public String getTopicMapId()
public QueryProcessorIF getQueryProcessor()
NavigatorPageIF
getQueryProcessor
in interface NavigatorPageIF
public javax.servlet.jsp.PageContext getPageContext()
NavigatorPageIF
getPageContext
in interface NavigatorPageIF
public DeclarationContextIF getDeclarationContext()
NavigatorPageIF
getDeclarationContext
in interface NavigatorPageIF
public void setDeclarationContext(DeclarationContextIF declarationContext)
public void doCatch(Throwable t) throws Throwable
doCatch
in interface javax.servlet.jsp.tagext.TryCatchFinally
Throwable
public void doFinally()
doFinally
in interface javax.servlet.jsp.tagext.TryCatchFinally
public void _setTopicMap(TopicMapIF topicmap)
public void setContextManager(ContextManagerIF ctxtmgr)