Re: XCode: generate KVC compliant method bodies from header
Re: XCode: generate KVC compliant method bodies from header
- Subject: Re: XCode: generate KVC compliant method bodies from header
- From: Bruce Truax <email@hidden>
- Date: Sat, 22 Jan 2005 22:48:44 -0500
I think what you want already exists. If you look in the script menu there
is a Code submenu with two very useful scripts: "Place Accessor Decls on
Clipboard" and "Place Accessor Defs on Clipboard". These two scripts will
generate KVO compliant declarations for the header file and method
declarations for the code file. There is also a nice little utility called
"Accessorizer" which does this and much more. Note that neither gets the
definitions perfect, they do not handle mutable objects properly (they use
copy rather than mutableCopy), but other than that they are great time
savers.
Bruce
On 1/22/05 7:48 PM, "Matthew" <email@hidden> eloquently
wrote:
> I recently ran across an interesting dialogue
>
> http://www.cocoadev.com/index.pl?XcodeTooMuchLikeATextEditor
>
> that asked why XCode doesn't have a built in script or function of some
> sort that generates body files from the header file. The question
> didn't seem to be answered and Google doesn't return much about this,
> at least with my search terms. I've seen a lot of other IDEs that do
> this sort of thing and was a little surprised that I didn't run across
> anything.
>
> It seems pretty reasonable to have some AppleScripts generate a body
> that's KVC compliant from a header that contains the instance variables
> and the non-KVC method declarations. Before I run off to do this, does
> anyone know of a location that already provides this? Yea, I know it
> could get fancy by synchronizing newly added methods, etc, but it would
> be nice to just have a simple little script save a few minutes at the
> start of each project by skipping the mundane details of copying and
> pasting all of the methods, doing KVC, etc.
>
> Assuming it's not already out there and I've just overlooked it, I can
> provide a link back to the list when I'm done if anyone would be
> interested.
>
> Matthew
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Cocoa-dev mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden