org.ztemplates.web.spring
Class ZServletServiceSpring

java.lang.Object
  extended by org.ztemplates.web.spring.ZServletServiceSpring
All Implemented Interfaces:
ZIService, ZIServletService

@Component(value="ZIServletService")
@Scope(value="request")
public class ZServletServiceSpring
extends Object
implements ZIServletService

Spring proxy for ZISecurityService

Author:
gerd

Field Summary
 
Fields inherited from interface org.ztemplates.web.ZIServletService
SPRING_NAME
 
Constructor Summary
ZServletServiceSpring()
           
 
Method Summary
 String createUrl(Object action)
          Deprecated. 
 String getEncoding()
          The encoding used for the response and for parsing request parameters, defaults to "UTF-8". * To change encoding to ISO-8859-1 add the following lines to your web.xml: encoding ISO-8859-1 Don't forget to adjust your IDE/compiler/editor settings to use the selected encoding.
 javax.servlet.http.HttpServletRequest getRequest()
           
 javax.servlet.http.HttpServletResponse getResponse()
           
 void render(org.json.JSONArray json)
          utility as this is often needed for ajax applications, renders as mime-type "application/json"
 void render(org.json.JSONObject json)
          utility as this is often needed for ajax applications, renders as mime-type "application/json"
 void render(Object obj)
          renders the object to the response, with default mime type "text/html"
 void render(Object obj, String mimeType)
          renders the object to the response, with specified mime type
 void render(Object obj, String mimeType, String encoding)
          renders the object to the response, with specified mime type and encoding
 void sendRedirect(Object action)
          sends a redirect to the action
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ZServletServiceSpring

public ZServletServiceSpring()
Method Detail

getRequest

public javax.servlet.http.HttpServletRequest getRequest()
Specified by:
getRequest in interface ZIServletService
Returns:
the HttpServletRequest object associated with this servlet request

getResponse

public javax.servlet.http.HttpServletResponse getResponse()
Specified by:
getResponse in interface ZIServletService
Returns:
the HttpServletResponse

render

public void render(Object obj)
Description copied from interface: ZIServletService
renders the object to the response, with default mime type "text/html"

Specified by:
render in interface ZIServletService

render

public void render(Object obj,
                   String mimeType)
Description copied from interface: ZIServletService
renders the object to the response, with specified mime type

Specified by:
render in interface ZIServletService
Parameters:
obj - object to render
mimeType - mime type to use

render

public void render(Object obj,
                   String mimeType,
                   String encoding)
Description copied from interface: ZIServletService
renders the object to the response, with specified mime type and encoding

Specified by:
render in interface ZIServletService
Parameters:
obj - object to render
mimeType - mime type to use

render

public void render(org.json.JSONObject json)
Description copied from interface: ZIServletService
utility as this is often needed for ajax applications, renders as mime-type "application/json"

Specified by:
render in interface ZIServletService

render

public void render(org.json.JSONArray json)
Description copied from interface: ZIServletService
utility as this is often needed for ajax applications, renders as mime-type "application/json"

Specified by:
render in interface ZIServletService

createUrl

@Deprecated
public String createUrl(Object action)
Deprecated. 

use actionService.createUrl instead

Specified by:
createUrl in interface ZIServletService
Returns:

sendRedirect

public void sendRedirect(Object action)
                  throws Exception
Description copied from interface: ZIServletService
sends a redirect to the action

Specified by:
sendRedirect in interface ZIServletService
Throws:
IOException
Exception

getEncoding

public String getEncoding()
Description copied from interface: ZIServletService
The encoding used for the response and for parsing request parameters, defaults to "UTF-8". *

To change encoding to ISO-8859-1 add the following lines to your web.xml:

  
    encoding
    ISO-8859-1 
 
 
Don't forget to adjust your IDE/compiler/editor settings to use the selected encoding.

Specified by:
getEncoding in interface ZIServletService
Returns:


Copyright © 2011. All Rights Reserved.