com.ibm.commerce.ras

Class ECTracingProvider

  • java.lang.Object
    • com.ibm.commerce.ras.ECTracingProvider
  • All Implemented Interfaces:
    ITracingService


    public final class ECTracingProvider
    extends java.lang.Object
    implements ITracingService
    ECTracingProvider is used to configure tracing and write the tracing information to output.
    • Field Summary

      Fields 
      Modifier and Type Field and Description
      static java.lang.String COPYRIGHT
      IBM copyright notice field.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void disable()
      Disables tracing subsystem.
      void disable(long componentId)
      Disables a specific tracing component.
      void disableTracing()
      Disables tracing subsystem.
      void enable()
      Enables tracing subsystem.
      void enable(long componentId)
      Enables a specific tracing component.
      void enableTracing()
      Enables tracing subsystem.
      void entry(long componentId, java.lang.String className, java.lang.String methodName)
      Writes an entry in the trace file to record the entry from a method.
      void entry(long componentId, java.lang.String className, java.lang.String methodName, java.lang.Object[] param)
      Writes an entry in the trace file to record the entry from a method.
      void exit(long componentId, java.lang.String className, java.lang.String methodName)
      Writes an entry in the trace file to record the exit from a method
      void exit(long componentId, java.lang.String className, java.lang.String methodName, java.lang.Object retValue)
      Writes an entry in the trace file to record the exit from a method
      static long getComponent(java.lang.Object comp)
      Gets the component id
      static java.lang.String getComponentName(long componentId)
      Gets the component name.
      int getSizeOfComponent()
      Returns the number of tracing components.
      static ECTracingProvider getUniqueInstance()
      Gets an unique instance of ECTracingProvider.
      boolean isClientInfoEnabled()
      Checks if client tracing information is enabled.
      boolean isTraceable(long componentId)
      This method is used to check if a particular component is tracable.
      boolean isTraceEnabled()
      Checks if tracing is enabled.
      void overrideMask(int[] componentMask)
      Updates the status of the tracing components.
      void setClientInfoEnabled(boolean value)
      Sets the Client Tracing information option.
      void trace(long componentId, java.lang.String className, java.lang.String methodName, java.lang.String text)
      Writes an entry in the trace file to record a trace point in a method.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • COPYRIGHT

        public static final java.lang.String COPYRIGHT
        IBM copyright notice field.
        See Also:
        Constant Field Values
    • Constructor Detail

      • ECTracingProvider

        public ECTracingProvider()
    • Method Detail

      • disable

        public void disable()
        Disables tracing subsystem.
      • disable

        public void disable(long componentId)
        Disables a specific tracing component.
        Specified by:
        disable in interface ITracingService
        Parameters:
        component - tracing component
      • enable

        public void enable()
        Enables tracing subsystem.
      • enable

        public void enable(long componentId)
        Enables a specific tracing component.
        Specified by:
        enable in interface ITracingService
        Parameters:
        component - tracing component
      • entry

        public void entry(long componentId,
                          java.lang.String className,
                          java.lang.String methodName)
        Writes an entry in the trace file to record the entry from a method.
        Specified by:
        entry in interface ITracingService
        Parameters:
        componentId - tracing component
        className - class name
        methodName - method name
      • entry

        public void entry(long componentId,
                          java.lang.String className,
                          java.lang.String methodName,
                          java.lang.Object[] param)
        Writes an entry in the trace file to record the entry from a method.
        Specified by:
        entry in interface ITracingService
        Parameters:
        componentId - tracing component
        className - class name
        methodName - method name
        param - the entry parameters to the method.
      • exit

        public void exit(long componentId,
                         java.lang.String className,
                         java.lang.String methodName)
        Writes an entry in the trace file to record the exit from a method
        Specified by:
        exit in interface ITracingService
        Parameters:
        componentId - tracing component
        className - class name
        methodName - method name
      • exit

        public void exit(long componentId,
                         java.lang.String className,
                         java.lang.String methodName,
                         java.lang.Object retValue)
        Writes an entry in the trace file to record the exit from a method
        Specified by:
        exit in interface ITracingService
        Parameters:
        componentId - tracing component
        className - class name
        methodName - method name
        retValue - return object value
      • getComponent

        public static long getComponent(java.lang.Object comp)
        Gets the component id
        Parameters:
        comp - component Object
      • getComponentName

        public static java.lang.String getComponentName(long componentId)
        Gets the component name.
        Parameters:
        componentId - tracing component Id
      • getSizeOfComponent

        public int getSizeOfComponent()
        Returns the number of tracing components.
        Returns:
        number of tracing components
      • getUniqueInstance

        public static ECTracingProvider getUniqueInstance()
        Gets an unique instance of ECTracingProvider.
        Returns:
        unique instance of ECTracingProvider
      • isClientInfoEnabled

        public boolean isClientInfoEnabled()
        Checks if client tracing information is enabled.
        Specified by:
        isClientInfoEnabled in interface ITracingService
        Returns:
        true if client tracing information is enabled; false otherwise
      • isTraceable

        public boolean isTraceable(long componentId)
        This method is used to check if a particular component is tracable.
        Specified by:
        isTraceable in interface ITracingService
        Parameters:
        componentId - tracing component Id
        Returns:
        true if the tracing component is traceable; false otherwise
      • isTraceEnabled

        public boolean isTraceEnabled()
        Checks if tracing is enabled.
        Specified by:
        isTraceEnabled in interface ITracingService
        Returns:
        true if tracing subsystem is enabled
      • overrideMask

        public void overrideMask(int[] componentMask)
        Updates the status of the tracing components.
      • trace

        public void trace(long componentId,
                          java.lang.String className,
                          java.lang.String methodName,
                          java.lang.String text)
        Writes an entry in the trace file to record a trace point in a method.
        Specified by:
        trace in interface ITracingService
        Parameters:
        componentName - the name of the component to which the class to be traced belongs
        classname - the name of the class to be traced
        methodName - the name of the method to be traced
        text - the text to be recorded
      • setClientInfoEnabled

        public void setClientInfoEnabled(boolean value)
        Sets the Client Tracing information option.
        Specified by:
        setClientInfoEnabled in interface ITracingService
        Parameters:
        value - client tracing information enablement value