Class WebdavStatus


  • public final class WebdavStatus
    extends Object
    Wraps the HttpServletResponse class to abstract the specific protocol used. To support other protocols we would only need to modify this class and the WebDavRetCode classes.
    Version:
    1.0, 16 Nov 1997
    Author:
    Marc Eaddy
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int SC_INSUFFICIENT_SPACE_ON_RESOURCE
      Status code (419) indicating that the resource does not have sufficient space to record the state of the resource after the execution of this method.
      static int SC_LOCKED
      Status code (423) indicating the destination resource of a method is locked, and either the request did not contain a valid Lock-Info header, or the Lock-Info header identifies a lock held by another principal.
      static int SC_METHOD_FAILURE
      Status code (420) indicating the method was not executed on a particular resource within its scope because some part of the method's execution failed causing the entire method to be aborted.
      static int SC_MULTI_STATUS
      Status code (207) indicating that the response requires providing status for multiple independent operations.
      static int SC_UNPROCESSABLE_ENTITY
      Status code (418) indicating the entity body submitted with the PATCH method was not understood by the resource.
    • Field Detail

      • SC_MULTI_STATUS

        public static final int SC_MULTI_STATUS
        Status code (207) indicating that the response requires providing status for multiple independent operations.
        See Also:
        Constant Field Values
      • SC_UNPROCESSABLE_ENTITY

        public static final int SC_UNPROCESSABLE_ENTITY
        Status code (418) indicating the entity body submitted with the PATCH method was not understood by the resource.
        See Also:
        Constant Field Values
      • SC_INSUFFICIENT_SPACE_ON_RESOURCE

        public static final int SC_INSUFFICIENT_SPACE_ON_RESOURCE
        Status code (419) indicating that the resource does not have sufficient space to record the state of the resource after the execution of this method.
        See Also:
        Constant Field Values
      • SC_METHOD_FAILURE

        public static final int SC_METHOD_FAILURE
        Status code (420) indicating the method was not executed on a particular resource within its scope because some part of the method's execution failed causing the entire method to be aborted.
        See Also:
        Constant Field Values
      • SC_LOCKED

        public static final int SC_LOCKED
        Status code (423) indicating the destination resource of a method is locked, and either the request did not contain a valid Lock-Info header, or the Lock-Info header identifies a lock held by another principal.
        See Also:
        Constant Field Values
    • Method Detail

      • getStatusText

        public static String getStatusText​(int nHttpStatusCode)
        Returns the HTTP status text for the HTTP or WebDav status code specified by looking it up in the static mapping. This is a static function.
        Parameters:
        nHttpStatusCode - [IN] HTTP or WebDAV status code
        Returns:
        A string with a short descriptive phrase for the HTTP status code (e.g., "OK").