com.sapportals.wcm.util.log

Class FileChannel

java.lang.Object
  extended by com.sapportals.wcm.util.log.AbstractChannel
      extended by com.sapportals.wcm.util.log.FileChannel
All Implemented Interfaces:
IChannel

public class FileChannel
extends AbstractChannel
implements IChannel

Channel for writing log output to a file


Field Summary
 
Fields inherited from class com.sapportals.wcm.util.log.AbstractChannel
formatter, m_maxBacklog, m_maxSize, m_showStackTraces, m_showThreads
 
Constructor Summary
FileChannel(String fileName, Long maxSize, Integer maxBacklog, Boolean showStackTraces, Boolean showThreads)
          Construct
 
Method Summary
 void finalize()
          Close the output stream
 void log(String method, int level, Object message, Throwable throwable)
          Log
 void setFileName(String fileName)
          Set the name of the file the output is written to
 
Methods inherited from class com.sapportals.wcm.util.log.AbstractChannel
getDateTimeString, getLogLevelText, getLogText
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FileChannel

public FileChannel(String fileName,
                   Long maxSize,
                   Integer maxBacklog,
                   Boolean showStackTraces,
                   Boolean showThreads)
            throws Exception
Construct

Parameters:
fileName - TBD: Description of the incoming method parameter
maxSize - TBD: Description of the incoming method parameter
maxBacklog - TBD: Description of the incoming method parameter
showStackTraces - TBD: Description of the incoming method parameter
showThreads - TBD: Description of the incoming method parameter
Throws:
Exception - Exception raised in failure situation
Method Detail

setFileName

public void setFileName(String fileName)
                 throws FileNotFoundException
Set the name of the file the output is written to

Parameters:
fileName - fileName to be set
Throws:
FileNotFoundException - Exception raised in failure situation

finalize

public void finalize()
Close the output stream

Overrides:
finalize in class Object

log

public void log(String method,
                int level,
                Object message,
                Throwable throwable)
Log

Specified by:
log in interface IChannel
Parameters:
method - TBD: Description of the incoming method parameter
level - TBD: Description of the incoming method parameter
message - TBD: Description of the incoming method parameter
throwable - TBD: Description of the incoming method parameter
Access Rights

This class can be accessed from:


SC DC Public Part ACH
[sap.com] KMC-CM [sap.com] tc/km/frwk api EP-KM-CM
[sap.com] KMC-WPC [sap.com] tc/kmc/wpc/wpcfacade api EP-PIN-WPC-WCM


Copyright 2014 SAP AG Complete Copyright Notice