|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.codehaus.groovy.grails.web.mapping.DefaultUrlMappingEvaluator
public class DefaultUrlMappingEvaluator
A UrlMapping evaluator that evaluates Groovy scripts that are in the form:
mappings {
/$post/$year?/$month?/$day?" {
controller = "blog"
action = "show"
constraints {
year(matches:/\d{4}/)
month(matches:/\d{2}/)
}
}
}
Nested Class Summary | |
---|---|
(package private) class |
DefaultUrlMappingEvaluator.MappingCapturingClosure
A Closure that captures a call to a method that accepts a single closure |
(package private) class |
DefaultUrlMappingEvaluator.UrlMappingBuilder
A modal builder that constructs a UrlMapping instances by executing a closure. |
Field Summary |
---|
Fields inherited from interface org.codehaus.groovy.grails.web.mapping.UrlMappingEvaluator |
---|
DEFAULT_REST_MAPPING |
Constructor Summary | |
---|---|
DefaultUrlMappingEvaluator(ServletContext servletContext)
|
Method Summary | |
---|---|
List |
evaluateMappings(Class theClass)
Evaluates mapping from the given class if possible |
List |
evaluateMappings(groovy.lang.Closure closure)
Evaluates mapping from the given closure if possible |
List |
evaluateMappings(Resource resource)
Evaluates URL mapping from the give Spring Resource |
void |
setClassLoader(ClassLoader classLoader)
This method is called by the ApplicationContext that
loads the Grails application. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DefaultUrlMappingEvaluator(ServletContext servletContext)
Method Detail |
---|
public List evaluateMappings(Resource resource)
UrlMappingEvaluator
evaluateMappings
in interface UrlMappingEvaluator
resource
- The Spring Resource to evaluate mapping from
public List evaluateMappings(Class theClass)
UrlMappingEvaluator
evaluateMappings
in interface UrlMappingEvaluator
theClass
- The class to evaluate mapping from
public List evaluateMappings(groovy.lang.Closure closure)
UrlMappingEvaluator
evaluateMappings
in interface UrlMappingEvaluator
closure
- The closure to evaluate mapping from
public void setClassLoader(ClassLoader classLoader)
ClassLoaderAware
This method is called by the ApplicationContext
that
loads the Grails application. The ClassLoader
that loads the Grails application code
is injected.
setClassLoader
in interface ClassLoaderAware
classLoader
- the ClassLoader
that loads the Grails application code
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |