
Package ca.uhn.fhir.rest.server.method
Class OperationMethodBinding
java.lang.Object
ca.uhn.fhir.rest.server.method.BaseMethodBinding
ca.uhn.fhir.rest.server.method.BaseResourceReturningMethodBinding
ca.uhn.fhir.rest.server.method.OperationMethodBinding
- Direct Known Subclasses:
GraphQLMethodBinding,ValidateMethodBindingDstu2Plus
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class ca.uhn.fhir.rest.server.method.BaseResourceReturningMethodBinding
BaseResourceReturningMethodBinding.MethodReturnTypeEnum, BaseResourceReturningMethodBinding.ReturnTypeEnum -
Field Summary
FieldsFields inherited from class ca.uhn.fhir.rest.server.method.BaseResourceReturningMethodBinding
myResponseBundleBuilder -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedOperationMethodBinding(Class<?> theReturnResourceType, Class<? extends org.hl7.fhir.instance.model.api.IBaseResource> theReturnTypeFromRp, Method theMethod, ca.uhn.fhir.context.FhirContext theContext, Object theProvider, boolean theIdempotent, boolean theDeleteEnabled, String theOperationName, Class<? extends org.hl7.fhir.instance.model.api.IBaseResource> theOperationType, String theOperationTypeName, ca.uhn.fhir.rest.annotation.OperationParam[] theReturnParams, ca.uhn.fhir.model.valueset.BundleTypeEnum theBundleType, boolean theGlobal) OperationMethodBinding(Class<?> theReturnResourceType, Class<? extends org.hl7.fhir.instance.model.api.IBaseResource> theReturnTypeFromRp, Method theMethod, ca.uhn.fhir.context.FhirContext theContext, Object theProvider, ca.uhn.fhir.rest.annotation.Operation theAnnotation) Constructor - This is the constructor that is called when binding a standard @Operation method. -
Method Summary
Modifier and TypeMethodDescriptiongetName()Returns the name of the operation, starting with "$"protected ca.uhn.fhir.model.valueset.BundleTypeEnumIf the response is a bundle, this type will be placed in the root of the bundle (can be null)ca.uhn.fhir.rest.api.RestOperationTypeEnumca.uhn.fhir.rest.api.RestOperationTypeEnumgetRestOperationType(RequestDetails theRequestDetails) Determine which operation is being fired for a specific requestincomingServerRequestMatchesMethod(RequestDetails theRequest) invokeServer(IRestfulServer<?> theServer, RequestDetails theRequest) invokeServer(IRestfulServer<?> theServer, RequestDetails theRequest, Object[] theMethodParams) booleanbooleanbooleanbooleanbooleanSubclasses may override to declare that they apply to all resource typesbooleanbooleanprotected voidpopulateRequestDetailsForInterceptor(RequestDetails theRequestDetails, Object[] theMethodParams) Subclasses may override this method (but should also call super) to provide method specifics to the interceptors.voidsetDescription(String theDescription) toString()Methods inherited from class ca.uhn.fhir.rest.server.method.BaseResourceReturningMethodBinding
callOutgoingFailureOperationOutcomeHook, callOutgoingResponseHook, doInvokeServer, getMethodReturnType, getResourceName, isAddContentLocationHeader, isOffsetModeHistory, provideExpectedReturnTypes, setResourceNameMethods inherited from class ca.uhn.fhir.rest.server.method.BaseMethodBinding
bindMethod, close, createMethodParams, createParametersForServerRequest, getAllowableParamAnnotations, getContext, getIncludes, getMethod, getParameters, getProvider, getQueryParameters, getRequestIncludesFromParams, getRevIncludes, invokeServerMethod, isSupportsConditional, isSupportsConditionalMultiple, setParameters, toResourceList, verifyMethodHasZeroOrOneOperationAnnotation
-
Field Details
-
WILDCARD_NAME
- See Also:
-
-
Constructor Details
-
OperationMethodBinding
public OperationMethodBinding(Class<?> theReturnResourceType, Class<? extends org.hl7.fhir.instance.model.api.IBaseResource> theReturnTypeFromRp, Method theMethod, ca.uhn.fhir.context.FhirContext theContext, Object theProvider, ca.uhn.fhir.rest.annotation.Operation theAnnotation) Constructor - This is the constructor that is called when binding a standard @Operation method. -
OperationMethodBinding
protected OperationMethodBinding(Class<?> theReturnResourceType, Class<? extends org.hl7.fhir.instance.model.api.IBaseResource> theReturnTypeFromRp, Method theMethod, ca.uhn.fhir.context.FhirContext theContext, Object theProvider, boolean theIdempotent, boolean theDeleteEnabled, String theOperationName, Class<? extends org.hl7.fhir.instance.model.api.IBaseResource> theOperationType, String theOperationTypeName, ca.uhn.fhir.rest.annotation.OperationParam[] theReturnParams, ca.uhn.fhir.model.valueset.BundleTypeEnum theBundleType, boolean theGlobal)
-
-
Method Details
-
getShortDescription
-
isGlobalMethod
Description copied from class:BaseMethodBindingSubclasses may override to declare that they apply to all resource types- Overrides:
isGlobalMethodin classBaseMethodBinding
-
getDescription
-
setDescription
-
getName
Returns the name of the operation, starting with "$" -
getResponseBundleType
Description copied from class:BaseResourceReturningMethodBindingIf the response is a bundle, this type will be placed in the root of the bundle (can be null)- Specified by:
getResponseBundleTypein classBaseResourceReturningMethodBinding
-
getRestOperationType
- Specified by:
getRestOperationTypein classBaseMethodBinding
-
getReturnParams
-
getReturnType
- Specified by:
getReturnTypein classBaseResourceReturningMethodBinding
-
incomingServerRequestMatchesMethod
- Specified by:
incomingServerRequestMatchesMethodin classBaseMethodBinding
-
getRestOperationType
public ca.uhn.fhir.rest.api.RestOperationTypeEnum getRestOperationType(RequestDetails theRequestDetails) Description copied from class:BaseMethodBindingDetermine which operation is being fired for a specific request- Overrides:
getRestOperationTypein classBaseMethodBinding- Parameters:
theRequestDetails- The request
-
toString
-
invokeServer
public Object invokeServer(IRestfulServer<?> theServer, RequestDetails theRequest) throws ca.uhn.fhir.rest.server.exceptions.BaseServerResponseException, IOException - Overrides:
invokeServerin classBaseResourceReturningMethodBinding- Throws:
ca.uhn.fhir.rest.server.exceptions.BaseServerResponseExceptionIOException
-
invokeServer
public Object invokeServer(IRestfulServer<?> theServer, RequestDetails theRequest, Object[] theMethodParams) throws ca.uhn.fhir.rest.server.exceptions.BaseServerResponseException - Specified by:
invokeServerin classBaseResourceReturningMethodBinding- Throws:
ca.uhn.fhir.rest.server.exceptions.BaseServerResponseException
-
isCanOperateAtInstanceLevel
-
isCanOperateAtServerLevel
-
isCanOperateAtTypeLevel
-
isIdempotent
-
isDeleteEnabled
-
populateRequestDetailsForInterceptor
protected void populateRequestDetailsForInterceptor(RequestDetails theRequestDetails, Object[] theMethodParams) Description copied from class:BaseMethodBindingSubclasses may override this method (but should also call super) to provide method specifics to the interceptors.- Overrides:
populateRequestDetailsForInterceptorin classBaseMethodBinding- Parameters:
theRequestDetails- The server request detailstheMethodParams- The method params as generated by the specific method binding
-
isManualRequestMode
-
getCanonicalUrl
-