Package org.apache.abdera.protocol.server.provider

Examples of org.apache.abdera.protocol.server.provider.AbstractResponseContext


            if (type == TargetType.TYPE_MEDIA) {
              return provider.deleteMedia(request);
            }
          }
          else if (method == "OPTIONS") {
            AbstractResponseContext rc = new EmptyResponseContext(200);
            rc.addHeader("Allow", combine(getAllowedMethods(type)));
            return rc;
          }
        } else {
          return handler.process(provider, request);
        }
View Full Code Here


  public ResponseContext getService(
    RequestContext request,
    boolean full) {
      Abdera abdera = request.getServiceContext().getAbdera();
      Document<Service> service = get_service_doc(abdera);
      AbstractResponseContext rc;
      rc = (full) ?
        new BaseResponseContext<Document<Service>>(service) :
        new EmptyResponseContext(200);
      rc.setEntityTag(service_etag);
      return rc;
  }
View Full Code Here

  public ResponseContext getFeed(
    RequestContext request,
    boolean full) {
      Abdera abdera = request.getServiceContext().getAbdera();
      Document<Feed> feed = get_feed_doc(abdera);
      AbstractResponseContext rc;
      rc = (full) ?
        new BaseResponseContext<Document<Feed>>(feed) :
        new EmptyResponseContext(200);
      rc.setEntityTag(calculateEntityTag(feed.getRoot()));
      return rc;
  }
View Full Code Here

      if (entry != null) {
        Feed feed = entry.getParentElement();
        entry = (Entry) entry.clone();
        entry.setSource(feed.getAsSource());
        Document<Entry> entry_doc = entry.getDocument();
        AbstractResponseContext rc = (full) ?
          new BaseResponseContext<Document<Entry>>(entry_doc) :
          new EmptyResponseContext(200);
        rc.setEntityTag(calculateEntityTag(entry));
        return rc;
      } else {
        return new EmptyResponseContext(404);
      }
  }
View Full Code Here

TOP

Related Classes of org.apache.abdera.protocol.server.provider.AbstractResponseContext

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.