code: function amf0encString(str) {
      var buf = new Buffer(3);
      buf.writeUInt8(0x02, 0);
      buf.writeUInt16BE(str.length, 1);
      return Buffer.concat([buf, new Buffer(str, 'utf8')]);
  }
docs: AMF0 Encode String
  @param str
  @returns {Buffer}