title: Convert UInt8?, String, Int to String type using Swift
body: <p>I am using the <a href="https://github.com/swiftsocket/SwiftSocket" rel="nofollow">SwiftSocket library</a> and I am trying to convert the data the UDP socket receives from type 'UInt8?, String, Int' to type String. </p>
  
  <pre><code>    let data = client.recv(1024)
      let string = NSData.withBytes(data)
      let str = NSString(data: string, encoding: NSUTF8StringEncoding) as String?
  </code></pre>
  
  <p>When I attempt this I get the following error:</p>
  
  <blockquote>
    <p>Cannot convert value of type '((UInt8]?,String,Int)' (aka'(Optional>, String, Int)') to be expected argument type '[UInt8'</p>
  </blockquote>
  
  <p>If I print out 'data', i receive the following:</p>
  
  <pre class="lang-none prettyprint-override"><code>(Optional([104, 101, 108, 108, 111]), "127.0.0.1", 34835)
  </code></pre>
  
  <p>Where 104,101,108,108,111 is the string "hello".</p>
  
  <p>Is there way to convert the data read to string?</p>