Re: NSInvocationOperation error
Richard Frith-Macdonald <[email protected]> Fri, 3 Dec 2010 18:55:34 +0000
| Newsgroups | gmane.comp.lib.gnustep.user |
|---|---|
| Message-ID | <[email protected]> |
On 3 Dec 2010, at 18:30, Germ=E1n Arias wrote: > Well, in the GNUstep documentation I don't see NSInvocationOperation > class. Then, I suppose this class don't exist on GNUstep. >=20 > On jue, 2010-12-02 at 21:36 -0800, aphuk wrote: >> Hi, I am new to Objective-C and GNUstep so my question might be a = little >> basic but please help me out since I am stuck. >>=20 >> We are trying to create an instance of a NSInvocationOperation and = put it in >> the NSOperationQueue as given below >>=20 >> NSInvocationOperation* putOp =3D [[[NSInvocationOperation alloc] >> initWithTarget:self selector:@selector(put) >> = object:[NSNumber >> numberWithInt:5]] autorelease]; >>=20 >> But on compilation, I get the below error : >>=20 >> NSInvocationOperation undeclared (first use in this function) >>=20 >> What am I missing here? Yes, this is a non-existent class. Searching the web for it, it seems = it's a class from the iPhone operating system. Looking at the documentation, it seems quite simple though ... just a = simple wrapper to run an invocation as an NSOperation ... s/he could get = a similar effect easily by writing a subclass of NSOperation.