Tip:
Highlight text to annotate it
X
as we've talked about the initialize they should inside of object we should
probably talk about the other end to im bank to looking in the boilerplate code
of that extra gives you for a class with no editions no changes open up my
counterparts in the assistant t_m_ i can just see the what i have is the unit
method we were talking about last time and we also have this one called the
alloc and taking a look at the code for the allocate seems to do nothing other
than just called it the alexa mathematics of the super class that is
of course all it's doing
what's this for a bomb teammate is for what happens when the object is
instantiated the allergist for what happens when the object goes away the
alec is wont get schooled on this object when he'd is released and the retain can
goes to zero you don't call the alopecia self you lead objective c do that the
reason that it's their is for cleanup let's say for example in my instance
variables i'm going to have and n_i_s_ date
which are called
start date could represent the start date and time then in my emit method
what i'm going to do is create
and an estate object and storytime
and then start to date instance variable
perfectly valid way of doing it in a way that i can make sure that i actually
have any real objects their in that variable but the problem is this where
using one of the magic word which is allot
so this object will have in that cold when it is first allocated an
initialized
the start date on jay will be created there will be used and then after a
while something will call release on it them point the alec will be called and
here's where we should enter in
start date
released
this is our matching release for the alag creation intimate all the way that
we do it in d alag
is you're taking care of your own stuff first and then you're passing the task
up the chain to your superclass it then takes care of it's going to be
allocation any resources it needs to let go off
again making analogies to other languages if you're familiar with things
like finalize as andy structures it's that kind of idea