|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectch.qos.logback.core.spi.ContextAwareBase
ch.qos.logback.core.UnsynchronizedAppenderBase<E>
ch.qos.logback.core.OutputStreamAppender<E>
ch.qos.logback.core.FileAppender<E>
ch.qos.logback.core.rolling.RollingFileAppender<E>
public class RollingFileAppender<E>
RollingFileAppender
extends FileAppender
to backup the
log files depending on RollingPolicy
and TriggeringPolicy
.
For more information about this appender, please refer to the online manual at http://logback.qos.ch/manual/appenders.html#RollingFileAppender
Field Summary |
---|
Fields inherited from class ch.qos.logback.core.FileAppender |
---|
append, fileName |
Fields inherited from class ch.qos.logback.core.OutputStreamAppender |
---|
encoder, lock |
Fields inherited from class ch.qos.logback.core.UnsynchronizedAppenderBase |
---|
name, started |
Fields inherited from class ch.qos.logback.core.spi.ContextAwareBase |
---|
context |
Constructor Summary | |
---|---|
RollingFileAppender()
|
Method Summary | |
---|---|
String |
getFile()
Returns the value of the File property. |
RollingPolicy |
getRollingPolicy()
|
TriggeringPolicy<E> |
getTriggeringPolicy()
|
void |
rollover()
Implemented by delegating most of the rollover work to a rolling policy. |
void |
setFile(String file)
The File property takes a string value which should be the name of the file to append to. |
void |
setRollingPolicy(RollingPolicy policy)
Sets the rolling policy. |
void |
setTriggeringPolicy(TriggeringPolicy<E> policy)
|
void |
start()
If the value of File is not null , then
FileAppender.openFile(java.lang.String) is called with the values of File and
Append properties. |
void |
stop()
Stop this appender instance. |
protected void |
subAppend(E event)
This method differentiates RollingFileAppender from its super class. |
Methods inherited from class ch.qos.logback.core.FileAppender |
---|
isAppend, isPrudent, openFile, rawFileProperty, setAppend, setPrudent, writeOut |
Methods inherited from class ch.qos.logback.core.OutputStreamAppender |
---|
append, closeOutputStream, getEncoder, getOutputStream, setEncoder, setLayout, setOutputStream |
Methods inherited from class ch.qos.logback.core.UnsynchronizedAppenderBase |
---|
addFilter, clearAllFilters, doAppend, getCopyOfAttachedFiltersList, getFilterChainDecision, getName, isStarted, setName, toString |
Methods inherited from class ch.qos.logback.core.spi.ContextAwareBase |
---|
addError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, getDeclaredOrigin, getStatusManager, setContext |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface ch.qos.logback.core.spi.ContextAware |
---|
addError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, setContext |
Constructor Detail |
---|
public RollingFileAppender()
Method Detail |
---|
public void start()
FileAppender
null
, then
FileAppender.openFile(java.lang.String)
is called with the values of File and
Append properties.
start
in interface LifeCycle
start
in class FileAppender<E>
public void stop()
OutputStreamAppender
Stopped appenders cannot be reused.
stop
in interface LifeCycle
stop
in class OutputStreamAppender<E>
public void setFile(String file)
FileAppender
setFile
in class FileAppender<E>
public String getFile()
FileAppender
This method may be overridden by derived classes.
getFile
in class FileAppender<E>
public void rollover()
protected void subAppend(E event)
subAppend
in class OutputStreamAppender<E>
public RollingPolicy getRollingPolicy()
public TriggeringPolicy<E> getTriggeringPolicy()
public void setRollingPolicy(RollingPolicy policy)
TriggeringPolicy
, then the triggering policy for this appender is
automatically set to be the policy argument.
policy
- public void setTriggeringPolicy(TriggeringPolicy<E> policy)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |