docs: function(error, messages){
    var that = this;
    this.error = error;
    this.messages = messages;  // an array of message objects
    this.length = 2;
    _.each(this.messages, function(msg){
      that.length = msg.payload.length + MESSAGE_HEADER_LENGTH;
    });
    this.bytesLengthVal = null;
  }