I'm writing an app where support for "promotions" is required, and these promotions could be arbitrarily complex and many different pieces of data might be relevant in their calculation. Therefore, whilst in the early stages of development, I don't want to invent a whole specification schema for these things, I'd rather just write each one in Objective-C and then somehow serialize the compiled code into the (CoreData) database for later recall and execution.
Is this in any way possible? I was thinking that GCD blocks might be a good candidate for this, although I'm not aware of any out-of-the-box method for serializing / deserializing them.
Thanks for any advice.
edit: this is an iPhone app so unfortunately I can't use something like Python function pickling ... it has to be straight Objective-C ...