GCKLoggerFilter Class

GCKLoggerFilter Class Reference

Overview

A class for filtering log messages that are produced using GCKLogger.

Since
3.0

Inherits NSObject.

Instance Method Summary

(instancetype) - init
 Constructs a new GCKLoggerFilter with empty criteria. More...
 
(void) - setLoggingLevel:forClasses:
 Sets the minimum logging level that will be passed by the filter for the set of matching classes. More...
 
(void) - setLoggingLevel:forFunctions:
 Sets the minimum logging level that will be passed by the filter for the set of matching function names. More...
 
(void) - addClassNames:
 Adds a list of class names to be matched by the filter. More...
 
(void) - addClassNames:minimumLogLevel:
 Adds a list of class names to be matched by the filter, specifying a minimum logging level. More...
 
(void) - addFunctionNames:
 Adds a list of non-member function names to be matched by the filter. More...
 
(void) - addFunctionNames:minimumLogLevel:
 Adds a list of non-member function names to be matched by the filter, specifying a minimum logging level. More...
 
(void) - addMessagePatterns:
 Adds a list of regular expression patterns for matching the text of the log messages. More...
 
(void) - addMessagePatterns:caseInsensitive:
 Adds a list of regular expression patterns for matching the text of the log messages with optional case-insensitivity. More...
 
(void) - reset
 Resets the filter; removing all match criteria. More...
 

Property Summary

BOOL exclusive
 A flag indicating whether the filter is exclusive (YES) or inclusive (NO). More...
 
GCKLoggerLevel minimumLevel
 The minimum logging level that will be logged from this filter. More...
 

Method Detail

- (instancetype) init

Constructs a new GCKLoggerFilter with empty criteria.

- (void) setLoggingLevel: (GCKLoggerLevel)  minimumLevel
forClasses: (NSArray< NSString * > *)  classNames 

Sets the minimum logging level that will be passed by the filter for the set of matching classes.

Glob patterns are supported for the class names.

Parameters
minimumLevelThe minimum logging level for these classes. May be GCKLoggerLevelVerbose. to include all levels.
classNamesA list of class names.
Since
3.3
- (void) setLoggingLevel: (GCKLoggerLevel)  minimumLevel
forFunctions: (NSArray< NSString * > *)  functionNames 

Sets the minimum logging level that will be passed by the filter for the set of matching function names.

Glob patterns are supported.

Parameters
minimumLevelThe minimum logging level for these functions. May be GCKLoggerLevelVerbose to include all levels.
functionNamesA list of function names.
Since
3.3
- (void) addClassNames: (NSArray< NSString * > *)  classNames

Adds a list of class names to be matched by the filter.

A class name can be a simple name or the name of an extension, for example, @"MyClass" or @"MyClass(MyExtension)". If an extension is not included in the name, all extensions of the class will be included implicitly. Glob patterns are supported.

Deprecated:
Use setLoggingLevel:forClasses: instead.
- (void) addClassNames: (NSArray< NSString * > *)  classNames
minimumLogLevel: (GCKLoggerLevel)  minimumLogLevel 

Adds a list of class names to be matched by the filter, specifying a minimum logging level.

A class name can be a simple name or the name of an extension, for example, @"MyClass" or @"MyClass(MyExtension)". If an extension is not included in the name, all extensions of the class will be included implicitly. Glob patterns are supported.

Deprecated:
Use setLoggingLevel:forClasses: instead.
Parameters
classNamesThe class names.
minimumLogLevelThe minimum level to log; may be GCKLoggerLevelVerbose to log all levels.
Since
3.2
- (void) addFunctionNames: (NSArray< NSString * > *)  functionNames

Adds a list of non-member function names to be matched by the filter.

Glob patterns are supported.

Deprecated:
Use setLoggingLevel:forFunctions: instead.
- (void) addFunctionNames: (NSArray< NSString * > *)  functionNames
minimumLogLevel: (GCKLoggerLevel)  minimumLogLevel 

Adds a list of non-member function names to be matched by the filter, specifying a minimum logging level.

Glob patterns are supported.

Deprecated:
Use setLoggingLevel:forFunctions: instead.
Parameters
functionNamesThe function names.
minimumLogLevelThe minimum level to log; may be GCKLoggerLevelVerbose to log all levels.
Since
3.2
- (void) addMessagePatterns: (NSArray< NSString * > *)  messagePatterns

Adds a list of regular expression patterns for matching the text of the log messages.

- (void) addMessagePatterns: (NSArray< NSString * > *)  messagePatterns
caseInsensitive: (BOOL)  caseInsensitive 

Adds a list of regular expression patterns for matching the text of the log messages with optional case-insensitivity.

Deprecated:
Use addMessagePatterns: with inline (?-i) or (?i) instead.
- (void) reset

Resets the filter; removing all match criteria.

Property Detail

- (BOOL) exclusive
readwritenonatomicassign

A flag indicating whether the filter is exclusive (YES) or inclusive (NO).

By default filters are inclusive, that is, they accept all log messages that match the filter.

Deprecated:
No longer implemented; value is ignored.
- (GCKLoggerLevel) minimumLevel
readwritenonatomicassign

The minimum logging level that will be logged from this filter.

Since
3.2