Class BaseParam

java.lang.Object
ca.uhn.fhir.rest.param.BaseParam
All Implemented Interfaces:
IQueryParameterType, Serializable
Direct Known Subclasses:
BaseParamWithPrefix, CompositeParam, HasParam, ReferenceParam, SpecialParam, StringParam, TokenParam, UriParam

public abstract class BaseParam extends Object implements IQueryParameterType
Base class for RESTful operation parameter types
See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    If set to non-null value, indicates that this parameter has been populated with a "[name]:missing=true" or "[name]:missing=false" vale instead of a normal value
    final String
    This method will return any qualifier that should be appended to the parameter name (e.g ":exact").
    final String
    Returns a representation of this parameter's value as it will be represented "over the wire".
    protected boolean
    Does this parameter type support chained parameters (only reference should return true for this)
    setMissing(Boolean theMissing)
    If set to non-null value, indicates that this parameter has been populated with a "[name]:missing=true" or "[name]:missing=false" value instead of a normal value
    final void
    setValueAsQueryToken(FhirContext theContext, String theParamName, String theQualifier, String theValue)
    This method is generally only called by HAPI itself, and should not need to be called from user code.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • getMissing

      public Boolean getMissing()
      If set to non-null value, indicates that this parameter has been populated with a "[name]:missing=true" or "[name]:missing=false" vale instead of a normal value
      Specified by:
      getMissing in interface IQueryParameterType
    • getQueryParameterQualifier

      Description copied from interface: IQueryParameterType
      This method will return any qualifier that should be appended to the parameter name (e.g ":exact"). Returns null if none are present.
      Specified by:
      getQueryParameterQualifier in interface IQueryParameterType
    • getValueAsQueryToken

      public final String getValueAsQueryToken(FhirContext theContext)
      Description copied from interface: IQueryParameterType
      Returns a representation of this parameter's value as it will be represented "over the wire". In other words, how it will be presented in a URL (although not URL escaped)

      See FHIR specification 2.2.2 Search SearchParameter Types for information on the token format

      Specified by:
      getValueAsQueryToken in interface IQueryParameterType
      Parameters:
      theContext - TODO
      Returns:
      Returns a representation of this parameter's value as it will be represented "over the wire". In other words, how it will be presented in a URL (although not URL escaped)
    • isSupportsChain

      protected boolean isSupportsChain()
      Does this parameter type support chained parameters (only reference should return true for this)
    • setMissing

      public BaseParam setMissing(Boolean theMissing)
      If set to non-null value, indicates that this parameter has been populated with a "[name]:missing=true" or "[name]:missing=false" value instead of a normal value
      Specified by:
      setMissing in interface IQueryParameterType
      Returns:
      Returns a reference to this for easier method chaining
    • setValueAsQueryToken

      public final void setValueAsQueryToken(FhirContext theContext, String theParamName, String theQualifier, String theValue)
      Description copied from interface: IQueryParameterType
      This method is generally only called by HAPI itself, and should not need to be called from user code.

      See FHIR specification 2.2.2 Search SearchParameter Types for information on the token format

      Specified by:
      setValueAsQueryToken in interface IQueryParameterType
      Parameters:
      theContext - TODO
      theParamName - TODO
      theQualifier - The parameter name qualifier that accompanied this value. For example, if the complete query was http://foo?name:exact=John, qualifier would be ":exact"
      theValue - The actual parameter value. For example, if the complete query was http://foo?name:exact=John, the value would be "John"