Package com.googlecode.sardine.model

Examples of com.googlecode.sardine.model.Acl


    {
      return null;
    }
    for (Propstat propstat : list)
    {
      Acl a = propstat.getProp().getAcl();
      if (a != null && a.getAce() != null)
      {
        for (Ace ace : a.getAce())
        {
          result.add(new DavAce(ace));
        }
      }
    }
View Full Code Here


  @Override
  public void setAcl(String url, List<DavAce> aces) throws IOException
  {
    HttpAcl entity = new HttpAcl(url);
    // Build WebDAV <code>ACL</code> entity.
    Acl body = new Acl();
    body.setAce(new ArrayList<Ace>());
    for (DavAce davAce : aces)
    {
      // protected and inherited acl must not be part of ACL http request
      if (davAce.getInherited() != null || davAce.isProtected())
      {
        continue;
      }
      Ace ace = davAce.toModel();
      body.getAce().add(ace);
    }
    entity.setEntity(new StringEntity(SardineUtil.toXml(body), UTF_8));
    this.execute(entity, new VoidResponseHandler());
  }
View Full Code Here

    entity.setDepth("0");
    Propfind body = new Propfind();
    Prop prop = new Prop();
    prop.setOwner(new Owner());
    prop.setGroup(new Group());
    prop.setAcl(new Acl());
    body.setProp(prop);
    entity.setEntity(new StringEntity(SardineUtil.toXml(body), UTF_8));
    Multistatus multistatus = this.execute(entity, new MultiStatusResponseHandler());
    List<Response> responses = multistatus.getResponse();
    if (responses.isEmpty())
View Full Code Here

TOP

Related Classes of com.googlecode.sardine.model.Acl

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.