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.mortbay.servlet
Class PutFilter

    java.lang.Object
      org.mortbay.servlet.PutFilter

All Implemented Interfaces:
  javax.servlet.Filter

    public class PutFilter

extends java.lang.Object
implements javax.servlet.Filter

PutFilter A Filter that handles PUT, DELETE and MOVE methods. Files are hidden during PUT operations, so that 404's result. The following init paramters pay be used:

- baseURI - The file URI of the document root for put content.
- delAllowed - boolean, if true DELETE and MOVE methods are supported.

Field Summary
`static java.lang.String` | `__DELETE`
`static java.lang.String` | `__MOVE`
`static java.lang.String` | `__OPTIONS`
`static java.lang.String` | `__PUT`
`protected java.lang.String` | `_baseURI`
`protected javax.servlet.ServletContext` | `_context`
`protected boolean` | `_delAllowed`
`protected java.util.concurrent.ConcurrentMap` | `_hidden`

Constructor Summary
`PutFilter()`

Method Summary
`void` | `destroy()`
`void` | `doFilter(javax.servlet.ServletRequest req, javax.servlet.ServletResponse res, javax.servlet.FilterChain chain)`
`void` | `handleDelete(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, java.lang.String pathInContext, java.io.File file)`
`void` | `handleMove(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, java.lang.String pathInContext, java.io.File file)`
`void` | `handleOptions(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)`
`void` | `handlePut(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, java.lang.String pathInContext, java.io.File file)`
`void` | `init(javax.servlet.FilterConfig config)`
`protected boolean` | `passConditionalHeaders(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, java.io.File file)`

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

Field Detail

### __PUT

    public static final java.lang.String __PUT

See Also:
  Constant Field Values

### __DELETE

    public static final java.lang.String __DELETE

See Also:
  Constant Field Values

### __MOVE

    public static final java.lang.String __MOVE

See Also:
  Constant Field Values

### __OPTIONS

    public static final java.lang.String __OPTIONS

See Also:
  Constant Field Values

### _hidden

    protected java.util.concurrent.ConcurrentMap _hidden

### _context

    protected javax.servlet.ServletContext _context

### _baseURI

    protected java.lang.String _baseURI

### _delAllowed

    protected boolean _delAllowed

Constructor Detail

### PutFilter

    public PutFilter()

Method Detail

### init

    public void init(javax.servlet.FilterConfig config)
              throws javax.servlet.ServletException

  Specified by:
    `init` in interface `javax.servlet.Filter`
  Throws:
    `javax.servlet.ServletException`

### doFilter

    public void doFilter(javax.servlet.ServletRequest req,
                         javax.servlet.ServletResponse res,
                         javax.servlet.FilterChain chain)
                  throws java.io.IOException,
                         javax.servlet.ServletException

  Specified by:
    `doFilter` in interface `javax.servlet.Filter`
  Throws:
    `java.io.IOException`
    `javax.servlet.ServletException`

### destroy

    public void destroy()

  Specified by:
    `destroy` in interface `javax.servlet.Filter`

### handlePut

    public void handlePut(javax.servlet.http.HttpServletRequest request,
                          javax.servlet.http.HttpServletResponse response,
                          java.lang.String pathInContext,
                          java.io.File file)
                   throws javax.servlet.ServletException,
                          java.io.IOException

  Throws:
    `javax.servlet.ServletException`
    `java.io.IOException`

### handleDelete

    public void handleDelete(javax.servlet.http.HttpServletRequest request,
                             javax.servlet.http.HttpServletResponse response,
                             java.lang.String pathInContext,
                             java.io.File file)
                      throws javax.servlet.ServletException,
                             java.io.IOException

  Throws:
    `javax.servlet.ServletException`
    `java.io.IOException`

### handleMove

    public void handleMove(javax.servlet.http.HttpServletRequest request,
                           javax.servlet.http.HttpServletResponse response,
                           java.lang.String pathInContext,
                           java.io.File file)
                    throws javax.servlet.ServletException,
                           java.io.IOException,
                           java.net.URISyntaxException

  Throws:
    `javax.servlet.ServletException`
    `java.io.IOException`
    `java.net.URISyntaxException`

### handleOptions

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

  Throws:
    `java.io.IOException`

### passConditionalHeaders

    protected boolean passConditionalHeaders(javax.servlet.http.HttpServletRequest request,
                                             javax.servlet.http.HttpServletResponse response,
                                             java.io.File file)
                                      throws java.io.IOException

  Throws:
    `java.io.IOException`

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

Copyright © 1995-2010 Mort Bay Consulting. All Rights Reserved.