[F-Script-talk] Multiple Blocks
Brought to you by:
pmougin
From: Jeremy S. <js...@ga...> - 2006-09-08 02:34:01
|
I am trying to implement extensions into my app. I am wanting to define blocks in one file and then run only blocks that I call. Example: [ name:=[ sys log:('Jeremy').] description:=[ :des| sys log:('des).] ] Now I want to just execute the "name" block. -(id)runProcedure { // will set fscript to the above example. NSString *fscript = [procedure objectForKey:@"procedure"]; // Create a Block object from the string Block *myBlock = [fscript asBlock]; // Can I do something like.... // I know this is not a method on the Block class, but is there another way to get //subblocks from blocks? myBlock = [myBlock forName:@"name"]; // Execute the block [myBlock value:@"name"]; } Thanks, Jeremy |