Class CLogErrorBuffer

java.lang.Object
java.util.logging.Handler
org.compiere.util.CLogErrorBuffer

public class CLogErrorBuffer extends Handler
Handler that publish log record to the system error output stream
Version:
$Id: CLogErrorBuffer.java,v 1.3 2006/07/30 00:54:36 jjanke Exp $
Author:
Jorg Janke, Teo Sarca, teo.sarca@gmail.com
  • BF [ 2973298 ] NPE on CLogErrorBuffer
    • Constructor Details

      • CLogErrorBuffer

        public CLogErrorBuffer()
        Constructor
    • Method Details

      • isIssueError

        public boolean isIssueError()
        Is Issue Error (Save to MIssue)
        Returns:
        true if issue error
      • setIssueError

        public void setIssueError(boolean issueError)
        Set Issue Error (Save to MIssue)
        Parameters:
        issueError - issue error
      • setLevel

        public void setLevel(Level newLevel) throws SecurityException
        Set Level.
        Ignore OFF - and higher then FINE
        Overrides:
        setLevel in class Handler
        Parameters:
        newLevel - ignored
        Throws:
        SecurityException
        See Also:
      • publish

        public void publish(LogRecord record)
        Publish
        Specified by:
        publish in class Handler
        Parameters:
        record - log record
        See Also:
      • flush

        public void flush()
        Flush (NOP)
        Specified by:
        flush in class Handler
        See Also:
      • close

        public void close() throws SecurityException
        Close
        Specified by:
        close in class Handler
        Throws:
        SecurityException
        See Also:
      • getColumnNames

        public Vector<String> getColumnNames(Properties ctx)
        Get ColumnNames of Log Entries
        Parameters:
        ctx - context (not used)
        Returns:
        string vector
      • getLogData

        public Vector<Vector<Object>> getLogData(boolean errorsOnly)
        Get Log Data
        Parameters:
        errorsOnly - if true errors otherwise log
        Returns:
        data array
      • getRecords

        public LogRecord[] getRecords(boolean errorsOnly)
        Get Array of events with most recent first
        Parameters:
        errorsOnly - if true errors otherwise log
        Returns:
        array of events
      • resetBuffer

        public void resetBuffer(boolean errorsOnly)
        Reset Error Buffer
        Parameters:
        errorsOnly - if true errors otherwise log
      • getErrorInfo

        public String getErrorInfo(Properties ctx, boolean errorsOnly)
        Get/Put Error Info in String
        Parameters:
        ctx - context
        errorsOnly - if true errors otherwise log
        Returns:
        error info
      • toString

        public String toString()
        String Representation
        Overrides:
        toString in class Object
        Returns:
        info
      • get

        public static CLogErrorBuffer get(boolean create)
        Get or create CLogErrorBuffer handler instance.
        Parameters:
        create -
        Returns:
        CLogErrorBuffer handler instance