|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.groovy.grails.web.mapping.DefaultUrlMappingsHolder
public class DefaultUrlMappingsHolder
The default implementation of the UrlMappingsHolder interface that takes a list of mappings and then sorts them according to their precdence rules as defined in the implementation of Comparable
UrlMapping
,
Comparable
Nested Class Summary | |
---|---|
(package private) class |
DefaultUrlMappingsHolder.UrlMappingKey
A class used as a key to lookup a UrlMapping based on controller, action and parameter names |
Field Summary |
---|
Fields inherited from interface org.codehaus.groovy.grails.web.mapping.UrlMappingsHolder |
---|
BEAN_ID |
Constructor Summary | |
---|---|
DefaultUrlMappingsHolder(java.util.List mappings)
|
Method Summary | |
---|---|
UrlCreator |
getReverseMapping(java.lang.String controller,
java.lang.String action,
java.util.Map params)
Retrieves the best guess of a URI for the given controller, action and parameters |
UrlMapping[] |
getUrlMappings()
Retrieves the held UrlMapping instances as an array |
UrlMappingInfo |
match(java.lang.String uri)
Match and return the first UrlMappingInfo instance possible |
UrlMappingInfo[] |
matchAll(java.lang.String uri)
Matches all possible UrlMappingInfo instances to the given URI and returns them all |
UrlMappingInfo[] |
matchAll(java.lang.String uri,
java.lang.String httpMethod)
Match all possible UrlMappingInfo instances to the given URI and HTTP method |
UrlMappingInfo |
matchStatusCode(int responseCode)
Match and return the first UrlMappingInfo instance possible |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public DefaultUrlMappingsHolder(java.util.List mappings)
Method Detail |
---|
public UrlMapping[] getUrlMappings()
UrlMappingsHolder
getUrlMappings
in interface UrlMappingsHolder
public UrlCreator getReverseMapping(java.lang.String controller, java.lang.String action, java.util.Map params)
UrlMappingsHolder
getReverseMapping
in interface UrlMappingsHolder
controller
- The name of the controlleraction
- The name of the action or nullparams
- The parameters or null
UrlMappingsHolder.getReverseMapping(String, String, java.util.Map)
public UrlMappingInfo match(java.lang.String uri)
UrlMappingsHolder
match
in interface UrlMappingsHolder
uri
- The URI to match
UrlMappingsHolder.match(String)
public UrlMappingInfo[] matchAll(java.lang.String uri)
UrlMappingsHolder
matchAll
in interface UrlMappingsHolder
uri
- The URI to match
public UrlMappingInfo[] matchAll(java.lang.String uri, java.lang.String httpMethod)
UrlMappingsHolder
matchAll
in interface UrlMappingsHolder
uri
- The URI to matchhttpMethod
- The HTTP method (GET,POST,PUT,DELETE etc.)
public UrlMappingInfo matchStatusCode(int responseCode)
UrlMappingsHolder
matchStatusCode
in interface UrlMappingsHolder
responseCode
- The responseCode to match
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |