com.ibm.cics.server

Class EnterRequest

  • All Implemented Interfaces:
    java.io.Serializable


    public class EnterRequest
    extends API
    implements java.io.Serializable
    This class is used to make trace entries in the currently active trace destinations. CICS writes the trace entry only if the main and user trace flags are on, unless isException() is true, in which case a user trace entry is always written, even if the main and user trace flags are off.

    You can use the exception trace option in an application program to write a trace entry when the program detects an exception or abnormal condition. To do this, call setException(true) before calling enterTrace(byte[]) in your program's exception or abnormal condition error-handling routine.

    This provides the equivalent of the EXEC CICS ENTER TRACENUM command.

    See Also:
    Serialized Form
    Since CICS TS version:
    1.3
    Since package version:
    1.0.0
    • Constructor Summary

      Constructors 
      Constructor and Description
      EnterRequest() 
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void enterTrace()
      Writes a trace entry without data.
      void enterTrace(byte[] data)
      Writes a trace entry with data.
      java.lang.String getResource() 
      short getTraceIdentifier() 
      boolean isException()
      Gets whether CICS will write a user exception trace entry.
      void setException(boolean traceException)
      Specifies whether CICS is to write a user exception trace entry.
      void setResource(java.lang.String resource)
      Specifies an 8-character name to be entered into the resource field of the trace table entry.
      void setTraceIdentifier(short traceId)
      Specifies the trace identifier for a user trace table entry with a value in the range 0 through 199.
      • Methods inherited from class java.lang.Object

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

      • EnterRequest

        public EnterRequest()
        Since CICS TS version:
        1.3
        Since package version:
        1.0.0
    • Method Detail

      • getResource

        public java.lang.String getResource()
        Returns:
        The 8-character name to be entered into the resource field of the trace table entry.
        See Also:
        setResource(String)
        Since CICS TS version:
        1.3
        Since package version:
        1.0.0
      • setResource

        public void setResource(java.lang.String resource)
        Specifies an 8-character name to be entered into the resource field of the trace table entry. Use a name that identifies the user trace, for example, the name of the calling program.

        The resource name must be 8 characters long. If the value supplied is too short then it is padded with spaces. If the value is too long then it is truncated.

        If the resource is null or blank (contains only space characters) it will be omitted from the command.

        Parameters:
        resource - The resource field of the trace table entry.
        Since CICS TS version:
        1.3
        Since package version:
        1.0.0
      • getTraceIdentifier

        public short getTraceIdentifier()
        Returns:
        The trace identifier for the user trace table entry.
        See Also:
        setTraceIdentifier(short)
        Since CICS TS version:
        1.3
        Since package version:
        1.0.0
      • setTraceIdentifier

        public void setTraceIdentifier(short traceId)
        Specifies the trace identifier for a user trace table entry with a value in the range 0 through 199.
        Parameters:
        traceId - The trace identifier.
        Since CICS TS version:
        1.3
        Since package version:
        1.0.0
      • isException

        public boolean isException()
        Gets whether CICS will write a user exception trace entry.
        Returns:
        true if CICS will write a user exception trace entry.
        See Also:
        setException(boolean)
        Since CICS TS version:
        1.3
        Since package version:
        1.0.0
      • setException

        public void setException(boolean traceException)
        Specifies whether CICS is to write a user exception trace entry. If true, this option overrides the main user trace flag, and CICS writes the trace entry even if the user trace flag is off.
        Parameters:
        traceException - true if CICS is to write a user exception trace entry.
        Since CICS TS version:
        1.3
        Since package version:
        1.0.0