Classes
Objective-C classes are subclassed in the same manner as a normal Python class:
class MyDuck(NSObject): # NSObject is a base Objective-C class. def init(self): self = super(MyDuck, self).init # An Objective-C idiom, wherein the # subclass instance, self, is instantiated # by sending the superclass its # designated initializer. return self myLittleDuckOne = MyDuck.alloc.initRead more about this topic: Py Obj C
Famous quotes containing the word classes:
“Is a man too strong and fierce for society, and by temper and position a bad citizen,a morose ruffian, with a dash of the pirate in him;Mnature sends him a troop of pretty sons and daughters, who are getting along in the dames classes at the village school, and love and fear for them smooths his grim scowl to courtesy. Thus she contrives to intenerate the granite and the feldspar, takes the boar out and puts the lamb in, and keeps her balance true.”
—Ralph Waldo Emerson (18031882)
“Classes struggle, some classes triumph, others are eliminated. Such is history; such is the history of civilization for thousands of years.”
—Mao Zedong (18931976)
“There are two classes of men called poets. The one cultivates life, the other art,... one satisfies hunger, the other gratifies the palate.”
—Henry David Thoreau (18171862)