org.ofbiz.webapp.view
Class WfsViewHandler

java.lang.Object
  extended by org.ofbiz.webapp.view.AbstractViewHandler
      extended by org.ofbiz.webapp.view.WfsViewHandler
All Implemented Interfaces:
ViewHandler

public class WfsViewHandler
extends AbstractViewHandler

WfsViewHandler - View Handler


Field Summary
protected  ServletContext context
           
static java.lang.String FormatTemplateUrl
           
static java.lang.String module
           
 
Fields inherited from class org.ofbiz.webapp.view.AbstractViewHandler
name
 
Constructor Summary
WfsViewHandler()
           
 
Method Summary
static Template getDocTemplate(java.lang.String fileUrl)
           
 void init(ServletContext context)
          Initializes the handler.
static Configuration makeDefaultOfbizConfig()
           
 void render(java.lang.String name, java.lang.String page, java.lang.String info, java.lang.String contentType, java.lang.String encoding, HttpServletRequest request, HttpServletResponse response)
          Render the page.
 
Methods inherited from class org.ofbiz.webapp.view.AbstractViewHandler
getName, setName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

module

public static final java.lang.String module

FormatTemplateUrl

public static final java.lang.String FormatTemplateUrl
See Also:
Constant Field Values

context

protected ServletContext context
Constructor Detail

WfsViewHandler

public WfsViewHandler()
Method Detail

init

public void init(ServletContext context)
          throws ViewHandlerException
Description copied from interface: ViewHandler
Initializes the handler. Since handlers use the singleton pattern this method should only be called the first time the handler is used.

Parameters:
context - ServletContext This may be needed by the handler in order to lookup properties or XML definition files for rendering pages or handler options.
Throws:
ViewHandlerException

render

public void render(java.lang.String name,
                   java.lang.String page,
                   java.lang.String info,
                   java.lang.String contentType,
                   java.lang.String encoding,
                   HttpServletRequest request,
                   HttpServletResponse response)
            throws ViewHandlerException
Description copied from interface: ViewHandler
Render the page.

Parameters:
name - The name of the view.
page - The source of the view; could be a page, url, etc depending on the type of handler.
info - An info string attached to this view
request - The HttpServletRequest object used when requesting this page.
response - The HttpServletResponse object to be used to present the page.
Throws:
ViewHandlerException

getDocTemplate

public static Template getDocTemplate(java.lang.String fileUrl)
                               throws java.io.FileNotFoundException,
                                      java.io.IOException,
                                      TemplateException,
                                      java.net.URISyntaxException
Throws:
java.io.FileNotFoundException
java.io.IOException
TemplateException
java.net.URISyntaxException

makeDefaultOfbizConfig

public static Configuration makeDefaultOfbizConfig()
                                            throws TemplateException,
                                                   java.io.IOException
Throws:
TemplateException
java.io.IOException