|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.loom.resolution.DefaultResolutionFactory
@Singleton public class DefaultResolutionFactory
Default ResolutionFactory implementation
Constructor Summary | |
---|---|
DefaultResolutionFactory()
|
Method Summary | |
---|---|
ForwardResolution |
forward(java.lang.String pageName)
Create a ForwardResolution |
ForwardResolution |
forwardWithLocale(java.lang.String pageName)
Forward to a page, with preference for a localized page if possible. |
java.lang.String |
getForwardResourcesRoot()
|
org.codehaus.jackson.map.ObjectMapper |
getMapper()
|
JacksonResolution |
json(java.lang.Object contents)
Sends a JSON serialization of the contents object. |
RedirectResolution |
redirect(java.lang.Class<? extends Action> actionClass,
java.lang.String event)
Redirects the browser to a different Action and Event |
RedirectResolution |
redirect(java.lang.String url)
Redirects the browser to a different URL |
RedirectResolution |
redirect(java.lang.String action,
java.lang.String event)
Redirects the browser to a different Action and Event |
PersistentFileResolution |
send(PersistentFile file)
Sends a persistent file to the browser. |
void |
setForwardResourcesRoot(java.lang.String forwardResourcesRoot)
|
void |
setMapper(org.codehaus.jackson.map.ObjectMapper mapper)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DefaultResolutionFactory()
Method Detail |
---|
public ForwardResolution forward(java.lang.String pageName)
ResolutionFactory
forward
in interface ResolutionFactory
pageName
- the name of the forward destination
public ForwardResolution forwardWithLocale(java.lang.String pageName)
ResolutionFactory
forwardWithLocale
in interface ResolutionFactory
pageName
- the name of the resource to forward to
LocaleForwardResolution
public PersistentFileResolution send(PersistentFile file)
ResolutionFactory
send
in interface ResolutionFactory
public RedirectResolution redirect(java.lang.String url)
ResolutionFactory
redirect
in interface ResolutionFactory
url
- the url for the browser redirection
RedirectResolution
pointing to the provided URLpublic RedirectResolution redirect(java.lang.String action, java.lang.String event)
ResolutionFactory
redirect
in interface ResolutionFactory
action
- the action short or long nameevent
- the event to be invoked, null for default event
RedirectResolution
pointing to the provided URLpublic RedirectResolution redirect(java.lang.Class<? extends Action> actionClass, java.lang.String event)
ResolutionFactory
redirect
in interface ResolutionFactory
actionClass
- the action classevent
- the event to be called, null for default event
RedirectResolution
pointing to the provided URLpublic java.lang.String getForwardResourcesRoot()
public void setForwardResourcesRoot(java.lang.String forwardResourcesRoot)
public JacksonResolution json(java.lang.Object contents)
ResolutionFactory
json
in interface ResolutionFactory
contents
- the contents object to serialize as a JSON object
public org.codehaus.jackson.map.ObjectMapper getMapper()
public void setMapper(org.codehaus.jackson.map.ObjectMapper mapper)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |