Package ca.uhn.fhir.rest.server.method
Class BaseOutcomeReturningMethodBindingWithResourceIdButNoResourceBody
- java.lang.Object
-
- ca.uhn.fhir.rest.server.method.BaseMethodBinding<ca.uhn.fhir.rest.api.MethodOutcome>
-
- ca.uhn.fhir.rest.server.method.BaseOutcomeReturningMethodBindingWithResourceIdButNoResourceBody
-
- Direct Known Subclasses:
DeleteMethodBinding,PatchMethodBinding
public abstract class BaseOutcomeReturningMethodBindingWithResourceIdButNoResourceBody extends BaseMethodBinding<ca.uhn.fhir.rest.api.MethodOutcome>
-
-
Constructor Summary
Constructors Constructor Description BaseOutcomeReturningMethodBindingWithResourceIdButNoResourceBody(Method theMethod, ca.uhn.fhir.context.FhirContext theContext, Object theProvider, Class<?> theMethodAnnotationType, Class<? extends org.hl7.fhir.instance.model.api.IBaseResource> theResourceTypeFromAnnotation)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract voidaddParametersForServerRequest(RequestDetails theRequest, Object[] theParams)protected booleanallowVoidReturnType()Subclasses may override to allow a void method return type, which is allowable for some methods (e.g.protected IntegergetIdParameterIndex()protected abstract StringgetMatchingOperation()For servers, this method will match only incoming requests that match the given operation, or which have no operation in the URL if this method returns null.StringgetResourceName()Returns the name of the resource this method handles, ornullif this method is not resource specificbooleanincomingServerRequestMatchesMethod(RequestDetails theRequest)ObjectinvokeServer(IRestfulServer<?> theServer, RequestDetails theRequest)booleanisReturnVoid()protected abstract Set<ca.uhn.fhir.rest.api.RequestTypeEnum>provideAllowableRequestTypes()-
Methods inherited from class ca.uhn.fhir.rest.server.method.BaseMethodBinding
bindMethod, createMethodParams, createParametersForServerRequest, getAllowableParamAnnotations, getContext, getIncludes, getMethod, getParameters, getProvider, getRequestIncludesFromParams, getRestOperationType, getRestOperationType, invokeServerMethod, isGlobalMethod, isSupportsConditional, isSupportsConditionalMultiple, populateActionRequestDetailsForInterceptor, setParameters, toResourceList, verifyMethodHasZeroOrOneOperationAnnotation
-
-
-
-
Constructor Detail
-
BaseOutcomeReturningMethodBindingWithResourceIdButNoResourceBody
public BaseOutcomeReturningMethodBindingWithResourceIdButNoResourceBody(Method theMethod, ca.uhn.fhir.context.FhirContext theContext, Object theProvider, Class<?> theMethodAnnotationType, Class<? extends org.hl7.fhir.instance.model.api.IBaseResource> theResourceTypeFromAnnotation)
-
-
Method Detail
-
getResourceName
public String getResourceName()
Description copied from class:BaseMethodBindingReturns the name of the resource this method handles, ornullif this method is not resource specific- Specified by:
getResourceNamein classBaseMethodBinding<ca.uhn.fhir.rest.api.MethodOutcome>
-
getIdParameterIndex
protected Integer getIdParameterIndex()
-
addParametersForServerRequest
protected abstract void addParametersForServerRequest(RequestDetails theRequest, Object[] theParams)
-
allowVoidReturnType
protected boolean allowVoidReturnType()
Subclasses may override to allow a void method return type, which is allowable for some methods (e.g. delete)
-
getMatchingOperation
protected abstract String getMatchingOperation()
For servers, this method will match only incoming requests that match the given operation, or which have no operation in the URL if this method returns null.
-
incomingServerRequestMatchesMethod
public boolean incomingServerRequestMatchesMethod(RequestDetails theRequest)
- Specified by:
incomingServerRequestMatchesMethodin classBaseMethodBinding<ca.uhn.fhir.rest.api.MethodOutcome>
-
invokeServer
public Object invokeServer(IRestfulServer<?> theServer, RequestDetails theRequest) throws ca.uhn.fhir.rest.server.exceptions.BaseServerResponseException, IOException
- Specified by:
invokeServerin classBaseMethodBinding<ca.uhn.fhir.rest.api.MethodOutcome>- Throws:
ca.uhn.fhir.rest.server.exceptions.BaseServerResponseExceptionIOException
-
isReturnVoid
public boolean isReturnVoid()
-
provideAllowableRequestTypes
protected abstract Set<ca.uhn.fhir.rest.api.RequestTypeEnum> provideAllowableRequestTypes()
-
-