discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSPredicate


From: Fred Kiefer
Subject: Re: NSPredicate
Date: Sat, 01 Nov 2008 01:23:17 +0100
User-agent: Thunderbird 2.0.0.17 (X11/20080922)

Richard Frith-Macdonald wrote:
> 
> On 31 Oct 2008, at 20:20, Fred Kiefer wrote:
> 
>> Samantha Rahn wrote:
>>> What types of syntax can and cannot be used in NSPredicate?
>>>
>>> When I use
>>>
>>>    companyName CONTAINS 'Corp'
>>>
>>> I get:
>>>
>>>    NAME:NSInvalidArgumentException REASON:Format string contains
>>> extra characters: "companyName CONTAINS 'Corp'"
>>>
>>
>> I had a look at the source code and it looks like we are missing code
>> for the parsing of string constants. Somebody will have to add this.
> 
> Looked simple, so I added it ... try svn trunk to see if it works.
> 
>> The whole file NSPredicate.m needs a make over, we should split it up
>> and replace the current scanner with something more powerful.
> 
> What is needed?  The current NSScanner based implementation has lots of
> method call overheads and is obviously going to be slower than something
> similar written in pure C, but it's not obvious to me that it's less
> powerful (and it has the advantage of re-using reliable code).
> I'm not familiar with NSPredicate though, so I could easily be missing
> some disadvantage.

Thank you. Looks like you are more familiar with NSScanner than me and
if you think it is a supportable way of implementing this, we should
stay with it.







reply via email to

[Prev in Thread] Current Thread [Next in Thread]