final void roll ( final long timeForSuffix ) { final File backupFile = this . prepareBackupFile ( timeForSuffix ) ; // close filename this . getAppender ( ) . closeFile ( ) ; // rename filename on disk to filename+suffix(+number) this . doFileRoll ( this . getAppender ( ) . getIoFile ( ) , backupFile ) ; // setup new file 'filename' this . getAppender ( ) . openFile ( ) ; this . fireFileRollEvent ( new FileRollEvent ( this , backupFile ) ) ; }
Invoked by subclasses ; performs actual file roll . Tests to see whether roll is necessary have already been performed so just do it .