|
||||||||||
| 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(List mappings)
|
|
| Method Summary | |
|---|---|
UrlCreator |
getReverseMapping(String controller,
String action,
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(String uri)
Match and return the first UrlMappingInfo instance possible |
UrlMappingInfo[] |
matchAll(String uri)
Matches all possible UrlMappingInfo instances to the given URI and returns them all |
UrlMappingInfo[] |
matchAll(String uri,
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 |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultUrlMappingsHolder(List mappings)
| Method Detail |
|---|
public UrlMapping[] getUrlMappings()
UrlMappingsHolder
getUrlMappings in interface UrlMappingsHolder
public UrlCreator getReverseMapping(String controller,
String action,
Map params)
UrlMappingsHolder
getReverseMapping in interface UrlMappingsHoldercontroller - 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(String uri)
UrlMappingsHolder
match in interface UrlMappingsHolderuri - The URI to match
UrlMappingsHolder.match(String)public UrlMappingInfo[] matchAll(String uri)
UrlMappingsHolder
matchAll in interface UrlMappingsHolderuri - The URI to match
public UrlMappingInfo[] matchAll(String uri,
String httpMethod)
UrlMappingsHolder
matchAll in interface UrlMappingsHolderuri - The URI to matchhttpMethod - The HTTP method (GET,POST,PUT,DELETE etc.)
public UrlMappingInfo matchStatusCode(int responseCode)
UrlMappingsHolder
matchStatusCode in interface UrlMappingsHolderresponseCode - The responseCode to match
public String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||