Package com.yahoo.log

Class FileLogTarget

  • All Implemented Interfaces:
    LogTarget

    public class FileLogTarget
    extends java.lang.Object
    implements LogTarget
    Since:
    5.1
    Author:
    Ulf Lilleengen
    • Constructor Summary

      Constructors 
      Constructor Description
      FileLogTarget​(java.io.File target)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void close()
      Close the log target, ensuring that all data is written.
      java.io.OutputStream open()
      Opens an output stream for the target.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • FileLogTarget

        public FileLogTarget​(java.io.File target)
                      throws java.io.FileNotFoundException
        Throws:
        java.io.FileNotFoundException
    • Method Detail

      • open

        public java.io.OutputStream open()
        Description copied from interface: LogTarget
        Opens an output stream for the target. If already open, the stream should be reopened.
        Specified by:
        open in interface LogTarget
        Returns:
        a new outputstream for the log target.
      • close

        public void close()
        Description copied from interface: LogTarget
        Close the log target, ensuring that all data is written.
        Specified by:
        close in interface LogTarget
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object