Package org.apache.webdav.lib

Examples of org.apache.webdav.lib.WebdavResources


      WebdavResource wdr = connect(directory);

      if(wdr == null)
        throw new Exception ("could not connect to WebDav Server");

      WebdavResources e = wdr.getChildResources();
      java.util.Enumeration en = e.getResources();
      while(en.hasMoreElements()) {
        WebdavResource cr = (WebdavResource)en.nextElement();               
        System.out.println(cr);
        if(cr.isCollection())
          listnames.put(cr, "dir");
        else
          listnames.put(cr, "file");
      }
      if(logtext != nulllogtext.append("..webdav server reply [changeDirectory] [status= "  + wdr.getStatusMessage() );
    } catch (Exception e) {

      MainWindow.message("could not change Directory [" + directory + "] cause:" + e.getMessage(), SWT.ICON_WARNING);

      try {
        new ErrorLog("error in " + sos.util.SOSClassUtil.getMethodName() + " ; could not change Directory [" + directory + "]", e);
      } catch(Exception ee) {
        //tu nichts
      }
      hasError = true;
      if(logtext != nulllogtext.append("could not change Directory [" + directory + "] cause:" + e.getMessage() );
    }
    return listnames;

  }
View Full Code Here


        String oldPath = webdavResource.getPath();
        try
        {
            webdavResource.setPath( path );

            WebdavResources resources = webdavResource.getChildResources();

            WebdavResource testResource = resources.getResource( filename );

            if ( testResource == null )
            {
                fail( "The file/contents <" + path + "/" + filename + "> does not exist in <" + httpurl + ">" );
            }
View Full Code Here

        String oldPath = webdavResource.getPath();
        try
        {
            webdavResource.setPath( path );

            WebdavResources resources = webdavResource.getChildResources();

            WebdavResource testResource = resources.getResource( filename );

            if ( testResource == null )
            {
                // Nothing found. we're done.
                return;
View Full Code Here

    @Override
    public WebdavResources getChildResources()
            throws HttpException, IOException
    {
        WebdavResources resources = super.getChildResources();
        WebdavResources out = new WebdavResources();
        for (WebdavResource resource : resources.listResources()) {
            out.addResource(createResource(resource));
        }

        return out;
    }
View Full Code Here

TOP

Related Classes of org.apache.webdav.lib.WebdavResources

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.