Update of /cvsroot/eas-dev/eas-dev/components/logger/src
In directory sc8-pr-cvs1:/tmp/cvs-serv5135/components/logger/src
Modified Files:
consolelogger.cxx consolelogger.hxx logger.cxx
Removed Files:
logger_impls.hxx
Log Message:
minor changes in build process; `logger' component rewritten to 'handle'
log records; compiles but not tested yet. sigslot library added to common includes.
another minor changes
Index: consolelogger.cxx
===================================================================
RCS file: /cvsroot/eas-dev/eas-dev/components/logger/src/consolelogger.cxx,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- consolelogger.cxx 1 Feb 2003 04:10:19 -0000 1.2
+++ consolelogger.cxx 3 Feb 2003 09:06:51 -0000 1.3
@@ -63,8 +63,6 @@
Mutex m_mutex;
sal_Int32 m_nRefCount;
- sal_Bool m_ignore[8];
-
public:
@@ -97,20 +95,12 @@
static Sequence< OUString > SAL_CALL getSupportedServiceNames_Static();
// XConsoleLogger
- virtual void SAL_CALL ignoreLogLevel (logLevel aLL, sal_Bool bOnOff)
- throw (RuntimeException)
- {
- m_ignore[aLL] = bOnOff;
- }
-
- virtual void SAL_CALL log(logLevel aLL, const OUString& message)
+ virtual void SAL_CALL log(const OUString& message)
throw (RuntimeException)
{
- if (!m_ignore[aLL])
cout << message;
+ cout.flush();
}
-
-#include "logger_impls.hxx"
};
Index: consolelogger.hxx
===================================================================
RCS file: /cvsroot/eas-dev/eas-dev/components/logger/src/consolelogger.hxx,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- consolelogger.hxx 1 Feb 2003 04:10:19 -0000 1.2
+++ consolelogger.hxx 3 Feb 2003 09:06:52 -0000 1.3
@@ -24,8 +24,6 @@
Mutex m_mutex;
sal_Int32 m_nRefCount;
- sal_Bool m_ignore[8];
-
public:
@@ -53,9 +51,9 @@
// XXConsoleLogger
virtual void SAL_CALL ignoreLogLevel (logLevel aLL, sal_Bool bOnOff)
throw (RuntimeException);
- virtual void SAL_CALL log(logLevel aLL, const OUString& message)
+ virtual void SAL_CALL log(const OUString& message)
throw (RuntimeException);
- Sequence<OU_String> SAL_CALL getImplementations() throw (RuntimeException);
+ Sequence<OUString> SAL_CALL getImplementations() throw (RuntimeException);
};
Reference<XInterface> SAL_CALL XConsoleLoggerImpl_create(
Index: logger.cxx
===================================================================
RCS file: /cvsroot/eas-dev/eas-dev/components/logger/src/logger.cxx,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- logger.cxx 2 Feb 2003 06:59:11 -0000 1.3
+++ logger.cxx 3 Feb 2003 09:06:52 -0000 1.4
@@ -66,6 +66,7 @@
sal_Int32 m_nRefCount;
sal_Bool m_ignore[8];
+ Reference<XLoggerHandler> m_handler;
public:
@@ -105,10 +106,19 @@
{
m_ignore[aLL] = bOnOff;
}
-
+
virtual void SAL_CALL log(logLevel aLL, const OUString& message)
throw (RuntimeException)
{
+ if (!m_ignore[aLL])
+ m_handler->log(message);
+
+ }
+
+ virtual void SAL_CALL setHandler(const Reference<XLoggerHandler>& xHandler)
+ throw (RuntimeException)
+ {
+ m_handler = xHandler;
}
};
--- logger_impls.hxx DELETED ---
|