);
buildSettings = {
DYLIB_COMPATIBILITY_VERSION = 1;
- DYLIB_CURRENT_VERSION = 4.5.126;
+ DYLIB_CURRENT_VERSION = 4.5.127;
FRAMEWORK_SEARCH_PATHS = "$(LOCAL_LIBRARY_DIR)/Frameworks";
FRAMEWORK_VERSION = A;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
--- /dev/null
+/*
+ Copyright (C) 2000-2004 SKYRIX Software AG
+
+ This file is part of OpenGroupware.org.
+
+ OGo is free software; you can redistribute it and/or modify it under
+ the terms of the GNU Lesser General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ OGo is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with OGo; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.
+*/
+
+#ifndef __NGExtensions_NGLogAppender_H_
+#define __NGExtensions_NGLogAppender_H_
+
+/*
+ Abstract superclass for all appenders.
+*/
+
+#import <Foundation/Foundation.h>
+#include <NGExtensions/NSObject+ExtendedLogging.h>
+
+@class NGLogEvent;
+
+@interface NGLogAppender : NSObject
+{
+}
+
+/* subclass responsibility */
+- (void)appendLogEvent:(NGLogEvent *)_event;
+- (NSString *)formattedEvent:(NGLogEvent *)_event;
+
+- (NSString *)localizedNameOfLogLevel:(NGLogLevel)_level;
+
+@end
+
+#endif /* __NGExtensions_NGLogAppender_H_ */
--- /dev/null
+/*
+ Copyright (C) 2000-2004 SKYRIX Software AG
+
+ This file is part of OpenGroupware.org.
+
+ OGo is free software; you can redistribute it and/or modify it under
+ the terms of the GNU Lesser General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ OGo is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with OGo; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.
+*/
+
+#ifndef __NGExtensions_NGLogConsoleAppender_H_
+#define __NGExtensions_NGLogConsoleAppender_H_
+
+#include <NGExtensions/NGLogAppender.h>
+
+@interface NGLogConsoleAppender : NGLogAppender
+{
+}
+
+@end
+
+#endif /* __NGExtensions_NGLogConsoleAppender_H_ */
--- /dev/null
+/*
+ Copyright (C) 2000-2004 SKYRIX Software AG
+
+ This file is part of OpenGroupware.org.
+
+ OGo is free software; you can redistribute it and/or modify it under
+ the terms of the GNU Lesser General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ OGo is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with OGo; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.
+*/
+
+#ifndef __NGExtensions_NGLogEvent_H_
+#define __NGExtensions_NGLogEvent_H_
+
+#import <Foundation/Foundation.h>
+#include <NGExtensions/NSObject+ExtendedLogging.h>
+
+
+@interface NGLogEvent : NSObject
+{
+ NSString *msg;
+ NGLogLevel level;
+ NSTimeInterval date;
+}
+
+- (id)initWithLevel:(NGLogLevel)_level message:(NSString *)_msg;
+
+- (NGLogLevel)level;
+- (NSString *)message;
+- (NSDate *)date;
+
+@end
+
+#endif /* __NGExtensions_NGLogEvent_H_ */
--- /dev/null
+/*
+ Copyright (C) 2000-2004 SKYRIX Software AG
+
+ This file is part of OpenGroupware.org.
+
+ OGo is free software; you can redistribute it and/or modify it under
+ the terms of the GNU Lesser General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ OGo is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with OGo; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.
+*/
+
+#ifndef __NGExtensions_NGLogSyslogAppender_H_
+#define __NGExtensions_NGLogSyslogAppender_H_
+
+#include <NGExtensions/NGLogAppender.h>
+
+@interface NGLogSyslogAppender : NGLogAppender
+{
+}
+
++ (id)sharedAppender;
+
+/* provide syslog identifier */
+- (id)initWithIdentifier:(NSString *)_ident;
+
+@end
+
+#endif /* __NGExtensions_NGLogSyslogAppender_H_ */
--- /dev/null
+/*
+ Copyright (C) 2000-2004 SKYRIX Software AG
+
+ This file is part of OpenGroupware.org.
+
+ OGo is free software; you can redistribute it and/or modify it under
+ the terms of the GNU Lesser General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ OGo is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with OGo; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.
+*/
+
+#ifndef __NGExtensions_NGLogger_H_
+#define __NGExtensions_NGLogger_H_
+
+/*
+ The logger, modeled closely after log4j.
+ */
+
+#import <Foundation/Foundation.h>
+#include <NGExtensions/NSObject+ExtendedLogging.h>
+
+
+@interface NGLogger : NSObject
+{
+ NGLogLevel logLevel;
+ id _appender; // going away as soon as we have a config
+}
+
+- (id)initWithLogLevel:(NGLogLevel)_level;
+
+- (void)logLevel:(NGLogLevel)_level message:(NSString *)_msg;
+- (void)logLevel:(NGLogLevel)_level withFormat:(NSString *)_fmt, ...;
+
+- (void)setLogLevel:(NGLogLevel)_level;
+- (NGLogLevel)logLevel;
+
+@end
+
+#endif /* __NGExtensions_NGLogger_H_ */
--- /dev/null
+/*
+ Copyright (C) 2000-2004 SKYRIX Software AG
+
+ This file is part of OpenGroupware.org.
+
+ OGo is free software; you can redistribute it and/or modify it under
+ the terms of the GNU Lesser General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ OGo is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with OGo; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.
+*/
+
+#ifndef __NGExtensions_NGLoggerManager_H_
+#define __NGExtensions_NGLoggerManager_H_
+
+#import <Foundation/Foundation.h>
+
+@class NGLogger;
+
+@interface NGLoggerManager : NSObject
+{
+ NSMutableDictionary *loggerMap;
+}
+
++ (id)defaultManager;
+
+- (NGLogger *)loggerForDefaultKey:(NSString *)_defaultKey;
+
+@end
+
+#endif /* __NGExtensions_NGLoggerManager_H_ */
--- /dev/null
+/*
+ Copyright (C) 2000-2004 SKYRIX Software AG
+
+ This file is part of OpenGroupware.org.
+
+ OGo is free software; you can redistribute it and/or modify it under
+ the terms of the GNU Lesser General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ OGo is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with OGo; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.
+*/
+
+#ifndef __NGExtensions_NGLogging_H_
+#define __NGExtensions_NGLogging_H_
+
+/*
+ NGLogging is a somewhat more sophisticated logging framework, modeled
+ apparently similar to log4j - without some of its bloat.
+*/
+
+#include <NGExtensions/NSObject+ExtendedLogging.h>
+#include <NGExtensions/NGLogger.h>
+#include <NGExtensions/NGLoggerManager.h>
+#include <NGExtensions/NGLogEvent.h>
+#include <NGExtensions/NGLogAppender.h>
+#include <NGExtensions/NGLogConsoleAppender.h>
+#include <NGExtensions/NGLogSyslogAppender.h>
+
+#endif /* __NGExtensions_NGLogging_H_ */
--- /dev/null
+/*
+ Copyright (C) 2000-2004 SKYRIX Software AG
+
+ This file is part of OpenGroupware.org.
+
+ OGo is free software; you can redistribute it and/or modify it under
+ the terms of the GNU Lesser General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ OGo is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with OGo; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.
+*/
+
+#ifndef __NSObject_ExtendedLogging_H_
+#define __NSObject_ExtendedLogging_H_
+
+#import <Foundation/Foundation.h>
+
+typedef enum {
+ NGLogLevelOff = 0,
+ NGLogLevelDebug = 1,
+ NGLogLevelInfo = 2,
+ NGLogLevelWarn = 3,
+ NGLogLevelError = 4,
+ NGLogLevelFatal = 5,
+ NGLogLevelAll = 6
+} NGLogLevel;
+
+@interface NSObject (NGExtendedLogging)
+
+- (id)logger;
+
+- (void)logDebugWithFormat:(NSString *)_fmt, ...;
+- (void)logInfoWithFormat:(NSString *)_fmt, ...;
+- (void)logWarnWithFormat:(NSString *)_fmt, ...;
+- (void)logErrorWithFormat:(NSString *)_fmt, ...;
+- (void)logFatalWithFormat:(NSString *)_fmt, ...;
+
+- (BOOL)isLogDebugEnabled;
+- (BOOL)isLogInfoEnabled;
+- (BOOL)isLogWarnEnabled;
+- (BOOL)isLogErrorEnabled;
+- (BOOL)isLogFatalEnabled;
+
+- (void)logLevel:(NGLogLevel)_level message:(NSString *)_msg;
+- (void)logLevel:(NGLogLevel)_level withFormat:(NSString *)_fmt, ...;
+
+@end
+
+#endif /* __NSObject_ExtendedLogging_H_ */