objective c - How to define a method to show up when subclassing a custom class -


i'm not sure title makes sense, i'm having problems asking (and google searching) solution below question in single coherent sentence.

i've created custom class sole intention of subclassing it. have single method i'll need override when writing new subclass. i'm looking is, when create new file, , choose custom class subclass i'd new implementation file have empty version of method. similar how init method, or drawrect method (when appropriate) in implementation file when creating new class.

does make sense?

you can define template in editor that. there no mechanism in objective-c language can that.

however, create protocol required method , implement (instead of subclassing existing class), if fits need. gives compile error if forget implement method.


Comments

Popular posts from this blog

java - JavaFX 2 slider labelFormatter not being used -

Detect support for Shoutcast ICY MP3 without navigator.userAgent in Firefox? -

web - SVG not rendering properly in Firefox -