code: protected int getDepth( final WebdavRequest req )
      {
          int depth = INFINITY;
          final String depthStr = req.getHeader( "Depth" );
          if ( depthStr != null )
          {
              if ( depthStr.equals( "0" ) )
              {
                  depth = 0;
              }
              else if ( depthStr.equals( "1" ) )
              {
                  depth = 1;
              }
          }
          return depth;
      }
docs: reads the depth header from the request and returns it as a int
  
  @param req
  @return the depth from the depth header