extensions.gem
Class ForwardCommand

java.lang.Object
  |
  +--extensions.gem.ForwardCommand

public class ForwardCommand
extends java.lang.Object
implements Command

Program: ForwardCommand.java This simple command just forwards the browser to the next JSP page specified in the constructor.


Constructor Summary
ForwardCommand(java.lang.String nextPage)
           
 
Method Summary
 extensions.gem.HttpServletResponse execute(extensions.gem.HttpServletRequest req, extensions.gem.HttpServletResponse res)
          Don't really need to do anything here, just return the name of the next page to display.
 java.lang.String getNextPage()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ForwardCommand

public ForwardCommand(java.lang.String nextPage)
Method Detail

execute

public extensions.gem.HttpServletResponse execute(extensions.gem.HttpServletRequest req,
                                                  extensions.gem.HttpServletResponse res)
Don't really need to do anything here, just return the name of the next page to display. However, we have the entire request object, so other command classes may do all kinds of things like call setPropBean and so on.
Specified by:
execute in interface Command

getNextPage

public java.lang.String getNextPage()
Specified by:
getNextPage in interface Command