Class FHIRBasicAuthenticator

  • All Implemented Interfaces:
    javax.ws.rs.client.ClientRequestFilter

    public class FHIRBasicAuthenticator
    extends java.lang.Object
    implements javax.ws.rs.client.ClientRequestFilter
    This class is responsible for adding the Authorization header to outbound REST API requests.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void filter​(javax.ws.rs.client.ClientRequestContext ctxt)
      This method is called by the JAX-RS client runtime and will add an Authorization header to the outbound REST API request to supply the necessary basic auth security token.
      java.lang.String getPassword()  
      java.lang.String getUsername()  
      void setPassword​(java.lang.String password)  
      void setUsername​(java.lang.String username)  
      • Methods inherited from class java.lang.Object

        clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • FHIRBasicAuthenticator

        protected FHIRBasicAuthenticator()
      • FHIRBasicAuthenticator

        public FHIRBasicAuthenticator​(java.lang.String user,
                                      java.lang.String password)
    • Method Detail

      • getUsername

        public java.lang.String getUsername()
      • setUsername

        public void setUsername​(java.lang.String username)
      • getPassword

        public java.lang.String getPassword()
      • setPassword

        public void setPassword​(java.lang.String password)
      • filter

        public void filter​(javax.ws.rs.client.ClientRequestContext ctxt)
                    throws java.io.IOException
        This method is called by the JAX-RS client runtime and will add an Authorization header to the outbound REST API request to supply the necessary basic auth security token.
        Specified by:
        filter in interface javax.ws.rs.client.ClientRequestFilter
        Throws:
        java.io.IOException