title: How to get x, y, width, height of UIView which is using auto layout
body: <p>I am trying to set mask on my <code>blue UIView</code> for which I have to set <code>frame</code> for mask but problem is <code>blue UIView</code> is using <code>auto layout</code>. </p>
  
  <p>How can I get <code>x, y, width, height</code> of <code>UIView</code> which is using <code>auto layout</code> to use like this <code>[self.v.layer.mask setFrame:CGRectMake(?, ?, ?, ?)];</code>. </p>
  
  <p>Is using <code>frame</code> property like <code>self.v.frame.size.width;</code> is correct while using <code>auto layout</code>? or is there any other approach of getting an <code>UIView x, y, width, height</code> which is using <code>auto layout</code>.</p>
  
  <p>Please see the screen shot below.</p>
  
  <p><a href="https://i.stack.imgur.com/apIgi.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/apIgi.png" alt="enter image description here"></a></p>