Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.directwebremoting.dwrp
Class BaseCallMarshaller

    java.lang.Object
      org.directwebremoting.dwrp.BaseCallMarshaller

All Implemented Interfaces:
  Marshaller

Direct Known Subclasses:
  HtmlCallMarshaller, PlainCallMarshaller

    public abstract class BaseCallMarshaller

extends java.lang.Object
implements Marshaller

A Marshaller that output plain Javascript. This marshaller can be tweaked to output Javascript in an HTML context. This class works in concert with CallScriptConduit, they should be considered closely related and it is important to understand what one does while editing the other.

Author:
  Joe Walker [joe at getahead dot ltd dot uk]

Constructor Summary
`BaseCallMarshaller()`

Method Summary
`boolean` | `isConvertable(java.lang.Class paramType)` Check if we can coerce the given type
`void` | `marshallException(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, java.lang.Exception ex)` Try to find a batchId to send to the client so it knows what broke
`Calls` | `marshallInbound(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)` Marshall an incomming HttpRequest into an abstract Calls POJO that defines the functions that we need to call.
`void` | `marshallOutbound(Replies replies, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)` Marshall the return values from executing this batch of requests.
`void` | `setAccessControl(AccessControl accessControl)` Accessor for the security manager
`void` | `setAllowGetForSafariButMakeForgeryEasier(boolean allowGetForSafariButMakeForgeryEasier)`
`void` | `setConverterManager(ConverterManager converterManager)` Accessor for the DefaultCreatorManager that we configure
`void` | `setCreatorManager(CreatorManager creatorManager)` Accessor for the DefaultCreatorManager that we configure
`void` | `setCrossDomainSessionSecurity(boolean crossDomainSessionSecurity)` To we perform cross-domain session security checks?
`void` | `setPageNormalizer(PageNormalizer pageNormalizer)` Accessor for the PageNormalizer.
`void` | `setSessionCookieName(java.lang.String sessionCookieName)` Alter the session cookie name from the default JSESSIONID.

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### BaseCallMarshaller

    public BaseCallMarshaller()

Method Detail

### marshallInbound

    public Calls marshallInbound(javax.servlet.http.HttpServletRequest request,
                                 javax.servlet.http.HttpServletResponse response)
                          throws java.io.IOException,
                                 ServerException

  Description copied from interface: `Marshaller`
  Marshall an incomming HttpRequest into an abstract Calls POJO that defines the functions that we need to call.

  Specified by:
    `marshallInbound` in interface `Marshaller`
  Parameters:
    `request` - The incoming Http request
    `response` - An Ajax response, XML, JSON, Javascript, etc.
  Returns:
    Data specifying the methods to call
  Throws:
    `java.io.IOException` - If the connection breaks
    `ServerException` - If an error occurs during parsing

### marshallOutbound

    public void marshallOutbound(Replies replies,
                                 javax.servlet.http.HttpServletRequest request,
                                 javax.servlet.http.HttpServletResponse response)
                          throws java.io.IOException

  Description copied from interface: `Marshaller`
  Marshall the return values from executing this batch of requests.

  Specified by:
    `marshallOutbound` in interface `Marshaller`
  Parameters:
    `replies` - The objects to convert into a reply
    `request` - The incoming Http request
    `response` - An Ajax response, XML, JSON, Javascript, etc.
  Throws:
    `java.io.IOException` - If the connection breaks

### marshallException

    public void marshallException(javax.servlet.http.HttpServletRequest request,
                                  javax.servlet.http.HttpServletResponse response,
                                  java.lang.Exception ex)
                           throws java.io.IOException

  Description copied from interface: `Marshaller`
  Try to find a batchId to send to the client so it knows what broke

  Specified by:
    `marshallException` in interface `Marshaller`
  Parameters:
    `request` - The incoming Http request
    `response` - An Ajax response, XML, JSON, Javascript, etc.
    `ex` - The exception that we wish to propogate to the client
  Throws:
    `java.io.IOException` - If writing to the output stream fails

### isConvertable

    public boolean isConvertable(java.lang.Class paramType)

  Description copied from interface: `Marshaller`
  Check if we can coerce the given type

  Specified by:
    `isConvertable` in interface `Marshaller`
  Parameters:
    `paramType` - The type to check
  Returns:
    true iff `paramType` is coercable

### setConverterManager

    public void setConverterManager(ConverterManager converterManager)

  Accessor for the DefaultCreatorManager that we configure

  Parameters:
    `converterManager` - The new DefaultConverterManager

### setCreatorManager

    public void setCreatorManager(CreatorManager creatorManager)

  Accessor for the DefaultCreatorManager that we configure

  Parameters:
    `creatorManager` - The new DefaultConverterManager

### setAccessControl

    public void setAccessControl(AccessControl accessControl)

  Accessor for the security manager

  Parameters:
    `accessControl` - The accessControl to set.

### setPageNormalizer

    public void setPageNormalizer(PageNormalizer pageNormalizer)

  Accessor for the PageNormalizer.

  Parameters:
    `pageNormalizer` - The new PageNormalizer

### setCrossDomainSessionSecurity

    public void setCrossDomainSessionSecurity(boolean crossDomainSessionSecurity)

  To we perform cross-domain session security checks?

  Parameters:
    `crossDomainSessionSecurity` - the cross domain session security setting

### setAllowGetForSafariButMakeForgeryEasier

    public void setAllowGetForSafariButMakeForgeryEasier(boolean allowGetForSafariButMakeForgeryEasier)

  Parameters:
    `allowGetForSafariButMakeForgeryEasier` - Do we reduce security to help Safari

### setSessionCookieName

    public void setSessionCookieName(java.lang.String sessionCookieName)

  Alter the session cookie name from the default JSESSIONID.

  Parameters:
    `sessionCookieName` - the sessionCookieName to set

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Copyright ¬ 2005
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD