title: Understanding swift Alamofire completionHandler
body: <p>I have these two methods in my API class to get data from an API:</p>
  
  <pre><code>func authenticateUser(completionHandler: (responseObject: String?, error: NSError?) -&gt; ()) {
          makeAuthenticateUserCall(completionHandler)
      }
  
      func makeAuthenticateUserCall(completionHandler: (responseObject: String?, error: NSError?) -&gt; ()) {
          Alamofire.request(.GET, loginUrlString)
              .authenticate(user: "a", password: "b")
              .responseString { request, response, responseString, responseError in
                  completionHandler(responseObject: responseString as String!, error: responseError)
          }
      }
  </code></pre>
  
  <p>Then in another class i use the following code to access the data:</p>
  
  <pre><code>API().authenticateUser{ (responseObject, error) in
      println(responseObject)
  }
  </code></pre>
  
  <p>The code is working but i don't understand it completely.</p>
  
  <ol>
  <li>func authenticateUser has the parameter completionHandler: (responseObject: String?, error: NSError?) -> (), is this a reference to the completionHandler method? or is it an object? whats the purpose of -> ()?</li>
  <li>When i call the authenticateUser func, how do i actually access the response? There is no return in any of my api funcs,  the funcname{(parameter, parameter) in .. } syntax seems really strange.</li>
  </ol>