Difference between directly setting a controller's view and adding view as a subview
<p>I have just started learning objective-C and the iphone sdk and I have a question that I hope someone can help shed some light on.</p>

<p>What is the difference in the following:</p>

<pre><code>self.view = someView;
</code></pre>

<p>and</p>

<pre><code>[self.view addSubView: someView];
</code></pre>

<p>Say for example, in a simple app, where we have only one controller and one container view (has a few image subviews).
What is the difference between the two statements? The reason that I'm asking is because I was tinkering around in some sample code and I noticed the view was being initialized with images as subviews like so:</p>

<pre><code>if (self = [super initWithFrame:CGRectZero])
{
//adds some images as subviews here
}
</code></pre>

<p>As I understand it the initWithFrame: CGRectZero, creates a frame with size at [0,0,0,0] (essentially invisible). </p>

<p>When I directly set the view with </p>

<pre><code>self.view = someView;
</code></pre>

<p>I notice the view actually displays the image. But when I add the view to as a subview of controller's 'default' view, it doesn't. So basically my question is, whats going on behind the scenes? Why is the first method "resizing" the frame and the second one not doing the same thing.</p>
