|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.turbine.util.uri.BaseURI
org.apache.turbine.util.uri.TurbineURI
org.apache.turbine.util.uri.TemplateURI
public class TemplateURI
This class allows you to keep all the information needed for a single link at one place. It keeps your query data, path info, the server scheme, name, port and the script path. It is tuned for usage with a Template System e.g. Velocity. If you must generate a Turbine Link in a Template System, use this class.
| Field Summary |
|---|
| Fields inherited from interface org.apache.turbine.util.uri.URIConstants |
|---|
CGI_ACTION_PARAM, CGI_SCREEN_PARAM, CGI_TEMPLATE_PARAM, EVENT_PREFIX, FTP_PORT, HTTP, HTTP_PORT, HTTPS, HTTPS_PORT, PATH_INFO, QUERY_DATA, URI_SCHEME_SEPARATOR |
| Constructor Summary | |
|---|---|
TemplateURI()
Empty C'tor. |
|
TemplateURI(RunData runData)
Constructor with a RunData object |
|
TemplateURI(RunData runData,
boolean redirect)
Constructor, set explicit redirection |
|
TemplateURI(RunData runData,
String template)
Constructor, set Template |
|
TemplateURI(RunData runData,
String template,
boolean redirect)
Constructor, set Template, set explicit redirection |
|
TemplateURI(RunData runData,
String template,
String action)
Constructor, set Template and Action |
|
TemplateURI(RunData runData,
String template,
String action,
boolean redirect)
Constructor, set Template and Action, set explicit redirection |
|
TemplateURI(ServerData serverData)
Constructor with a ServerData object |
|
TemplateURI(ServerData serverData,
boolean redirect)
Constructor, set explicit redirection |
|
TemplateURI(ServerData serverData,
String template)
Constructor, set Template |
|
TemplateURI(ServerData serverData,
String template,
boolean redirect)
Constructor, set Template, set explicit redirection |
|
TemplateURI(ServerData serverData,
String template,
String action)
Constructor, set Template and Action |
|
TemplateURI(ServerData serverData,
String template,
String action,
boolean redirect)
Constructor, set Template and Action, set explicit redirection |
|
TemplateURI(String template,
String action)
Constructor, user Turbine.getDefaultServerData(), set Template and Action |
|
| Method Summary | |
|---|---|
protected void |
add(int type,
org.apache.fulcrum.parser.ParameterParser pp)
Method for a quick way to add all the parameters in a ParameterParser. |
void |
clearTemplate()
Clears the template= value for this URL. |
void |
setTemplate(String template)
Sets the template= value for this URL. |
| Methods inherited from class org.apache.turbine.util.uri.TurbineURI |
|---|
add, add, addPathInfo, addPathInfo, addPathInfo, addPathInfo, addPathInfo, addPathInfo, addPathInfo, addQueryData, addQueryData, addQueryData, addQueryData, addQueryData, addQueryData, addQueryData, clearAction, clearResponse, clearScreen, getAbsoluteLink, getPathInfo, getQueryData, getRelativeLink, hasPathInfo, hasQueryData, remove, removePathInfo, removePathInfo, removeQueryData, removeQueryData, setAction, setActionEvent, setEvent, setPathInfo, setQueryData, setScreen, toString |
| Methods inherited from class org.apache.turbine.util.uri.BaseURI |
|---|
encodeResponse, getContextAndScript, getContextPath, getReference, getResponse, getSchemeAndPort, getScriptName, getServerName, getServerPort, getServerScheme, hasReference, isRedirect, setContextPath, setRedirect, setReference, setResponse, setScriptName, setSecure, setSecure, setServerName, setServerPort, setServerScheme |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public TemplateURI()
public TemplateURI(RunData runData)
runData - A RunData object
public TemplateURI(RunData runData,
boolean redirect)
runData - A RunData objectredirect - True if redirection allowed.
public TemplateURI(RunData runData,
String template)
runData - A RunData objecttemplate - A Template Name
public TemplateURI(RunData runData,
String template,
boolean redirect)
runData - A RunData objecttemplate - A Template Nameredirect - True if redirection allowed.
public TemplateURI(RunData runData,
String template,
String action)
runData - A RunData objecttemplate - A Template Nameaction - An Action Name
public TemplateURI(RunData runData,
String template,
String action,
boolean redirect)
runData - A RunData objecttemplate - A Template Nameaction - An Action Nameredirect - True if redirection allowed.public TemplateURI(ServerData serverData)
serverData - A ServerData object
public TemplateURI(ServerData serverData,
boolean redirect)
serverData - A ServerData objectredirect - True if redirection allowed.
public TemplateURI(ServerData serverData,
String template)
serverData - A ServerData objecttemplate - A Template Name
public TemplateURI(ServerData serverData,
String template,
boolean redirect)
serverData - A ServerData objecttemplate - A Template Nameredirect - True if redirection allowed.
public TemplateURI(ServerData serverData,
String template,
String action)
serverData - A ServerData objecttemplate - A Template Nameaction - An Action Name
public TemplateURI(ServerData serverData,
String template,
String action,
boolean redirect)
serverData - A ServerData objecttemplate - A Template Nameaction - An Action Nameredirect - True if redirection allowed.
public TemplateURI(String template,
String action)
template - A Template Nameaction - An Action Name| Method Detail |
|---|
public void setTemplate(String template)
template - A String with the template value.public void clearTemplate()
protected void add(int type,
org.apache.fulcrum.parser.ParameterParser pp)
If the type is P (0), then add name/value to the pathInfo hashtable.
If the type is Q (1), then add name/value to the queryData hashtable.
add in class TurbineURItype - Type of insertion (@see #add(char type, String name, String value))pp - A ParameterParser.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||