Class ServerCapabilityStatementProvider

java.lang.Object
ca.uhn.fhir.rest.server.util.BaseServerCapabilityStatementProvider
org.hl7.fhir.dstu3.hapi.rest.server.ServerCapabilityStatementProvider
All Implemented Interfaces:
ca.uhn.fhir.rest.server.IServerConformanceProvider<CapabilityStatement>

public class ServerCapabilityStatementProvider extends ca.uhn.fhir.rest.server.util.BaseServerCapabilityStatementProvider implements ca.uhn.fhir.rest.server.IServerConformanceProvider<CapabilityStatement>
Server FHIR Provider which serves the conformance statement for a RESTful server implementation

Note: This class is safe to extend, but it is important to note that the same instance of CapabilityStatement is always returned unless setCache(boolean) is called with a value of false. This means that if you are adding anything to the returned conformance instance on each call you should call setCache(false) in your provider constructor.

  • Constructor Summary

    Constructors
    Constructor
    Description
    No-arg constructor and setter so that the ServerConformanceProvider can be Spring-wired with the RestfulService avoiding the potential reference cycle that would happen.
    ServerCapabilityStatementProvider​(ca.uhn.fhir.rest.server.RestfulServer theRestfulServer)
    Deprecated.
    Use no-args constructor instead.
    ServerCapabilityStatementProvider​(ca.uhn.fhir.rest.server.RestfulServerConfiguration theServerConfiguration)
    Constructor - This is intended only for JAX-RS server
  • Method Summary

    Modifier and Type
    Method
    Description
    Gets the value of the "publisher" that will be placed in the generated conformance statement.
    getServerConformance​(javax.servlet.http.HttpServletRequest theRequest, ca.uhn.fhir.rest.api.server.RequestDetails theRequestDetails)
     
    readOperationDefinition​(IdType theId, ca.uhn.fhir.rest.api.server.RequestDetails theRequestDetails)
     
    setCache​(boolean theCache)
    Deprecated.
    Since 4.0.0 this doesn't do anything
    void
    setPublisher​(String thePublisher)
    Sets the value of the "publisher" that will be placed in the generated conformance statement.
    void
    setRestfulServer​(ca.uhn.fhir.rest.server.RestfulServer theRestfulServer)
     

    Methods inherited from class ca.uhn.fhir.rest.server.util.BaseServerCapabilityStatementProvider

    getServerConfiguration

    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.server.IServerConformanceProvider

    readOperationDefinition
  • Constructor Details

    • ServerCapabilityStatementProvider

      No-arg constructor and setter so that the ServerConformanceProvider can be Spring-wired with the RestfulService avoiding the potential reference cycle that would happen.
    • ServerCapabilityStatementProvider

      @Deprecated public ServerCapabilityStatementProvider(ca.uhn.fhir.rest.server.RestfulServer theRestfulServer)
      Deprecated.
      Use no-args constructor instead. Deprecated in 4.0.0
      Constructor
    • ServerCapabilityStatementProvider

      public ServerCapabilityStatementProvider(ca.uhn.fhir.rest.server.RestfulServerConfiguration theServerConfiguration)
      Constructor - This is intended only for JAX-RS server
  • Method Details

    • getPublisher

      public String getPublisher()
      Gets the value of the "publisher" that will be placed in the generated conformance statement. As this is a mandatory element, the value should not be null (although this is not enforced). The value defaults to "Not provided" but may be set to null, which will cause this element to be omitted.
    • setPublisher

      public void setPublisher(String thePublisher)
      Sets the value of the "publisher" that will be placed in the generated conformance statement. As this is a mandatory element, the value should not be null (although this is not enforced). The value defaults to "Not provided" but may be set to null, which will cause this element to be omitted.
    • getServerConformance

      public CapabilityStatement getServerConformance(javax.servlet.http.HttpServletRequest theRequest, ca.uhn.fhir.rest.api.server.RequestDetails theRequestDetails)
      Specified by:
      getServerConformance in interface ca.uhn.fhir.rest.server.IServerConformanceProvider<CapabilityStatement>
    • readOperationDefinition

      public OperationDefinition readOperationDefinition(IdType theId, ca.uhn.fhir.rest.api.server.RequestDetails theRequestDetails)
    • setCache

      public ServerCapabilityStatementProvider setCache(boolean theCache)
      Deprecated.
      Since 4.0.0 this doesn't do anything
      Sets the cache property (default is true). If set to true, the same response will be returned for each invocation.

      See the class documentation for an important note if you are extending this class

    • setRestfulServer

      public void setRestfulServer(ca.uhn.fhir.rest.server.RestfulServer theRestfulServer)
      Specified by:
      setRestfulServer in interface ca.uhn.fhir.rest.server.IServerConformanceProvider<CapabilityStatement>