Class NopService

  • All Implemented Interfaces:
    AuditLogService

    public class NopService
    extends java.lang.Object
    implements AuditLogService
    This class serves as a no-op audit service logger. It simply allows audit logging to be effectively disabled.
    • Constructor Summary

      Constructors 
      Constructor Description
      NopService()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void initialize​(PropertyGroup auditLogProperties)
      Performs any required audit log service initialization using the passed Properties file.
      boolean isEnabled()  
      void logEntry​(AuditLogEntry logEntry)
      Persists the passed audit log entry in a location determined by the log service.
      void stop​(PropertyGroup auditLogProperties)
      Performs any required audit log service stops
      • Methods inherited from class java.lang.Object

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

      • NopService

        public NopService()
    • Method Detail

      • isEnabled

        public boolean isEnabled()
        Specified by:
        isEnabled in interface AuditLogService
        Returns:
        true if the audit log service is enabled; false if not enabled.
      • initialize

        public void initialize​(PropertyGroup auditLogProperties)
                        throws java.lang.Exception
        Description copied from interface: AuditLogService
        Performs any required audit log service initialization using the passed Properties file.
        Specified by:
        initialize in interface AuditLogService
        Parameters:
        auditLogProperties - - Contains audit log related properties which are configured in fhir-server-config.json.
        Throws:
        java.lang.Exception - - Any non-recoverable exception thrown during audit log service initialization.
      • stop

        public void stop​(PropertyGroup auditLogProperties)
                  throws java.lang.Exception
        Description copied from interface: AuditLogService
        Performs any required audit log service stops
        Specified by:
        stop in interface AuditLogService
        Parameters:
        auditLogProperties - - Contains audit log related properties which are configured in fhir-server-config.json.
        Throws:
        java.lang.Exception - - Any non-recoverable exception thrown during audit log service initialization.
      • logEntry

        public void logEntry​(AuditLogEntry logEntry)
        Description copied from interface: AuditLogService
        Persists the passed audit log entry in a location determined by the log service.
        Specified by:
        logEntry in interface AuditLogService
        Parameters:
        logEntry - - The audit log entry to be saved.