Package org.apache.abdera.util

Examples of org.apache.abdera.util.EntityTag


    }
  }
 
  public ResponseContext setEntityTag(String etag) {
    return etag != null ?
      setEntityTag(new EntityTag(etag)) :
      removeHeader("ETag");
  }
View Full Code Here


        this.etag = tag;
        return this;
    }

    public Document<T> setEntityTag(String tag) {
        this.etag = new EntityTag(tag);
        return this;
    }
View Full Code Here

    String uri,
    EntityProvider provider,
    RequestOptions options) {
      if (options == null) options = getDefaultRequestOptions();
      if (options.isConditionalPut()) {
        EntityTag etag = provider.getEntityTag();
        if (etag != null) options.setIfMatch(etag);
        else {
          Date lm = provider.getLastModified();
          if (lm != null) options.setIfUnmodifiedSince(lm);
        }
View Full Code Here

    this.etag = tag;
    return this;
  }

  public Document<T> setEntityTag(String tag) {
    this.etag = new EntityTag(tag);
    return this;
  }
View Full Code Here

    }
  }
 
  public ResponseContext setEntityTag(String etag) {
    return etag != null ?
      setEntityTag(new EntityTag(etag)) :
      removeHeader("ETag");
  }
View Full Code Here

 
  /**
   * Sets the value of the HTTP If-Match header
   */
  public RequestOptions setIfMatch(String entity_tag) {
    return setIfMatch(new EntityTag(entity_tag));
  }
View Full Code Here

 
  /**
   * Sets the value of the HTTP If-None-Match header
   */
  public RequestOptions setIfNoneMatch(String entity_tag) {
    return setIfNoneMatch(new EntityTag(entity_tag));
  }
View Full Code Here

    String uri,
    EntityProvider provider,
    RequestOptions options) {
      if (options == null) options = getDefaultRequestOptions();
      if (options.isConditionalPut()) {
        EntityTag etag = provider.getEntityTag();
        if (etag != null) options.setIfMatch(etag);
        else {
          Date lm = provider.getLastModified();
          if (lm != null) options.setIfUnmodifiedSince(lm);
        }
View Full Code Here

        IRI r = new IRI(getUri());
        cl = r.resolve(cl);
      }
      String base = (cl != null) ? cl.toASCIIString() : getUri();
      Document<T> doc = parser.parse(getReader(), base, options);
      EntityTag etag = getEntityTag();
      if (etag != null) doc.setEntityTag(etag);
      Date lm = getLastModified();
      if (lm != null) doc.setLastModified(lm);
      MimeType mt = getContentType();
      if (mt != null) doc.setContentType(mt.toString());
View Full Code Here

            throw new RuntimeException(e);
        }
    }

    public ResponseContext setEntityTag(String etag) {
        return etag != null ? setEntityTag(new EntityTag(etag)) : removeHeader("ETag");
    }
View Full Code Here

TOP

Related Classes of org.apache.abdera.util.EntityTag

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.