Constants
Predefined
count for use with
Search and Replace methods to specify all matches are to be replaced.
RegexKit Framework errors.
The corresponding value is a
NSAttributedString that contains the string from
RKAbreviatedRegexStringErrorKey with attributes highlightling the location of the error. Intended for errors displayed to the user in which there is only a limited amount of space available or the display of a lengthy regular expression may be inappropriate.
The corresponding value is a truncated version of the regular expression that caused the error which is composed of a small number of characters to the left and to the right of the position that caused the error. Intended for errors displayed to the user in which there is only a limited amount of space available or the display of a lengthy regular expression may be inappropriate.
The corresponding value is a NSNumber containing the array index for the regular expression that caused the error. This error key is only set by the sorted regex collection methods.
The corresponding value is a NSAttributedString that contains the regular expression that caused the error with attributes highlightling the location of the error.
The corresponding value is the collection that contains the regular expression that caused the error. This error key is only set by the sorted regex collection methods.
The corresponding value is a
NSNumber of the
RKCompileErrorCode for the regular expression that caused the error.
The corresponding value is a
NSString representation of the
RKCompileErrorCode for the regular expression that caused the error.
The corresponding value is a
NSArray of
NSString objects representing the
RKCompileOption bits for the regular expression that cause the error.
The corresponding value is a
NSString representation of the
RKCompileOption bits joined together with the C bitwise OR operator for the regular expression that cause the error.
The corresponding value is a
NSNumber containing the
RKCompileOption for the regular expression that cause the error.
The corresponding value is the regular expression object from the collection that caused the error. This error key is only set by the sorted regex collection methods.
The corresponding value is the regular expression library that caused the error.
The corresponding value is the error string provided by the regular expression library that caused the error.
The corresponding value is the regular expression that caused the error.
Name of the exception that occurs when a capture reference (ie, $1) has an error.
Name of the exception that occurs when the regular expression to be compiled with the given options has an error.
Name of the exception that occurs when an unsupported feature or option is used.
Preprocessor definition to enable RegexKit specific DTrace probe points.
#define ENABLE_DTRACE_INSTRUMENTATION
This preprocessor define enables support for RegexKit specific DTrace probe points.
Preprocessor definition to enable Mac OS X 10.5 (Leopard) Garbage Collection.
#define ENABLE_MACOSX_GARBAGE_COLLECTION
This preprocessor define enables support for Garbage Collection on Mac OS X 10.5 (Leopard). Traditional retain / release functionality remains allowing the framework to be used in either Garbage Collected enabled applications or reference counting applications. The framework dynamically picks which mode to use at run-time base on whether or not the Garbage Collection system is active.
Preprocessor definition for cross-platform NSInteger functionality.
#define RKInteger NSInteger
On Mac OS X 10.5 this is defined to be NSInteger, otherwise it is defined as int.
This is done as a preprocessor macro so that it is rewritten in to the proper type for the build environment for type checking.
Preprocessor definition for cross-platform NSIntegerMax functionality.
#define RKIntegerMax NSIntegerMax
On Mac OS X 10.5 this is defined to be NSIntegerMax, otherwise it is defined as INT_MAX.
Preprocessor definition for cross-platform NSIntegerMin functionality.
#define RKIntegerMin NSIntegerMin
On Mac OS X 10.5 this is defined to be NSIntegerMin, otherwise it is defined as INT_MIN.
Preprocessor definition for making functions static inline.
#define RKREGEX_STATIC_INLINE static __inline__ __attribute__((always_inline))
RKREGEX_STATIC_INLINE is a wrapper around GCC 4+ directives to always static inline.
Borrowed from Mac OS X NSObjCRuntime.h FOUNDATION_STATIC_INLINE to be portable to GNUstep.
Evaluates to static __inline__ for compilers other than GCC 4+.
Preprocessor definition for cross-platform NSUInteger functionality.
#define RKUIntegerMax NSUIntegerMax
On Mac OS X 10.5 this is defined to be NSUInteger, otherwise it is defined as unsigned int.
This is done as a preprocessor macro so that it is rewritten in to the proper type for the build environment for type checking.
Preprocessor definition for cross-platform NSUIntegerMax functionality.
#define RKUIntegerMax NSUIntegerMax
On Mac OS X 10.5 this is defined to be NSUIntegerMax, otherwise it is defined as UINT_MAX.
#define RK_ATTRIBUTES(attr,...) __attribute__((attr, ##__VA_ARGS__))
When a compiler other than GCC 4+ is used, RK_ATTRIBUTES evaluates to an empty string, removing itself and its arguments from the code to be compiled.
Macro wrapper around C99 keywords.
#define RK_C99(keyword) keyword
RK_C99 is a wrapper for C99 standard keywords that are not compatible with previous C standards, such as C89.
This is used almost exclusively to wrap the C99 restrict keyword.
Macro to assist the compiler by providing branch prediction information.
#define RK_EXPECTED(cond,expect) __builtin_expect(cond, expect)
-
cond
The boolean conditional statement to be evaluated, for example (aPtr == NULL).
-
expect
The expected result of the conditional statement, expressed as a 0 or a 1.
Important:
RK_EXPECTED should only be used when the likelihood of the prediction is nearly certain. DO NOT GUESS.
RK_EXPECTED is a wrapper around the GCC 4+ built-in function __builtin_expect, which is used to provide the compiler with branch prediction information for conditional statements. If a compiler other than GCC 4+ is used then the macro leaves the conditional expression unaltered.
An example of an appropriate use is parameter validation checks at the start of a function, such as (aPtr == NULL). Since callers are always expected to pass a valid pointer, the likelyhood of the conditional evaluating to true is extremely unlikely. This allows the compiler to schedule instructions to minimize branch miss-prediction penalties. For example:
if(RK_EXPECTED((aPtr == NULL), 0)) { abort(); }
Compile time check for functions and methods that support a varying number of arguments that must be terminated with a NULL or nil as the last argument.
#define RK_REQUIRES_NIL_TERMINATION NS_REQUIRES_NIL_TERMINATION
Supported on Mac OS X 10.5 and later.
The PCRE regular expression pattern matching library.