// Private interface private void Process_Incoming_Frame( COutboundLogFrame frame ) { foreach ( var request in frame.Requests ) { if ( !CGenericHandlerManager.Instance.Try_Handle( request ) ) { throw new CApplicationException( String.Format( "Logging request of type {0} does not have a handler", request.GetType().Name ) ); } } }
public static void Flush_Frame() { if ( Frame != null && !Frame.Empty ) { CLogFrameManager.Instance.PublicInterface.Send( Frame ); Frame = null; } }
public static void Log( ELoggingChannel channel, ELogLevel log_level, string log_text ) { if ( log_level > Get_Log_Level() || log_level <= ELogLevel.None ) { return; } if ( Frame == null ) { Frame = new COutboundLogFrame(); } Frame.Add_Request( new CLogMessageRequest( channel, log_text ) ); }
public static void Configure( string filename_prefix ) { m_FileNamePrefix = filename_prefix; if ( Frame == null ) { Frame = new COutboundLogFrame(); } Frame.Add_Request( new CConfigureLoggingRequest( filename_prefix, m_LogDirectory ) ); Cleanup_Old_Logs(); }