Examples of NonFhirResponseException


Examples of ca.uhn.fhir.rest.client.exceptions.NonFhirResponseException

    if (Constants.CT_ATOM_XML.equals(theResponseMimeType)) {
      parser = getContext().newXmlParser();
    } else if (Constants.CT_FHIR_XML.equals(theResponseMimeType)) {
      parser = getContext().newXmlParser();
    } else {
      throw new NonFhirResponseException("Response contains non-FHIR content-type: " + theResponseMimeType, theResponseMimeType, theResponseStatusCode, IOUtils.toString(theResponseReader));
    }
    return parser;
  }
View Full Code Here

Examples of ca.uhn.fhir.rest.client.exceptions.NonFhirResponseException

  }

  protected IParser createAppropriateParserForParsingResponse(String theResponseMimeType, Reader theResponseReader, int theResponseStatusCode) {
    EncodingEnum encoding = EncodingEnum.forContentType(theResponseMimeType);
    if (encoding == null) {
      NonFhirResponseException ex = NonFhirResponseException.newInstance(theResponseStatusCode, theResponseMimeType, theResponseReader);
      populateException(ex, theResponseReader);
      throw ex;
    }

    IParser parser = encoding.newParser(getContext());
View Full Code Here

Examples of ca.uhn.fhir.rest.client.exceptions.NonFhirResponseException

  }

  protected IParser createAppropriateParserForParsingResponse(String theResponseMimeType, Reader theResponseReader, int theResponseStatusCode) {
    EncodingEnum encoding = EncodingEnum.forContentType(theResponseMimeType);
    if (encoding == null) {
      NonFhirResponseException ex = NonFhirResponseException.newInstance(theResponseStatusCode, theResponseMimeType, theResponseReader);
      populateException(ex, theResponseReader);
      throw ex;
    }

    IParser parser = encoding.newParser(getContext());
View Full Code Here

Examples of ca.uhn.fhir.rest.client.exceptions.NonFhirResponseException

  public abstract boolean incomingServerRequestMatchesMethod(Request theRequest);

  protected IParser createAppropriateParserForParsingResponse(String theResponseMimeType, Reader theResponseReader, int theResponseStatusCode) {
    EncodingEnum encoding = EncodingEnum.forContentType(theResponseMimeType);   
    if (encoding==null) {
      NonFhirResponseException ex = NonFhirResponseException.newInstance(theResponseStatusCode, theResponseMimeType, theResponseReader);
      populateException(ex, theResponseReader);
      throw ex;
    }
   
    IParser parser=encoding.newParser(getContext());
View Full Code Here

Examples of ca.uhn.fhir.rest.client.exceptions.NonFhirResponseException

    if (Constants.CT_ATOM_XML.equals(theResponseMimeType)) {
      parser = getContext().newXmlParser();
    } else if (Constants.CT_FHIR_XML.equals(theResponseMimeType)) {
      parser = getContext().newXmlParser();
    } else {
      throw new NonFhirResponseException("Response contains non-FHIR content-type: " + theResponseMimeType, theResponseMimeType, theResponseStatusCode, IOUtils.toString(theResponseReader));
    }
    return parser;
  }
View Full Code Here

Examples of ca.uhn.fhir.rest.client.exceptions.NonFhirResponseException

  }

  protected IParser createAppropriateParserForParsingResponse(String theResponseMimeType, Reader theResponseReader, int theResponseStatusCode) {
    EncodingEnum encoding = EncodingEnum.forContentType(theResponseMimeType);
    if (encoding == null) {
      NonFhirResponseException ex = NonFhirResponseException.newInstance(theResponseStatusCode, theResponseMimeType, theResponseReader);
      populateException(ex, theResponseReader);
      throw ex;
    }

    IParser parser = encoding.newParser(getContext());
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.