Skip to content
This repository has been archived by the owner on Aug 11, 2021. It is now read-only.

Update: Obj-C code #118

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Lumberjack/DDASLLogger.m
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ + (DDASLLogger *)sharedInstance
return sharedInstance;
}

- (id)init
- (instancetype)init
{
if (sharedInstance != nil)
{
Expand Down Expand Up @@ -73,7 +73,7 @@ - (void)logMessage:(DDLogMessage *)logMessage

if (logMsg)
{
const char *msg = [logMsg UTF8String];
const char *msg = logMsg.UTF8String;

int aslLogLevel;
switch (logMessage->logFlag)
Expand Down
2 changes: 1 addition & 1 deletion Lumberjack/DDAbstractDatabaseLogger.m
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ - (void)destroyDeleteTimer;

@implementation DDAbstractDatabaseLogger

- (id)init
- (instancetype)init
{
if ((self = [super init]))
{
Expand Down
30 changes: 15 additions & 15 deletions Lumberjack/DDFileLogger.h
Original file line number Diff line number Diff line change
Expand Up @@ -73,19 +73,19 @@

// Public methods

- (NSString *)logsDirectory;
@property (NS_NONATOMIC_IOSONLY, readonly, copy) NSString *logsDirectory;

- (NSArray *)unsortedLogFilePaths;
- (NSArray *)unsortedLogFileNames;
- (NSArray *)unsortedLogFileInfos;
@property (NS_NONATOMIC_IOSONLY, readonly, copy) NSArray *unsortedLogFilePaths;
@property (NS_NONATOMIC_IOSONLY, readonly, copy) NSArray *unsortedLogFileNames;
@property (NS_NONATOMIC_IOSONLY, readonly, copy) NSArray *unsortedLogFileInfos;

- (NSArray *)sortedLogFilePaths;
- (NSArray *)sortedLogFileNames;
- (NSArray *)sortedLogFileInfos;
@property (NS_NONATOMIC_IOSONLY, readonly, copy) NSArray *sortedLogFilePaths;
@property (NS_NONATOMIC_IOSONLY, readonly, copy) NSArray *sortedLogFileNames;
@property (NS_NONATOMIC_IOSONLY, readonly, copy) NSArray *sortedLogFileInfos;

// Private methods (only to be used by DDFileLogger)

- (NSString *)createNewLogFile;
@property (NS_NONATOMIC_IOSONLY, readonly, copy) NSString *createNewLogFile;

@optional

Expand Down Expand Up @@ -119,8 +119,8 @@
NSString *_logsDirectory;
}

- (id)init;
- (id)initWithLogsDirectory:(NSString *)logsDirectory;
- (instancetype)init;
- (instancetype)initWithLogsDirectory:(NSString *)logsDirectory NS_DESIGNATED_INITIALIZER;

/* Inherited from DDLogFileManager protocol:

Expand Down Expand Up @@ -159,8 +159,8 @@
NSDateFormatter *dateFormatter;
}

- (id)init;
- (id)initWithDateFormatter:(NSDateFormatter *)dateFormatter;
- (instancetype)init;
- (instancetype)initWithDateFormatter:(NSDateFormatter *)dateFormatter NS_DESIGNATED_INITIALIZER;

@end

Expand All @@ -181,8 +181,8 @@
NSTimeInterval rollingFrequency;
}

- (id)init;
- (id)initWithLogFileManager:(id <DDLogFileManager>)logFileManager;
- (instancetype)init;
- (instancetype)initWithLogFileManager:(id <DDLogFileManager>)logFileManager NS_DESIGNATED_INITIALIZER;

/**
* Log File Rolling:
Expand Down Expand Up @@ -285,7 +285,7 @@

+ (id)logFileWithPath:(NSString *)filePath;

- (id)initWithFilePath:(NSString *)filePath;
- (instancetype)initWithFilePath:(NSString *)filePath NS_DESIGNATED_INITIALIZER;

- (void)reset;
- (void)renameFile:(NSString *)newFileName;
Expand Down
Loading