AWSLogger Class Reference

Inherits from NSObject
Declared in AWSLogging.h
AWSLogging.m

Overview

AWSLogger is an utility class that handles logging to the console. Changing log levels during development may make debugging easier. You can change the log level by importing AWSCore.h and calling:

Swift

 AWSLogger.defaultLogger().logLevel = .None

The following logging level options are available:

 .None
 .Error
 .Warn
 .Info
 .Debug (This is the default.)
 .Verbose

Objective-C

 [AWSLogger defaultLogger].logLevel = AWSLogLevelNone;

The following logging level options are available:

 AWSLogLevelNone
 AWSLogLevelError
 AWSLogLevelWarn
 AWSLogLevelInfo
 AWSLogLevelDebug (This is the default.)
 AWSLogLevelVerbose

Note: We recommend setting the log level to None before publishing to the Apple App Store.

  logLevel

The log level setting. The default value is Debug.

@property (atomic, assign) AWSLogLevel logLevel

Declared In

AWSLogging.h

+ defaultLogger

Returns the shared logger object.

+ (instancetype)defaultLogger

Return Value

The shared logger object.

Declared In

AWSLogging.h

– log:format:

Prints out the formatted logs to the console. You can use the following predefined shorthand methods instead:

- (void)log:(AWSLogLevel)logLevel format:(NSString *)fmt, ...

Parameters

logLevel

The level of this log.

fmt

The formatted string to log.

Discussion

 AWSLogError(fmt, ...)
 AWSLogWarn(fmt, ...)
 AWSLogInfo(fmt, ...)
 AWSLogDebug(fmt, ...)
 AWSLogVerbose(fmt, ...)

Declared In

AWSLogging.h