init
TypeScriptstatic initFormatArgumentArray(predicateFormat: string, arguments_?: (Array<unknown>) | null): NSPredicateSwift declarationinit(format predicateFormat: String, argumentArray arguments: [Any]?)class · iOS 3.0+ · SDK 27.1
class NSPredicatestatic initFormatArgumentArray(predicateFormat: string, arguments_?: (Array<unknown>) | null): NSPredicateSwift declarationinit(format predicateFormat: String, argumentArray arguments: [Any]?)static initValue(value: boolean): NSPredicateSwift declarationinit(value: Bool)allowEvaluation(): voidSwift declarationfunc allowEvaluation()allowEvaluationValidator(validator: Implements<NSPredicateValidating> | SDKHandle): voidSwift declarationfunc allowEvaluation(validator: any NSPredicateValidating) throwsevaluateWith(object?: (unknown) | null): booleanSwift declarationfunc evaluate(with object: Any?) -> BoolevaluateWithSubstitutionVariables(object?: (unknown) | null, bindings?: (Record<string, unknown>) | null): booleanSwift declarationfunc evaluate(with object: Any?, substitutionVariables bindings: [String : Any]?) -> BoolwithSubstitutionVariables(variables: Record<string, unknown>): NSPredicateSwift declarationfunc withSubstitutionVariables(_ variables: [String : Any]) -> Selfget predicateFormat(): stringSwift declarationvar predicateFormat: String { get }static init(predicate: Predicate<_ObjectiveC_NSObject>): (NSPredicate) | nullSwift declarationconvenience init?<Input>(_ predicate: Predicate<Input>) where Input : NSObjectCreates a predicate by converting an existing predicate. Only a subset of predicates that can be expressed by `Predicate` are convertible to `NSPredicate`. Predicates that include operations like the following can't be converted: - Accessing key paths for properties that aren't exposed to the Objective-C runtime. - Capturing values of types that aren't supported by `NSPredicate`, like custom Swift structures. - Using some functions or operators, like performing collection operations on a nonstring value. - Parameters: - predicate: The predicate to convert. - Returns: The converted predicate, or `nil` if conversion fails.
4 declarations were excluded from these bindings. Each reason comes from the generator or the iOS SDK compiler.
NSPredicate.init(format:_:)
A variable number of Swift arguments is not supported.
NSPredicate.init(format:arguments:)
A C variable argument list cannot cross the bridge.
NSPredicate.init(block:)
callback cannot propagate synchronous failure
NSPredicate.init()
inherited init: cannot prove legal (class declares 6 custom initializers)