code: function encodeAttachmentMessage(buffer, offset, message) {
      if (message == undefined)
          throw Error('Specify message');
      offset += encodeString(buffer, message, offset);
      return offset;
  }
docs: Helper function to encode the attachment for a message.
  @param {Buffer} buffer
  @param {Number} offset
  @param {string} message
  @returns {Number} New offset
  @throws {Error}