nspredicate
Searching files - Objective-C
I am trying to search for a file. This returns 0 results. Does anyone know why? NSMetadataQuery *q = [[NSMetadataQuery alloc] init];[详细]
2023-03-14 01:43 分类:问答Creating Predicate to Test the Number of Relationship
Say I have a Business object in core data. The Business object may or may not have phones. I want to create an NSPredicate object where only Businesses with Phones would work.[详细]
2023-03-14 01:17 分类:问答Result of NSPredicate as a string
NSPredicate *predicate; 开发者_高级运维predicate = [NSPredicate predicateWithFormat:@\"SELF CONTAINS \'aaa\'\"];[详细]
2023-03-12 23:35 分类:问答why wont this NSPredicate work?
i have a list of objects being managed by CoreData. i want to get a specific object out of CoreData using an NSPredicate. below is the code i am using. Array arr always comes back with 0 objects in it[详细]
2023-03-12 22:33 分类:问答Shorter way to write NSPredicate format string for testing multiple properties?
Is there a shorter way to write the format string for a predicate equivalent to this: [NSPredicate predicateWithFormat: @\"key1 CONTAINS[cd] %@ OR key2 CONTAINS[cd] %@ OR key3 CONTAINS[cd] %@\", sear[详细]
2023-03-12 13:02 分类:问答NSPredicate with Multiple parameters
Hello Need help with predicate. The problem is that I want to have one function which will fetch from database depends on the multiple values it receives, but the values don\'t always exist, does it m[详细]
2023-03-11 16:30 分类:问答Detect Phone number in a NSString
I want to extract the phone number from a NSString. For ex: In the strin开发者_如何学Cg Call John @ 994-456-9966, i want to extract 994-456-9966.[详细]
2023-03-11 08:44 分类:问答How to get specific string in NSPredicate
How to get the string 开发者_StackOverflow中文版\"NSMetadataItemFSNameKey == *\" in a NSPredicate? predicateWithFormat doesn\'t work and crashes.[详细]
2023-03-11 02:58 分类:问答nspredicate questions
I tried applying NSPredicate with core data, but how to apply it with NSMutableArray of classes? I mean: I have NSMutableArray contai开发者_运维技巧ning objects of class that have fields. How do I s[详细]
2023-03-10 18:59 分类:问答Get all items starting with a given string
I want to get all items which start with a given string. The code below returns thousands of items when I do not use the predicate, but when it is present I get zero records returned.[详细]
2023-03-10 18:58 分类:问答