标签: ios objective-c cocoa-touch nspredicate
来自apple doc:
这两个谓词给出了同样的结果:
大写SELF:
NSPredicate *predicate = [NSPredicate predicateWithFormat: @"SELF.userType != %@", typeStr];
Lowecased SELF:
NSPredicate *predicate = [NSPredicate predicateWithFormat: @"self.userType != %@", typeStr];
保留字是否区分大小写?
答案 0 :(得分:0)
参见Predicate Format String Syntax “谓词字符串解析器对空格不敏感,对关键字不区分大小写,并支持嵌套的括号表达式。”