Package ca.uhn.fhir.rest.client.method
Class BaseMethodBinding<T>
java.lang.Object
ca.uhn.fhir.rest.client.method.BaseMethodBinding<T>
- All Implemented Interfaces:
IClientResponseHandler<T>
- Direct Known Subclasses:
BaseOutcomeReturningMethodBindingWithResourceIdButNoResourceBody
,BaseResourceReturningMethodBinding
,CreateMethodBinding
,UpdateMethodBinding
-
Constructor Summary
ConstructorDescriptionBaseMethodBinding
(Method theMethod, ca.uhn.fhir.context.FhirContext theContext, Object theProvider) -
Method Summary
Modifier and TypeMethodDescriptionstatic BaseMethodBinding
<?> bindMethod
(Method theMethod, ca.uhn.fhir.context.FhirContext theContext, Object theProvider) protected ca.uhn.fhir.parser.IParser
createAppropriateParserForParsingResponse
(String theResponseMimeType, InputStream theResponseInputStream, int theResponseStatusCode, List<Class<? extends org.hl7.fhir.instance.model.api.IBaseResource>> thePreferTypes) ca.uhn.fhir.context.FhirContext
abstract String
Returns the name of the resource this method handles, ornull
if this method is not resource specificabstract ca.uhn.fhir.rest.api.RestOperationTypeEnum
abstract BaseHttpClientInvocation
invokeClient
(Object[] theArgs) static boolean
isResourceInterface
(Class<?> theReturnTypeFromMethod) boolean
Does this method have a parameter annotated withConditionalParamBinder
.boolean
Does this method support conditional operations over multiple objects (basically for conditional delete)protected ca.uhn.fhir.rest.server.exceptions.BaseServerResponseException
processNon2xxResponseAndReturnExceptionToThrow
(int theStatusCode, String theResponseMimeType, InputStream theResponseInputStream) void
setParameters
(List<IParameter> theParameters) For unit tests onlystatic boolean
verifyMethodHasZeroOrOneOperationAnnotation
(Method theNextMethod, Object... theAnnotations) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface ca.uhn.fhir.rest.client.method.IClientResponseHandler
invokeClient
-
Constructor Details
-
BaseMethodBinding
public BaseMethodBinding(Method theMethod, ca.uhn.fhir.context.FhirContext theContext, Object theProvider)
-
-
Method Details
-
createAppropriateParserForParsingResponse
protected ca.uhn.fhir.parser.IParser createAppropriateParserForParsingResponse(String theResponseMimeType, InputStream theResponseInputStream, int theResponseStatusCode, List<Class<? extends org.hl7.fhir.instance.model.api.IBaseResource>> thePreferTypes) -
getAllowableParamAnnotations
-
getContext
-
getIncludes
-
getMethod
-
getParameters
-
getProvider
-
getResourceName
Returns the name of the resource this method handles, ornull
if this method is not resource specific -
getRestOperationType
-
invokeClient
public abstract BaseHttpClientInvocation invokeClient(Object[] theArgs) throws ca.uhn.fhir.rest.server.exceptions.InternalErrorException - Throws:
ca.uhn.fhir.rest.server.exceptions.InternalErrorException
-
isSupportsConditional
Does this method have a parameter annotated withConditionalParamBinder
. Note that many operations don't actually support this paramter, so this will only return true occasionally. -
isSupportsConditionalMultiple
Does this method support conditional operations over multiple objects (basically for conditional delete) -
processNon2xxResponseAndReturnExceptionToThrow
protected ca.uhn.fhir.rest.server.exceptions.BaseServerResponseException processNon2xxResponseAndReturnExceptionToThrow(int theStatusCode, String theResponseMimeType, InputStream theResponseInputStream) -
setParameters
For unit tests only -
bindMethod
public static BaseMethodBinding<?> bindMethod(Method theMethod, ca.uhn.fhir.context.FhirContext theContext, Object theProvider) -
isResourceInterface
-
verifyMethodHasZeroOrOneOperationAnnotation
public static boolean verifyMethodHasZeroOrOneOperationAnnotation(Method theNextMethod, Object... theAnnotations)
-