|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--com.hp.hpl.swade.portal.VMRenderManager
Render manager version for the velocity subsystem. Through this templates get access to global model state information and useful formatting utilities.
| Nested Class Summary | |
static class |
VMRenderManager.LinkDef
Structure used to hold a link definition, contains a name and a link address. |
| Field Summary | |
protected FilterState |
context
The filter context for the data source being rendered. |
protected javax.servlet.http.HttpServletRequest |
request
The request being processed - useful for finding context paths |
| Constructor Summary | |
VMRenderManager(FilterState context,
javax.servlet.http.HttpServletRequest request)
Constructor |
|
| Method Summary | |
java.lang.Integer |
asInt(java.lang.String s)
This is stupid but I can't see how velocity converts from strings to ints so do it here. |
RelationGraph |
createRelationGraph(ResourceWrapper resource,
int depthLimit)
Return a RelationGraph object on the current resource and relation set that can, in turn, be used to render a display of the relations graph. |
DataSource |
getDataSource()
Return the data source which this instance is rendering. |
java.util.Collection |
getDataSources()
Return a collection of all available data sources. |
FilterState |
getFilterContext()
Return the current filter context for the data source being rendered. |
java.lang.String |
getLinkFor(ResourceWrapper rw)
Return the link address to use for viewing a single resource in the current data source. |
ResourceWrapper |
getLinkTarget()
Return the wrapped resource that is to be linked to or null if there is none |
java.lang.String |
getMapRectFor(ResourceWrapper resource,
RelationGraph graph)
Return the coordinates of the rectangle for the given resources in the given visualization graph, formatted for using in an HTML image map. |
java.util.Collection |
getRelations()
Return a list of wrapper resources representing the available relations |
NodeWrapper |
getResourceParam(java.lang.String key)
Return an encoded parameter as a wrapped resource or null if it does not exist. |
java.lang.String |
getStyleSheet()
Return the path name for the style sheet used for view of the data source. |
java.util.Collection |
getVertices(RelationGraph graph)
Return the list of resources visualized in this map as a collection of ResourceWrappers |
java.lang.String |
getViewer()
Return the base pathname for the main viewing servlet, with action appropriate for viewing the current datasource |
java.lang.String |
getViewerPath(java.lang.String action)
Return the base pathname for the main viewing servlet with the given action parameter. |
java.lang.String |
getViewerPathWithDS(java.lang.String action)
Return the base pathname for the main viewing servlet with the given action parameter along with a current data source. |
java.util.Collection |
getVisibleRelations()
Return a collection of relations to be visualized |
java.util.List |
getVisits()
Return a list of LinkDef objects giving the recent visits recorded for this session. |
void |
recordVisit(java.lang.String name,
java.lang.String link)
Note the a resource link in the session context. |
java.lang.String |
renderFacetBrowse(ResourceWrapper facet,
java.lang.String annotation)
Renders a facet definition in nanotree-compatible javascript form. |
java.lang.String |
renderRelationGraph(RelationGraph graph)
Render a relation graph into a temporary image file and return the URL through which that file can be found. |
void |
setLinkTarget(ResourceWrapper target)
Note a wrapped resource that is to be linked to. |
boolean |
shouldShowRelation(ResourceWrapper relation)
Test whether the given relation is set to be visualized according to the current session state. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected FilterState context
protected javax.servlet.http.HttpServletRequest request
| Constructor Detail |
public VMRenderManager(FilterState context,
javax.servlet.http.HttpServletRequest request)
| Method Detail |
public java.lang.String getStyleSheet()
public DataSource getDataSource()
public FilterState getFilterContext()
public java.lang.String getViewerPath(java.lang.String action)
public java.lang.String getViewerPathWithDS(java.lang.String action)
public java.lang.String getViewer()
public java.lang.String getLinkFor(ResourceWrapper rw)
public java.util.Collection getDataSources()
public NodeWrapper getResourceParam(java.lang.String key)
public void recordVisit(java.lang.String name,
java.lang.String link)
public java.util.List getVisits()
public void setLinkTarget(ResourceWrapper target)
public ResourceWrapper getLinkTarget()
public java.lang.Integer asInt(java.lang.String s)
public java.lang.String renderFacetBrowse(ResourceWrapper facet,
java.lang.String annotation)
annotation - set to "enc" for including the encoding of the node resource,
"comment" to include the rdfs comment of the node or
"both" to include and array of both encoding and comment.public java.util.Collection getRelations()
public boolean shouldShowRelation(ResourceWrapper relation)
public java.util.Collection getVisibleRelations()
public RelationGraph createRelationGraph(ResourceWrapper resource,
int depthLimit)
public java.lang.String renderRelationGraph(RelationGraph graph)
public java.util.Collection getVertices(RelationGraph graph)
public java.lang.String getMapRectFor(ResourceWrapper resource,
RelationGraph graph)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||