public class ForwardToView extends RuntimeException implements HttpResponse
HttpResponse
that forwards to a RequestDispatcher
, such as a view.
Extends from RuntimeException
so that you can throw it.Constructor and Description |
---|
ForwardToView(Class c,
String view) |
ForwardToView(Object it,
String view) |
ForwardToView(javax.servlet.RequestDispatcher dispatcher) |
Modifier and Type | Method and Description |
---|---|
void |
generateResponse(StaplerRequest req,
StaplerResponse rsp,
Object node) |
ForwardToView |
optional()
Make this forwarding optional.
|
ForwardToView |
with(Map<String,?> attributes) |
ForwardToView |
with(String varName,
Object value)
Forwards to the view with specified attributes exposed as a variable binding.
|
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
public ForwardToView with(String varName, Object value)
public ForwardToView with(Map<String,?> attributes)
public ForwardToView optional()
public void generateResponse(StaplerRequest req, StaplerResponse rsp, Object node) throws IOException, javax.servlet.ServletException
generateResponse
in interface HttpResponse
node
- The object whose "doXyz" method created this object.IOException
javax.servlet.ServletException
Copyright © 2015. All rights reserved.