Examples of ResourceException


Examples of org.restlet.client.resource.ResourceException

    public Status getStatus(Throwable throwable, Request request,
            Response response) {
        Status result = null;

        if (throwable instanceof ResourceException) {
            ResourceException re = (ResourceException) throwable;

            if (re.getCause() != null) {
                // What is most interesting is the embedded cause
                result = new Status(re.getStatus(), re.getCause());
            } else {
                result = re.getStatus();
            }
        } else {
            result = new Status(Status.SERVER_ERROR_INTERNAL, throwable);
        }
View Full Code Here

Examples of org.restlet.resource.ResourceException

    MediaType mediaType = variant.getMediaType();

    FF format = registry.getFileFormatForMIMEType(mediaType.getName());

    if (format == null) {
      throw new ResourceException(CLIENT_ERROR_NOT_ACCEPTABLE, "No acceptable file format found.");
    }

    S service = registry.get(format);

    Representation representation = getRepresentation(service, mediaType);
View Full Code Here

Examples of org.w3c.tools.resources.ResourceException

     */
    protected Reply headFileResource(Request request)
  throws ProtocolException, ResourceException
    {
  if (fresource == null)
      throw new ResourceException("this frame is not attached to a "+
              "FileResource. ("+
              resource.getIdentifier()+")");
  Reply reply = null;
  fresource.checkContent();
  updateCachedHeaders();
View Full Code Here

Examples of pt.opensoft.resource.ResourceException

    }

    ResourceDispenser rd = (ResourceDispenser) resourceDispensers.get(resourceDispenser);

    if (rd == null) {
      throw new ResourceException("resourceDispenser " + resourceDispenser + " not found");
    }
    return rd;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.