public abstract class AbstractUrlMapping extends java.lang.Object implements UrlMapping
| Modifier and Type | Field and Description |
|---|---|
protected java.lang.Object |
actionName |
protected org.codehaus.groovy.grails.validation.ConstrainedProperty[] |
constraints |
protected java.lang.Object |
controllerName |
protected java.lang.Object |
forwardURI |
protected java.lang.String |
mappingName |
protected java.util.Map |
parameterValues |
protected boolean |
parseRequest |
protected java.lang.Object |
pluginName |
protected boolean |
restful |
protected javax.servlet.ServletContext |
servletContext |
protected java.lang.Object |
viewName |
ACTION, CONTROLLER| Modifier | Constructor and Description |
|---|---|
protected |
AbstractUrlMapping(java.lang.Object viewName,
org.codehaus.groovy.grails.validation.ConstrainedProperty[] constraints,
javax.servlet.ServletContext servletContext) |
|
AbstractUrlMapping(java.lang.Object controllerName,
java.lang.Object actionName,
java.lang.Object pluginName,
java.lang.Object viewName,
org.codehaus.groovy.grails.validation.ConstrainedProperty[] constraints,
javax.servlet.ServletContext servletContext)
Base constructor required to construct a UrlMapping instance
|
protected |
AbstractUrlMapping(java.net.URI uri,
org.codehaus.groovy.grails.validation.ConstrainedProperty[] constraints,
javax.servlet.ServletContext servletContext) |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
getActionName()
Retrieves the action name which is either a groovy.lang.Closure that evaluates the action
name at runtime or a java.lang.String that represents the action name
|
org.codehaus.groovy.grails.validation.ConstrainedProperty[] |
getConstraints()
The constraints the apply to this UrlMapping.
|
java.lang.Object |
getControllerName()
Retrieves the controller name which is either a groovy.lang.Closure that evaluates the controller
name at runtime or a java.lang.String that represents the controller name
|
java.lang.String |
getMappingName() |
java.lang.Object |
getPluginName() |
java.lang.Object |
getViewName()
Returns the name of the view to map to
|
boolean |
hasRuntimeVariable(java.lang.String name)
Whether the mapping has a runtime variable with the given name such as "/$foo"
|
boolean |
isRestfulMapping() |
void |
setMappingName(java.lang.String name) |
void |
setParameterValues(java.util.Map parameterValues)
Sets any parameter values that should be populated into the request
|
void |
setParseRequest(boolean shouldParse)
Sets whether this UrlMapping should parse the request
|
void |
setRestfulMapping(boolean isREST) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetUrlData, matchcreateRelativeURL, createRelativeURL, createRelativeURL, createRelativeURL, createURL, createURL, createURL, createURL, createURL, createURLprotected final org.codehaus.groovy.grails.validation.ConstrainedProperty[] constraints
protected java.lang.Object controllerName
protected java.lang.Object actionName
protected java.lang.Object pluginName
protected java.lang.Object viewName
protected java.lang.Object forwardURI
protected javax.servlet.ServletContext servletContext
protected java.util.Map parameterValues
protected boolean parseRequest
protected java.lang.String mappingName
protected boolean restful
public AbstractUrlMapping(java.lang.Object controllerName,
java.lang.Object actionName,
java.lang.Object pluginName,
java.lang.Object viewName,
org.codehaus.groovy.grails.validation.ConstrainedProperty[] constraints,
javax.servlet.ServletContext servletContext)
controllerName - The name of the controlleractionName - The name of the actionconstraints - Any constraints that apply to the mappingservletContext - protected AbstractUrlMapping(java.lang.Object viewName,
org.codehaus.groovy.grails.validation.ConstrainedProperty[] constraints,
javax.servlet.ServletContext servletContext)
protected AbstractUrlMapping(java.net.URI uri,
org.codehaus.groovy.grails.validation.ConstrainedProperty[] constraints,
javax.servlet.ServletContext servletContext)
public org.codehaus.groovy.grails.validation.ConstrainedProperty[] getConstraints()
UrlMappingThe constraints the apply to this UrlMapping. Each constraint maps to a GString token in a URL mapping in order. For example consider the URL:
/blog/$author/$title/$year?/$month?/$day?
This results in 5 ConstrainedProperty instances called author, title, year, month and day
getConstraints in interface UrlMappingUrlMapping.getConstraints()public java.lang.Object getControllerName()
UrlMappinggetControllerName in interface UrlMappingClosure or StringUrlMapping.getControllerName()public java.lang.Object getActionName()
UrlMappinggetActionName in interface UrlMappingClosure or StringUrlMapping.getActionName()public java.lang.Object getPluginName()
getPluginName in interface UrlMappingpublic java.lang.Object getViewName()
UrlMappinggetViewName in interface UrlMappingUrlMapping.getViewName()public void setParameterValues(java.util.Map parameterValues)
UrlMappingsetParameterValues in interface UrlMappingparameterValues - The parameter values to setpublic void setParseRequest(boolean shouldParse)
UrlMappingsetParseRequest in interface UrlMappingshouldParse - True if it shouldpublic java.lang.String getMappingName()
getMappingName in interface UrlMappingpublic void setMappingName(java.lang.String name)
setMappingName in interface UrlMappingpublic void setRestfulMapping(boolean isREST)
setRestfulMapping in interface UrlMappingisREST - Set whether this is a RESTful mappingpublic boolean isRestfulMapping()
isRestfulMapping in interface UrlMappingpublic boolean hasRuntimeVariable(java.lang.String name)
UrlMappinghasRuntimeVariable in interface UrlMappingname - The name of the variable