MPLogEvent /5.5.0

@interface MPLogEvent : NSObject

Logging event used to construct pre-formatted messages.

Public Properties

NSString/message /+5.5.0

  • Description: Message to be logged.

  • Declaration:

    @property (readonly, copy, nonatomic) NSString *_Nonnull message;
    
  • Parameters: None.

MPBLogLevel/logLevel /+5.5.0

  • Description: Level at which the message should be logged.

  • Declaration:

    @property (readonly, assign, nonatomic) MPBLogLevel logLevel;
    

Public Methods

  • Parameters: None.

-/initWithMessage: /+5.5.0

  • Description: Initializes the log event with the specified message to be logged at Debug level. Returns the log event.

  • Declaration:

    - (nonnull instancetype)initWithMessage:(nonnull NSString *)message;
    
  • Parameters:

    • message: Message to log.

-/initWithMessage:level: /+5.5.0

  • Description: Initializes the log event with the specified message to be logged at the desired log level.

  • Declaration:

    - (nonnull instancetype)initWithMessage:(nonnull NSString *)message
                                    level:(MPBLogLevel)level;
    
  • Parameters:

    • message: Message to log.
    • level: Level at which the message should be logged.

+/error:message: /+5.5.0

  • Description: Initializes a generic error log event with optional message. The message and error will be logged at Debug level. Returns the log event.

  • Declaration:

    + (nonnull instancetype)error:(nonnull NSError *)error
                        message:(NSString *_Nullable)message;
    
  • Parameters:

    • error: Error to log.
    • message: Optional message that will prefix the error message.

+/eventWithMessage:level: /+5.5.0

  • Description: Initializes the log event with the specified message to be logged at the desired log level. Returns the log event.

  • Declaration:

    + (nonnull instancetype)eventWithMessage:(nonnull NSString *)message
                                     level:(MPBLogLevel)level;
    
  • Parameters:

    • level: Level at which the message should be logged

Last updated October 06, 2020

TWITTER, MOPUB, and the Bird logo are trademarks of Twitter, Inc. or its affiliates. All third party logos and trademarks included are the property of their respective owners.

© 2020 MoPub (a division of Twitter, Inc.)