Source: proto/spine/system/server/command_log_pb.js

// source: spine/system/server/command_log.proto
/**
 * @fileoverview
 * @enhanceable
 * @suppress {messageConventions} JS Compiler reports an error if a variable or
 *     field starts with 'MSG_' and isn't a translatable message.
 * @public
 */
// GENERATED CODE -- DO NOT EDIT!

var jspb = require('google-protobuf');
var goog = jspb;
var global = Function('return this')();

var spine_options_pb = require('../../../spine/options_pb.js');
goog.object.extend(proto, spine_options_pb);
var google_protobuf_timestamp_pb = require('../../../google/protobuf/timestamp_pb.js');
goog.object.extend(proto, google_protobuf_timestamp_pb);
var spine_core_command_pb = require('../../../spine/core/command_pb.js');
goog.object.extend(proto, spine_core_command_pb);
var spine_core_response_pb = require('../../../spine/core/response_pb.js');
goog.object.extend(proto, spine_core_response_pb);
var spine_client_entities_pb = require('../../../spine/client/entities_pb.js');
goog.object.extend(proto, spine_client_entities_pb);
goog.exportSymbol('proto.spine.system.server.CommandLog', null, global);
goog.exportSymbol('proto.spine.system.server.CommandTarget', null, global);
goog.exportSymbol('proto.spine.system.server.CommandTimeline', null, global);
goog.exportSymbol('proto.spine.system.server.CommandTimeline.OutcomeCase', null, global);
goog.exportSymbol('proto.spine.system.server.Substituted', null, global);
goog.exportSymbol('proto.spine.system.server.Substituted.KindCase', null, global);
goog.exportSymbol('proto.spine.system.server.Substituted.Sequence', null, global);
/**
 * Generated by JsPbCodeGenerator.
 * @param {Array=} opt_data Optional initial data array, typically from a
 * server response, or constructed directly in Javascript. The array is used
 * in place and becomes part of the constructed object. It is not cloned.
 * If no data is provided, the constructed object will be empty, but still
 * valid.
 * @extends {jspb.Message}
 * @constructor
 */
proto.spine.system.server.CommandLog = function(opt_data) {
  jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.spine.system.server.CommandLog, jspb.Message);
if (goog.DEBUG && !COMPILED) {
  /**
   * @public
   * @override
   */
  proto.spine.system.server.CommandLog.displayName = 'proto.spine.system.server.CommandLog';
}
/**
 * Generated by JsPbCodeGenerator.
 * @param {Array=} opt_data Optional initial data array, typically from a
 * server response, or constructed directly in Javascript. The array is used
 * in place and becomes part of the constructed object. It is not cloned.
 * If no data is provided, the constructed object will be empty, but still
 * valid.
 * @extends {jspb.Message}
 * @constructor
 */
proto.spine.system.server.CommandTarget = function(opt_data) {
  jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.spine.system.server.CommandTarget, jspb.Message);
if (goog.DEBUG && !COMPILED) {
  /**
   * @public
   * @override
   */
  proto.spine.system.server.CommandTarget.displayName = 'proto.spine.system.server.CommandTarget';
}
/**
 * Generated by JsPbCodeGenerator.
 * @param {Array=} opt_data Optional initial data array, typically from a
 * server response, or constructed directly in Javascript. The array is used
 * in place and becomes part of the constructed object. It is not cloned.
 * If no data is provided, the constructed object will be empty, but still
 * valid.
 * @extends {jspb.Message}
 * @constructor
 */
proto.spine.system.server.CommandTimeline = function(opt_data) {
  jspb.Message.initialize(this, opt_data, 0, -1, null, proto.spine.system.server.CommandTimeline.oneofGroups_);
};
goog.inherits(proto.spine.system.server.CommandTimeline, jspb.Message);
if (goog.DEBUG && !COMPILED) {
  /**
   * @public
   * @override
   */
  proto.spine.system.server.CommandTimeline.displayName = 'proto.spine.system.server.CommandTimeline';
}
/**
 * Generated by JsPbCodeGenerator.
 * @param {Array=} opt_data Optional initial data array, typically from a
 * server response, or constructed directly in Javascript. The array is used
 * in place and becomes part of the constructed object. It is not cloned.
 * If no data is provided, the constructed object will be empty, but still
 * valid.
 * @extends {jspb.Message}
 * @constructor
 */
proto.spine.system.server.Substituted = function(opt_data) {
  jspb.Message.initialize(this, opt_data, 0, -1, null, proto.spine.system.server.Substituted.oneofGroups_);
};
goog.inherits(proto.spine.system.server.Substituted, jspb.Message);
if (goog.DEBUG && !COMPILED) {
  /**
   * @public
   * @override
   */
  proto.spine.system.server.Substituted.displayName = 'proto.spine.system.server.Substituted';
}
/**
 * Generated by JsPbCodeGenerator.
 * @param {Array=} opt_data Optional initial data array, typically from a
 * server response, or constructed directly in Javascript. The array is used
 * in place and becomes part of the constructed object. It is not cloned.
 * If no data is provided, the constructed object will be empty, but still
 * valid.
 * @extends {jspb.Message}
 * @constructor
 */
proto.spine.system.server.Substituted.Sequence = function(opt_data) {
  jspb.Message.initialize(this, opt_data, 0, -1, proto.spine.system.server.Substituted.Sequence.repeatedFields_, null);
};
goog.inherits(proto.spine.system.server.Substituted.Sequence, jspb.Message);
if (goog.DEBUG && !COMPILED) {
  /**
   * @public
   * @override
   */
  proto.spine.system.server.Substituted.Sequence.displayName = 'proto.spine.system.server.Substituted.Sequence';
}



if (jspb.Message.GENERATE_TO_OBJECT) {
/**
 * Creates an object representation of this proto.
 * Field names that are reserved in JavaScript and will be renamed to pb_name.
 * Optional fields that are not set will be set to undefined.
 * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
 * For the list of reserved names please see:
 *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
 * @param {boolean=} opt_includeInstance Deprecated. whether to include the
 *     JSPB instance for transitional soy proto support:
 *     http://goto/soy-param-migration
 * @return {!Object}
 */
proto.spine.system.server.CommandLog.prototype.toObject = function(opt_includeInstance) {
  return proto.spine.system.server.CommandLog.toObject(opt_includeInstance, this);
};


/**
 * Static version of the {@see toObject} method.
 * @param {boolean|undefined} includeInstance Deprecated. Whether to include
 *     the JSPB instance for transitional soy proto support:
 *     http://goto/soy-param-migration
 * @param {!proto.spine.system.server.CommandLog} msg The msg instance to transform.
 * @return {!Object}
 * @suppress {unusedLocalVariables} f is only used for nested messages
 */
proto.spine.system.server.CommandLog.toObject = function(includeInstance, msg) {
  var f, obj = {
    id: (f = msg.getId()) && spine_core_command_pb.CommandId.toObject(includeInstance, f),
    command: (f = msg.getCommand()) && spine_core_command_pb.Command.toObject(includeInstance, f),
    target: (f = msg.getTarget()) && proto.spine.system.server.CommandTarget.toObject(includeInstance, f),
    timeline: (f = msg.getTimeline()) && proto.spine.system.server.CommandTimeline.toObject(includeInstance, f)
  };

  if (includeInstance) {
    obj.$jspbMessageInstance = msg;
  }
  return obj;
};
}


/**
 * Deserializes binary data (in protobuf wire format).
 * @param {jspb.ByteSource} bytes The bytes to deserialize.
 * @return {!proto.spine.system.server.CommandLog}
 */
proto.spine.system.server.CommandLog.deserializeBinary = function(bytes) {
  var reader = new jspb.BinaryReader(bytes);
  var msg = new proto.spine.system.server.CommandLog;
  return proto.spine.system.server.CommandLog.deserializeBinaryFromReader(msg, reader);
};


/**
 * Deserializes binary data (in protobuf wire format) from the
 * given reader into the given message object.
 * @param {!proto.spine.system.server.CommandLog} msg The message object to deserialize into.
 * @param {!jspb.BinaryReader} reader The BinaryReader to use.
 * @return {!proto.spine.system.server.CommandLog}
 */
proto.spine.system.server.CommandLog.deserializeBinaryFromReader = function(msg, reader) {
  while (reader.nextField()) {
    if (reader.isEndGroup()) {
      break;
    }
    var field = reader.getFieldNumber();
    switch (field) {
    case 1:
      var value = new spine_core_command_pb.CommandId;
      reader.readMessage(value,spine_core_command_pb.CommandId.deserializeBinaryFromReader);
      msg.setId(value);
      break;
    case 2:
      var value = new spine_core_command_pb.Command;
      reader.readMessage(value,spine_core_command_pb.Command.deserializeBinaryFromReader);
      msg.setCommand(value);
      break;
    case 3:
      var value = new proto.spine.system.server.CommandTarget;
      reader.readMessage(value,proto.spine.system.server.CommandTarget.deserializeBinaryFromReader);
      msg.setTarget(value);
      break;
    case 4:
      var value = new proto.spine.system.server.CommandTimeline;
      reader.readMessage(value,proto.spine.system.server.CommandTimeline.deserializeBinaryFromReader);
      msg.setTimeline(value);
      break;
    default:
      reader.skipField();
      break;
    }
  }
  return msg;
};


/**
 * Serializes the message to binary data (in protobuf wire format).
 * @return {!Uint8Array}
 */
proto.spine.system.server.CommandLog.prototype.serializeBinary = function() {
  var writer = new jspb.BinaryWriter();
  proto.spine.system.server.CommandLog.serializeBinaryToWriter(this, writer);
  return writer.getResultBuffer();
};


/**
 * Serializes the given message to binary data (in protobuf wire
 * format), writing to the given BinaryWriter.
 * @param {!proto.spine.system.server.CommandLog} message
 * @param {!jspb.BinaryWriter} writer
 * @suppress {unusedLocalVariables} f is only used for nested messages
 */
proto.spine.system.server.CommandLog.serializeBinaryToWriter = function(message, writer) {
  var f = undefined;
  f = message.getId();
  if (f != null) {
    writer.writeMessage(
      1,
      f,
      spine_core_command_pb.CommandId.serializeBinaryToWriter
    );
  }
  f = message.getCommand();
  if (f != null) {
    writer.writeMessage(
      2,
      f,
      spine_core_command_pb.Command.serializeBinaryToWriter
    );
  }
  f = message.getTarget();
  if (f != null) {
    writer.writeMessage(
      3,
      f,
      proto.spine.system.server.CommandTarget.serializeBinaryToWriter
    );
  }
  f = message.getTimeline();
  if (f != null) {
    writer.writeMessage(
      4,
      f,
      proto.spine.system.server.CommandTimeline.serializeBinaryToWriter
    );
  }
};


/**
 * optional spine.core.CommandId id = 1;
 * @return {?proto.spine.core.CommandId}
 */
proto.spine.system.server.CommandLog.prototype.getId = function() {
  return /** @type{?proto.spine.core.CommandId} */ (
    jspb.Message.getWrapperField(this, spine_core_command_pb.CommandId, 1));
};


/**
 * @param {?proto.spine.core.CommandId|undefined} value
 * @return {!proto.spine.system.server.CommandLog} returns this
*/
proto.spine.system.server.CommandLog.prototype.setId = function(value) {
  return jspb.Message.setWrapperField(this, 1, value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandLog} returns this
 */
proto.spine.system.server.CommandLog.prototype.clearId = function() {
  return this.setId(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandLog.prototype.hasId = function() {
  return jspb.Message.getField(this, 1) != null;
};


/**
 * optional spine.core.Command command = 2;
 * @return {?proto.spine.core.Command}
 */
proto.spine.system.server.CommandLog.prototype.getCommand = function() {
  return /** @type{?proto.spine.core.Command} */ (
    jspb.Message.getWrapperField(this, spine_core_command_pb.Command, 2));
};


/**
 * @param {?proto.spine.core.Command|undefined} value
 * @return {!proto.spine.system.server.CommandLog} returns this
*/
proto.spine.system.server.CommandLog.prototype.setCommand = function(value) {
  return jspb.Message.setWrapperField(this, 2, value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandLog} returns this
 */
proto.spine.system.server.CommandLog.prototype.clearCommand = function() {
  return this.setCommand(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandLog.prototype.hasCommand = function() {
  return jspb.Message.getField(this, 2) != null;
};


/**
 * optional CommandTarget target = 3;
 * @return {?proto.spine.system.server.CommandTarget}
 */
proto.spine.system.server.CommandLog.prototype.getTarget = function() {
  return /** @type{?proto.spine.system.server.CommandTarget} */ (
    jspb.Message.getWrapperField(this, proto.spine.system.server.CommandTarget, 3));
};


/**
 * @param {?proto.spine.system.server.CommandTarget|undefined} value
 * @return {!proto.spine.system.server.CommandLog} returns this
*/
proto.spine.system.server.CommandLog.prototype.setTarget = function(value) {
  return jspb.Message.setWrapperField(this, 3, value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandLog} returns this
 */
proto.spine.system.server.CommandLog.prototype.clearTarget = function() {
  return this.setTarget(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandLog.prototype.hasTarget = function() {
  return jspb.Message.getField(this, 3) != null;
};


/**
 * optional CommandTimeline timeline = 4;
 * @return {?proto.spine.system.server.CommandTimeline}
 */
proto.spine.system.server.CommandLog.prototype.getTimeline = function() {
  return /** @type{?proto.spine.system.server.CommandTimeline} */ (
    jspb.Message.getWrapperField(this, proto.spine.system.server.CommandTimeline, 4));
};


/**
 * @param {?proto.spine.system.server.CommandTimeline|undefined} value
 * @return {!proto.spine.system.server.CommandLog} returns this
*/
proto.spine.system.server.CommandLog.prototype.setTimeline = function(value) {
  return jspb.Message.setWrapperField(this, 4, value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandLog} returns this
 */
proto.spine.system.server.CommandLog.prototype.clearTimeline = function() {
  return this.setTimeline(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandLog.prototype.hasTimeline = function() {
  return jspb.Message.getField(this, 4) != null;
};





if (jspb.Message.GENERATE_TO_OBJECT) {
/**
 * Creates an object representation of this proto.
 * Field names that are reserved in JavaScript and will be renamed to pb_name.
 * Optional fields that are not set will be set to undefined.
 * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
 * For the list of reserved names please see:
 *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
 * @param {boolean=} opt_includeInstance Deprecated. whether to include the
 *     JSPB instance for transitional soy proto support:
 *     http://goto/soy-param-migration
 * @return {!Object}
 */
proto.spine.system.server.CommandTarget.prototype.toObject = function(opt_includeInstance) {
  return proto.spine.system.server.CommandTarget.toObject(opt_includeInstance, this);
};


/**
 * Static version of the {@see toObject} method.
 * @param {boolean|undefined} includeInstance Deprecated. Whether to include
 *     the JSPB instance for transitional soy proto support:
 *     http://goto/soy-param-migration
 * @param {!proto.spine.system.server.CommandTarget} msg The msg instance to transform.
 * @return {!Object}
 * @suppress {unusedLocalVariables} f is only used for nested messages
 */
proto.spine.system.server.CommandTarget.toObject = function(includeInstance, msg) {
  var f, obj = {
    entityId: (f = msg.getEntityId()) && spine_client_entities_pb.EntityId.toObject(includeInstance, f),
    typeUrl: jspb.Message.getFieldWithDefault(msg, 2, "")
  };

  if (includeInstance) {
    obj.$jspbMessageInstance = msg;
  }
  return obj;
};
}


/**
 * Deserializes binary data (in protobuf wire format).
 * @param {jspb.ByteSource} bytes The bytes to deserialize.
 * @return {!proto.spine.system.server.CommandTarget}
 */
proto.spine.system.server.CommandTarget.deserializeBinary = function(bytes) {
  var reader = new jspb.BinaryReader(bytes);
  var msg = new proto.spine.system.server.CommandTarget;
  return proto.spine.system.server.CommandTarget.deserializeBinaryFromReader(msg, reader);
};


/**
 * Deserializes binary data (in protobuf wire format) from the
 * given reader into the given message object.
 * @param {!proto.spine.system.server.CommandTarget} msg The message object to deserialize into.
 * @param {!jspb.BinaryReader} reader The BinaryReader to use.
 * @return {!proto.spine.system.server.CommandTarget}
 */
proto.spine.system.server.CommandTarget.deserializeBinaryFromReader = function(msg, reader) {
  while (reader.nextField()) {
    if (reader.isEndGroup()) {
      break;
    }
    var field = reader.getFieldNumber();
    switch (field) {
    case 1:
      var value = new spine_client_entities_pb.EntityId;
      reader.readMessage(value,spine_client_entities_pb.EntityId.deserializeBinaryFromReader);
      msg.setEntityId(value);
      break;
    case 2:
      var value = /** @type {string} */ (reader.readString());
      msg.setTypeUrl(value);
      break;
    default:
      reader.skipField();
      break;
    }
  }
  return msg;
};


/**
 * Serializes the message to binary data (in protobuf wire format).
 * @return {!Uint8Array}
 */
proto.spine.system.server.CommandTarget.prototype.serializeBinary = function() {
  var writer = new jspb.BinaryWriter();
  proto.spine.system.server.CommandTarget.serializeBinaryToWriter(this, writer);
  return writer.getResultBuffer();
};


/**
 * Serializes the given message to binary data (in protobuf wire
 * format), writing to the given BinaryWriter.
 * @param {!proto.spine.system.server.CommandTarget} message
 * @param {!jspb.BinaryWriter} writer
 * @suppress {unusedLocalVariables} f is only used for nested messages
 */
proto.spine.system.server.CommandTarget.serializeBinaryToWriter = function(message, writer) {
  var f = undefined;
  f = message.getEntityId();
  if (f != null) {
    writer.writeMessage(
      1,
      f,
      spine_client_entities_pb.EntityId.serializeBinaryToWriter
    );
  }
  f = message.getTypeUrl();
  if (f.length > 0) {
    writer.writeString(
      2,
      f
    );
  }
};


/**
 * optional spine.client.EntityId entity_id = 1;
 * @return {?proto.spine.client.EntityId}
 */
proto.spine.system.server.CommandTarget.prototype.getEntityId = function() {
  return /** @type{?proto.spine.client.EntityId} */ (
    jspb.Message.getWrapperField(this, spine_client_entities_pb.EntityId, 1));
};


/**
 * @param {?proto.spine.client.EntityId|undefined} value
 * @return {!proto.spine.system.server.CommandTarget} returns this
*/
proto.spine.system.server.CommandTarget.prototype.setEntityId = function(value) {
  return jspb.Message.setWrapperField(this, 1, value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandTarget} returns this
 */
proto.spine.system.server.CommandTarget.prototype.clearEntityId = function() {
  return this.setEntityId(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandTarget.prototype.hasEntityId = function() {
  return jspb.Message.getField(this, 1) != null;
};


/**
 * optional string type_url = 2;
 * @return {string}
 */
proto.spine.system.server.CommandTarget.prototype.getTypeUrl = function() {
  return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};


/**
 * @param {string} value
 * @return {!proto.spine.system.server.CommandTarget} returns this
 */
proto.spine.system.server.CommandTarget.prototype.setTypeUrl = function(value) {
  return jspb.Message.setProto3StringField(this, 2, value);
};



/**
 * Oneof group definitions for this message. Each group defines the field
 * numbers belonging to that group. When of these fields' value is set, all
 * other fields in the group are cleared. During deserialization, if multiple
 * fields are encountered for a group, only the last value seen will be kept.
 * @private {!Array<!Array<number>>}
 * @const
 */
proto.spine.system.server.CommandTimeline.oneofGroups_ = [[8,9]];

/**
 * @enum {number}
 */
proto.spine.system.server.CommandTimeline.OutcomeCase = {
  OUTCOME_NOT_SET: 0,
  HOW_HANDLED: 8,
  SUBSTITUTED: 9
};

/**
 * @return {proto.spine.system.server.CommandTimeline.OutcomeCase}
 */
proto.spine.system.server.CommandTimeline.prototype.getOutcomeCase = function() {
  return /** @type {proto.spine.system.server.CommandTimeline.OutcomeCase} */(jspb.Message.computeOneofCase(this, proto.spine.system.server.CommandTimeline.oneofGroups_[0]));
};



if (jspb.Message.GENERATE_TO_OBJECT) {
/**
 * Creates an object representation of this proto.
 * Field names that are reserved in JavaScript and will be renamed to pb_name.
 * Optional fields that are not set will be set to undefined.
 * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
 * For the list of reserved names please see:
 *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
 * @param {boolean=} opt_includeInstance Deprecated. whether to include the
 *     JSPB instance for transitional soy proto support:
 *     http://goto/soy-param-migration
 * @return {!Object}
 */
proto.spine.system.server.CommandTimeline.prototype.toObject = function(opt_includeInstance) {
  return proto.spine.system.server.CommandTimeline.toObject(opt_includeInstance, this);
};


/**
 * Static version of the {@see toObject} method.
 * @param {boolean|undefined} includeInstance Deprecated. Whether to include
 *     the JSPB instance for transitional soy proto support:
 *     http://goto/soy-param-migration
 * @param {!proto.spine.system.server.CommandTimeline} msg The msg instance to transform.
 * @return {!Object}
 * @suppress {unusedLocalVariables} f is only used for nested messages
 */
proto.spine.system.server.CommandTimeline.toObject = function(includeInstance, msg) {
  var f, obj = {
    whenReceived: (f = msg.getWhenReceived()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
    whenAcknowledged: (f = msg.getWhenAcknowledged()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
    whenScheduled: (f = msg.getWhenScheduled()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
    whenDispatched: (f = msg.getWhenDispatched()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
    whenTargetAssigned: (f = msg.getWhenTargetAssigned()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
    whenHandled: (f = msg.getWhenHandled()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
    whenSubstituted: (f = msg.getWhenSubstituted()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
    howHandled: (f = msg.getHowHandled()) && spine_core_response_pb.Status.toObject(includeInstance, f),
    substituted: (f = msg.getSubstituted()) && proto.spine.system.server.Substituted.toObject(includeInstance, f)
  };

  if (includeInstance) {
    obj.$jspbMessageInstance = msg;
  }
  return obj;
};
}


/**
 * Deserializes binary data (in protobuf wire format).
 * @param {jspb.ByteSource} bytes The bytes to deserialize.
 * @return {!proto.spine.system.server.CommandTimeline}
 */
proto.spine.system.server.CommandTimeline.deserializeBinary = function(bytes) {
  var reader = new jspb.BinaryReader(bytes);
  var msg = new proto.spine.system.server.CommandTimeline;
  return proto.spine.system.server.CommandTimeline.deserializeBinaryFromReader(msg, reader);
};


/**
 * Deserializes binary data (in protobuf wire format) from the
 * given reader into the given message object.
 * @param {!proto.spine.system.server.CommandTimeline} msg The message object to deserialize into.
 * @param {!jspb.BinaryReader} reader The BinaryReader to use.
 * @return {!proto.spine.system.server.CommandTimeline}
 */
proto.spine.system.server.CommandTimeline.deserializeBinaryFromReader = function(msg, reader) {
  while (reader.nextField()) {
    if (reader.isEndGroup()) {
      break;
    }
    var field = reader.getFieldNumber();
    switch (field) {
    case 1:
      var value = new google_protobuf_timestamp_pb.Timestamp;
      reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
      msg.setWhenReceived(value);
      break;
    case 2:
      var value = new google_protobuf_timestamp_pb.Timestamp;
      reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
      msg.setWhenAcknowledged(value);
      break;
    case 3:
      var value = new google_protobuf_timestamp_pb.Timestamp;
      reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
      msg.setWhenScheduled(value);
      break;
    case 4:
      var value = new google_protobuf_timestamp_pb.Timestamp;
      reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
      msg.setWhenDispatched(value);
      break;
    case 5:
      var value = new google_protobuf_timestamp_pb.Timestamp;
      reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
      msg.setWhenTargetAssigned(value);
      break;
    case 6:
      var value = new google_protobuf_timestamp_pb.Timestamp;
      reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
      msg.setWhenHandled(value);
      break;
    case 7:
      var value = new google_protobuf_timestamp_pb.Timestamp;
      reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
      msg.setWhenSubstituted(value);
      break;
    case 8:
      var value = new spine_core_response_pb.Status;
      reader.readMessage(value,spine_core_response_pb.Status.deserializeBinaryFromReader);
      msg.setHowHandled(value);
      break;
    case 9:
      var value = new proto.spine.system.server.Substituted;
      reader.readMessage(value,proto.spine.system.server.Substituted.deserializeBinaryFromReader);
      msg.setSubstituted(value);
      break;
    default:
      reader.skipField();
      break;
    }
  }
  return msg;
};


/**
 * Serializes the message to binary data (in protobuf wire format).
 * @return {!Uint8Array}
 */
proto.spine.system.server.CommandTimeline.prototype.serializeBinary = function() {
  var writer = new jspb.BinaryWriter();
  proto.spine.system.server.CommandTimeline.serializeBinaryToWriter(this, writer);
  return writer.getResultBuffer();
};


/**
 * Serializes the given message to binary data (in protobuf wire
 * format), writing to the given BinaryWriter.
 * @param {!proto.spine.system.server.CommandTimeline} message
 * @param {!jspb.BinaryWriter} writer
 * @suppress {unusedLocalVariables} f is only used for nested messages
 */
proto.spine.system.server.CommandTimeline.serializeBinaryToWriter = function(message, writer) {
  var f = undefined;
  f = message.getWhenReceived();
  if (f != null) {
    writer.writeMessage(
      1,
      f,
      google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
    );
  }
  f = message.getWhenAcknowledged();
  if (f != null) {
    writer.writeMessage(
      2,
      f,
      google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
    );
  }
  f = message.getWhenScheduled();
  if (f != null) {
    writer.writeMessage(
      3,
      f,
      google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
    );
  }
  f = message.getWhenDispatched();
  if (f != null) {
    writer.writeMessage(
      4,
      f,
      google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
    );
  }
  f = message.getWhenTargetAssigned();
  if (f != null) {
    writer.writeMessage(
      5,
      f,
      google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
    );
  }
  f = message.getWhenHandled();
  if (f != null) {
    writer.writeMessage(
      6,
      f,
      google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
    );
  }
  f = message.getWhenSubstituted();
  if (f != null) {
    writer.writeMessage(
      7,
      f,
      google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
    );
  }
  f = message.getHowHandled();
  if (f != null) {
    writer.writeMessage(
      8,
      f,
      spine_core_response_pb.Status.serializeBinaryToWriter
    );
  }
  f = message.getSubstituted();
  if (f != null) {
    writer.writeMessage(
      9,
      f,
      proto.spine.system.server.Substituted.serializeBinaryToWriter
    );
  }
};


/**
 * optional google.protobuf.Timestamp when_received = 1;
 * @return {?proto.google.protobuf.Timestamp}
 */
proto.spine.system.server.CommandTimeline.prototype.getWhenReceived = function() {
  return /** @type{?proto.google.protobuf.Timestamp} */ (
    jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 1));
};


/**
 * @param {?proto.google.protobuf.Timestamp|undefined} value
 * @return {!proto.spine.system.server.CommandTimeline} returns this
*/
proto.spine.system.server.CommandTimeline.prototype.setWhenReceived = function(value) {
  return jspb.Message.setWrapperField(this, 1, value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandTimeline} returns this
 */
proto.spine.system.server.CommandTimeline.prototype.clearWhenReceived = function() {
  return this.setWhenReceived(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandTimeline.prototype.hasWhenReceived = function() {
  return jspb.Message.getField(this, 1) != null;
};


/**
 * optional google.protobuf.Timestamp when_acknowledged = 2;
 * @return {?proto.google.protobuf.Timestamp}
 */
proto.spine.system.server.CommandTimeline.prototype.getWhenAcknowledged = function() {
  return /** @type{?proto.google.protobuf.Timestamp} */ (
    jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 2));
};


/**
 * @param {?proto.google.protobuf.Timestamp|undefined} value
 * @return {!proto.spine.system.server.CommandTimeline} returns this
*/
proto.spine.system.server.CommandTimeline.prototype.setWhenAcknowledged = function(value) {
  return jspb.Message.setWrapperField(this, 2, value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandTimeline} returns this
 */
proto.spine.system.server.CommandTimeline.prototype.clearWhenAcknowledged = function() {
  return this.setWhenAcknowledged(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandTimeline.prototype.hasWhenAcknowledged = function() {
  return jspb.Message.getField(this, 2) != null;
};


/**
 * optional google.protobuf.Timestamp when_scheduled = 3;
 * @return {?proto.google.protobuf.Timestamp}
 */
proto.spine.system.server.CommandTimeline.prototype.getWhenScheduled = function() {
  return /** @type{?proto.google.protobuf.Timestamp} */ (
    jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 3));
};


/**
 * @param {?proto.google.protobuf.Timestamp|undefined} value
 * @return {!proto.spine.system.server.CommandTimeline} returns this
*/
proto.spine.system.server.CommandTimeline.prototype.setWhenScheduled = function(value) {
  return jspb.Message.setWrapperField(this, 3, value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandTimeline} returns this
 */
proto.spine.system.server.CommandTimeline.prototype.clearWhenScheduled = function() {
  return this.setWhenScheduled(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandTimeline.prototype.hasWhenScheduled = function() {
  return jspb.Message.getField(this, 3) != null;
};


/**
 * optional google.protobuf.Timestamp when_dispatched = 4;
 * @return {?proto.google.protobuf.Timestamp}
 */
proto.spine.system.server.CommandTimeline.prototype.getWhenDispatched = function() {
  return /** @type{?proto.google.protobuf.Timestamp} */ (
    jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 4));
};


/**
 * @param {?proto.google.protobuf.Timestamp|undefined} value
 * @return {!proto.spine.system.server.CommandTimeline} returns this
*/
proto.spine.system.server.CommandTimeline.prototype.setWhenDispatched = function(value) {
  return jspb.Message.setWrapperField(this, 4, value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandTimeline} returns this
 */
proto.spine.system.server.CommandTimeline.prototype.clearWhenDispatched = function() {
  return this.setWhenDispatched(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandTimeline.prototype.hasWhenDispatched = function() {
  return jspb.Message.getField(this, 4) != null;
};


/**
 * optional google.protobuf.Timestamp when_target_assigned = 5;
 * @return {?proto.google.protobuf.Timestamp}
 */
proto.spine.system.server.CommandTimeline.prototype.getWhenTargetAssigned = function() {
  return /** @type{?proto.google.protobuf.Timestamp} */ (
    jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 5));
};


/**
 * @param {?proto.google.protobuf.Timestamp|undefined} value
 * @return {!proto.spine.system.server.CommandTimeline} returns this
*/
proto.spine.system.server.CommandTimeline.prototype.setWhenTargetAssigned = function(value) {
  return jspb.Message.setWrapperField(this, 5, value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandTimeline} returns this
 */
proto.spine.system.server.CommandTimeline.prototype.clearWhenTargetAssigned = function() {
  return this.setWhenTargetAssigned(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandTimeline.prototype.hasWhenTargetAssigned = function() {
  return jspb.Message.getField(this, 5) != null;
};


/**
 * optional google.protobuf.Timestamp when_handled = 6;
 * @return {?proto.google.protobuf.Timestamp}
 */
proto.spine.system.server.CommandTimeline.prototype.getWhenHandled = function() {
  return /** @type{?proto.google.protobuf.Timestamp} */ (
    jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 6));
};


/**
 * @param {?proto.google.protobuf.Timestamp|undefined} value
 * @return {!proto.spine.system.server.CommandTimeline} returns this
*/
proto.spine.system.server.CommandTimeline.prototype.setWhenHandled = function(value) {
  return jspb.Message.setWrapperField(this, 6, value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandTimeline} returns this
 */
proto.spine.system.server.CommandTimeline.prototype.clearWhenHandled = function() {
  return this.setWhenHandled(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandTimeline.prototype.hasWhenHandled = function() {
  return jspb.Message.getField(this, 6) != null;
};


/**
 * optional google.protobuf.Timestamp when_substituted = 7;
 * @return {?proto.google.protobuf.Timestamp}
 */
proto.spine.system.server.CommandTimeline.prototype.getWhenSubstituted = function() {
  return /** @type{?proto.google.protobuf.Timestamp} */ (
    jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 7));
};


/**
 * @param {?proto.google.protobuf.Timestamp|undefined} value
 * @return {!proto.spine.system.server.CommandTimeline} returns this
*/
proto.spine.system.server.CommandTimeline.prototype.setWhenSubstituted = function(value) {
  return jspb.Message.setWrapperField(this, 7, value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandTimeline} returns this
 */
proto.spine.system.server.CommandTimeline.prototype.clearWhenSubstituted = function() {
  return this.setWhenSubstituted(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandTimeline.prototype.hasWhenSubstituted = function() {
  return jspb.Message.getField(this, 7) != null;
};


/**
 * optional spine.core.Status how_handled = 8;
 * @return {?proto.spine.core.Status}
 */
proto.spine.system.server.CommandTimeline.prototype.getHowHandled = function() {
  return /** @type{?proto.spine.core.Status} */ (
    jspb.Message.getWrapperField(this, spine_core_response_pb.Status, 8));
};


/**
 * @param {?proto.spine.core.Status|undefined} value
 * @return {!proto.spine.system.server.CommandTimeline} returns this
*/
proto.spine.system.server.CommandTimeline.prototype.setHowHandled = function(value) {
  return jspb.Message.setOneofWrapperField(this, 8, proto.spine.system.server.CommandTimeline.oneofGroups_[0], value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandTimeline} returns this
 */
proto.spine.system.server.CommandTimeline.prototype.clearHowHandled = function() {
  return this.setHowHandled(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandTimeline.prototype.hasHowHandled = function() {
  return jspb.Message.getField(this, 8) != null;
};


/**
 * optional Substituted substituted = 9;
 * @return {?proto.spine.system.server.Substituted}
 */
proto.spine.system.server.CommandTimeline.prototype.getSubstituted = function() {
  return /** @type{?proto.spine.system.server.Substituted} */ (
    jspb.Message.getWrapperField(this, proto.spine.system.server.Substituted, 9));
};


/**
 * @param {?proto.spine.system.server.Substituted|undefined} value
 * @return {!proto.spine.system.server.CommandTimeline} returns this
*/
proto.spine.system.server.CommandTimeline.prototype.setSubstituted = function(value) {
  return jspb.Message.setOneofWrapperField(this, 9, proto.spine.system.server.CommandTimeline.oneofGroups_[0], value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.CommandTimeline} returns this
 */
proto.spine.system.server.CommandTimeline.prototype.clearSubstituted = function() {
  return this.setSubstituted(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.CommandTimeline.prototype.hasSubstituted = function() {
  return jspb.Message.getField(this, 9) != null;
};



/**
 * Oneof group definitions for this message. Each group defines the field
 * numbers belonging to that group. When of these fields' value is set, all
 * other fields in the group are cleared. During deserialization, if multiple
 * fields are encountered for a group, only the last value seen will be kept.
 * @private {!Array<!Array<number>>}
 * @const
 */
proto.spine.system.server.Substituted.oneofGroups_ = [[1,2]];

/**
 * @enum {number}
 */
proto.spine.system.server.Substituted.KindCase = {
  KIND_NOT_SET: 0,
  COMMAND: 1,
  SEQUENCE: 2
};

/**
 * @return {proto.spine.system.server.Substituted.KindCase}
 */
proto.spine.system.server.Substituted.prototype.getKindCase = function() {
  return /** @type {proto.spine.system.server.Substituted.KindCase} */(jspb.Message.computeOneofCase(this, proto.spine.system.server.Substituted.oneofGroups_[0]));
};



if (jspb.Message.GENERATE_TO_OBJECT) {
/**
 * Creates an object representation of this proto.
 * Field names that are reserved in JavaScript and will be renamed to pb_name.
 * Optional fields that are not set will be set to undefined.
 * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
 * For the list of reserved names please see:
 *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
 * @param {boolean=} opt_includeInstance Deprecated. whether to include the
 *     JSPB instance for transitional soy proto support:
 *     http://goto/soy-param-migration
 * @return {!Object}
 */
proto.spine.system.server.Substituted.prototype.toObject = function(opt_includeInstance) {
  return proto.spine.system.server.Substituted.toObject(opt_includeInstance, this);
};


/**
 * Static version of the {@see toObject} method.
 * @param {boolean|undefined} includeInstance Deprecated. Whether to include
 *     the JSPB instance for transitional soy proto support:
 *     http://goto/soy-param-migration
 * @param {!proto.spine.system.server.Substituted} msg The msg instance to transform.
 * @return {!Object}
 * @suppress {unusedLocalVariables} f is only used for nested messages
 */
proto.spine.system.server.Substituted.toObject = function(includeInstance, msg) {
  var f, obj = {
    command: (f = msg.getCommand()) && spine_core_command_pb.CommandId.toObject(includeInstance, f),
    sequence: (f = msg.getSequence()) && proto.spine.system.server.Substituted.Sequence.toObject(includeInstance, f)
  };

  if (includeInstance) {
    obj.$jspbMessageInstance = msg;
  }
  return obj;
};
}


/**
 * Deserializes binary data (in protobuf wire format).
 * @param {jspb.ByteSource} bytes The bytes to deserialize.
 * @return {!proto.spine.system.server.Substituted}
 */
proto.spine.system.server.Substituted.deserializeBinary = function(bytes) {
  var reader = new jspb.BinaryReader(bytes);
  var msg = new proto.spine.system.server.Substituted;
  return proto.spine.system.server.Substituted.deserializeBinaryFromReader(msg, reader);
};


/**
 * Deserializes binary data (in protobuf wire format) from the
 * given reader into the given message object.
 * @param {!proto.spine.system.server.Substituted} msg The message object to deserialize into.
 * @param {!jspb.BinaryReader} reader The BinaryReader to use.
 * @return {!proto.spine.system.server.Substituted}
 */
proto.spine.system.server.Substituted.deserializeBinaryFromReader = function(msg, reader) {
  while (reader.nextField()) {
    if (reader.isEndGroup()) {
      break;
    }
    var field = reader.getFieldNumber();
    switch (field) {
    case 1:
      var value = new spine_core_command_pb.CommandId;
      reader.readMessage(value,spine_core_command_pb.CommandId.deserializeBinaryFromReader);
      msg.setCommand(value);
      break;
    case 2:
      var value = new proto.spine.system.server.Substituted.Sequence;
      reader.readMessage(value,proto.spine.system.server.Substituted.Sequence.deserializeBinaryFromReader);
      msg.setSequence(value);
      break;
    default:
      reader.skipField();
      break;
    }
  }
  return msg;
};


/**
 * Serializes the message to binary data (in protobuf wire format).
 * @return {!Uint8Array}
 */
proto.spine.system.server.Substituted.prototype.serializeBinary = function() {
  var writer = new jspb.BinaryWriter();
  proto.spine.system.server.Substituted.serializeBinaryToWriter(this, writer);
  return writer.getResultBuffer();
};


/**
 * Serializes the given message to binary data (in protobuf wire
 * format), writing to the given BinaryWriter.
 * @param {!proto.spine.system.server.Substituted} message
 * @param {!jspb.BinaryWriter} writer
 * @suppress {unusedLocalVariables} f is only used for nested messages
 */
proto.spine.system.server.Substituted.serializeBinaryToWriter = function(message, writer) {
  var f = undefined;
  f = message.getCommand();
  if (f != null) {
    writer.writeMessage(
      1,
      f,
      spine_core_command_pb.CommandId.serializeBinaryToWriter
    );
  }
  f = message.getSequence();
  if (f != null) {
    writer.writeMessage(
      2,
      f,
      proto.spine.system.server.Substituted.Sequence.serializeBinaryToWriter
    );
  }
};



/**
 * List of repeated fields within this message type.
 * @private {!Array<number>}
 * @const
 */
proto.spine.system.server.Substituted.Sequence.repeatedFields_ = [2];



if (jspb.Message.GENERATE_TO_OBJECT) {
/**
 * Creates an object representation of this proto.
 * Field names that are reserved in JavaScript and will be renamed to pb_name.
 * Optional fields that are not set will be set to undefined.
 * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
 * For the list of reserved names please see:
 *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
 * @param {boolean=} opt_includeInstance Deprecated. whether to include the
 *     JSPB instance for transitional soy proto support:
 *     http://goto/soy-param-migration
 * @return {!Object}
 */
proto.spine.system.server.Substituted.Sequence.prototype.toObject = function(opt_includeInstance) {
  return proto.spine.system.server.Substituted.Sequence.toObject(opt_includeInstance, this);
};


/**
 * Static version of the {@see toObject} method.
 * @param {boolean|undefined} includeInstance Deprecated. Whether to include
 *     the JSPB instance for transitional soy proto support:
 *     http://goto/soy-param-migration
 * @param {!proto.spine.system.server.Substituted.Sequence} msg The msg instance to transform.
 * @return {!Object}
 * @suppress {unusedLocalVariables} f is only used for nested messages
 */
proto.spine.system.server.Substituted.Sequence.toObject = function(includeInstance, msg) {
  var f, obj = {
    itemList: jspb.Message.toObjectList(msg.getItemList(),
    spine_core_command_pb.CommandId.toObject, includeInstance)
  };

  if (includeInstance) {
    obj.$jspbMessageInstance = msg;
  }
  return obj;
};
}


/**
 * Deserializes binary data (in protobuf wire format).
 * @param {jspb.ByteSource} bytes The bytes to deserialize.
 * @return {!proto.spine.system.server.Substituted.Sequence}
 */
proto.spine.system.server.Substituted.Sequence.deserializeBinary = function(bytes) {
  var reader = new jspb.BinaryReader(bytes);
  var msg = new proto.spine.system.server.Substituted.Sequence;
  return proto.spine.system.server.Substituted.Sequence.deserializeBinaryFromReader(msg, reader);
};


/**
 * Deserializes binary data (in protobuf wire format) from the
 * given reader into the given message object.
 * @param {!proto.spine.system.server.Substituted.Sequence} msg The message object to deserialize into.
 * @param {!jspb.BinaryReader} reader The BinaryReader to use.
 * @return {!proto.spine.system.server.Substituted.Sequence}
 */
proto.spine.system.server.Substituted.Sequence.deserializeBinaryFromReader = function(msg, reader) {
  while (reader.nextField()) {
    if (reader.isEndGroup()) {
      break;
    }
    var field = reader.getFieldNumber();
    switch (field) {
    case 2:
      var value = new spine_core_command_pb.CommandId;
      reader.readMessage(value,spine_core_command_pb.CommandId.deserializeBinaryFromReader);
      msg.addItem(value);
      break;
    default:
      reader.skipField();
      break;
    }
  }
  return msg;
};


/**
 * Serializes the message to binary data (in protobuf wire format).
 * @return {!Uint8Array}
 */
proto.spine.system.server.Substituted.Sequence.prototype.serializeBinary = function() {
  var writer = new jspb.BinaryWriter();
  proto.spine.system.server.Substituted.Sequence.serializeBinaryToWriter(this, writer);
  return writer.getResultBuffer();
};


/**
 * Serializes the given message to binary data (in protobuf wire
 * format), writing to the given BinaryWriter.
 * @param {!proto.spine.system.server.Substituted.Sequence} message
 * @param {!jspb.BinaryWriter} writer
 * @suppress {unusedLocalVariables} f is only used for nested messages
 */
proto.spine.system.server.Substituted.Sequence.serializeBinaryToWriter = function(message, writer) {
  var f = undefined;
  f = message.getItemList();
  if (f.length > 0) {
    writer.writeRepeatedMessage(
      2,
      f,
      spine_core_command_pb.CommandId.serializeBinaryToWriter
    );
  }
};


/**
 * repeated spine.core.CommandId item = 2;
 * @return {!Array<!proto.spine.core.CommandId>}
 */
proto.spine.system.server.Substituted.Sequence.prototype.getItemList = function() {
  return /** @type{!Array<!proto.spine.core.CommandId>} */ (
    jspb.Message.getRepeatedWrapperField(this, spine_core_command_pb.CommandId, 2));
};


/**
 * @param {!Array<!proto.spine.core.CommandId>} value
 * @return {!proto.spine.system.server.Substituted.Sequence} returns this
*/
proto.spine.system.server.Substituted.Sequence.prototype.setItemList = function(value) {
  return jspb.Message.setRepeatedWrapperField(this, 2, value);
};


/**
 * @param {!proto.spine.core.CommandId=} opt_value
 * @param {number=} opt_index
 * @return {!proto.spine.core.CommandId}
 */
proto.spine.system.server.Substituted.Sequence.prototype.addItem = function(opt_value, opt_index) {
  return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.spine.core.CommandId, opt_index);
};


/**
 * Clears the list making it empty but non-null.
 * @return {!proto.spine.system.server.Substituted.Sequence} returns this
 */
proto.spine.system.server.Substituted.Sequence.prototype.clearItemList = function() {
  return this.setItemList([]);
};


/**
 * optional spine.core.CommandId command = 1;
 * @return {?proto.spine.core.CommandId}
 */
proto.spine.system.server.Substituted.prototype.getCommand = function() {
  return /** @type{?proto.spine.core.CommandId} */ (
    jspb.Message.getWrapperField(this, spine_core_command_pb.CommandId, 1));
};


/**
 * @param {?proto.spine.core.CommandId|undefined} value
 * @return {!proto.spine.system.server.Substituted} returns this
*/
proto.spine.system.server.Substituted.prototype.setCommand = function(value) {
  return jspb.Message.setOneofWrapperField(this, 1, proto.spine.system.server.Substituted.oneofGroups_[0], value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.Substituted} returns this
 */
proto.spine.system.server.Substituted.prototype.clearCommand = function() {
  return this.setCommand(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.Substituted.prototype.hasCommand = function() {
  return jspb.Message.getField(this, 1) != null;
};


/**
 * optional Sequence sequence = 2;
 * @return {?proto.spine.system.server.Substituted.Sequence}
 */
proto.spine.system.server.Substituted.prototype.getSequence = function() {
  return /** @type{?proto.spine.system.server.Substituted.Sequence} */ (
    jspb.Message.getWrapperField(this, proto.spine.system.server.Substituted.Sequence, 2));
};


/**
 * @param {?proto.spine.system.server.Substituted.Sequence|undefined} value
 * @return {!proto.spine.system.server.Substituted} returns this
*/
proto.spine.system.server.Substituted.prototype.setSequence = function(value) {
  return jspb.Message.setOneofWrapperField(this, 2, proto.spine.system.server.Substituted.oneofGroups_[0], value);
};


/**
 * Clears the message field making it undefined.
 * @return {!proto.spine.system.server.Substituted} returns this
 */
proto.spine.system.server.Substituted.prototype.clearSequence = function() {
  return this.setSequence(undefined);
};


/**
 * Returns whether this field is set.
 * @return {boolean}
 */
proto.spine.system.server.Substituted.prototype.hasSequence = function() {
  return jspb.Message.getField(this, 2) != null;
};


goog.object.extend(exports, proto.spine.system.server);

// Generated by Spine ProtoJs Plugin

let ObjectParser = require('../../../../client/parser/object-parser.js').default;
let TypeParsers = require('../../../../client/parser/type-parsers.js').default;

proto.spine.system.server.CommandTimeline.Parser = function() {
  ObjectParser.call(this);
};
proto.spine.system.server.CommandTimeline.Parser.prototype = Object.create(ObjectParser.prototype);
proto.spine.system.server.CommandTimeline.Parser.prototype.constructor = proto.spine.system.server.CommandTimeline.Parser;
proto.spine.system.server.CommandTimeline.Parser.prototype.fromObject = function(obj) {
  if (obj === null) {
    return null;
  }
  
  let msg = new proto.spine.system.server.CommandTimeline();
  
  if (obj.whenReceived !== undefined) {
    if (obj.whenReceived === null) {
      msg.setWhenReceived(null);
    } else {
      let value = TypeParsers.parserFor('type.googleapis.com/google.protobuf.Timestamp').fromObject(obj.whenReceived);
      msg.setWhenReceived(value);
    }
  }
  
  if (obj.whenAcknowledged !== undefined) {
    if (obj.whenAcknowledged === null) {
      msg.setWhenAcknowledged(null);
    } else {
      let value = TypeParsers.parserFor('type.googleapis.com/google.protobuf.Timestamp').fromObject(obj.whenAcknowledged);
      msg.setWhenAcknowledged(value);
    }
  }
  
  if (obj.whenScheduled !== undefined) {
    if (obj.whenScheduled === null) {
      msg.setWhenScheduled(null);
    } else {
      let value = TypeParsers.parserFor('type.googleapis.com/google.protobuf.Timestamp').fromObject(obj.whenScheduled);
      msg.setWhenScheduled(value);
    }
  }
  
  if (obj.whenDispatched !== undefined) {
    if (obj.whenDispatched === null) {
      msg.setWhenDispatched(null);
    } else {
      let value = TypeParsers.parserFor('type.googleapis.com/google.protobuf.Timestamp').fromObject(obj.whenDispatched);
      msg.setWhenDispatched(value);
    }
  }
  
  if (obj.whenTargetAssigned !== undefined) {
    if (obj.whenTargetAssigned === null) {
      msg.setWhenTargetAssigned(null);
    } else {
      let value = TypeParsers.parserFor('type.googleapis.com/google.protobuf.Timestamp').fromObject(obj.whenTargetAssigned);
      msg.setWhenTargetAssigned(value);
    }
  }
  
  if (obj.whenHandled !== undefined) {
    if (obj.whenHandled === null) {
      msg.setWhenHandled(null);
    } else {
      let value = TypeParsers.parserFor('type.googleapis.com/google.protobuf.Timestamp').fromObject(obj.whenHandled);
      msg.setWhenHandled(value);
    }
  }
  
  if (obj.whenSubstituted !== undefined) {
    if (obj.whenSubstituted === null) {
      msg.setWhenSubstituted(null);
    } else {
      let value = TypeParsers.parserFor('type.googleapis.com/google.protobuf.Timestamp').fromObject(obj.whenSubstituted);
      msg.setWhenSubstituted(value);
    }
  }
  
  if (obj.howHandled !== undefined) {
    if (obj.howHandled === null) {
      msg.setHowHandled(null);
    } else {
      let value = TypeParsers.parserFor('type.spine.io/spine.core.Status').fromObject(obj.howHandled);
      msg.setHowHandled(value);
    }
  }
  
  if (obj.substituted !== undefined) {
    if (obj.substituted === null) {
      msg.setSubstituted(null);
    } else {
      let value = TypeParsers.parserFor('type.spine.io/spine.system.server.Substituted').fromObject(obj.substituted);
      msg.setSubstituted(value);
    }
  }
  return msg;
};

proto.spine.system.server.CommandTarget.Parser = function() {
  ObjectParser.call(this);
};
proto.spine.system.server.CommandTarget.Parser.prototype = Object.create(ObjectParser.prototype);
proto.spine.system.server.CommandTarget.Parser.prototype.constructor = proto.spine.system.server.CommandTarget.Parser;
proto.spine.system.server.CommandTarget.Parser.prototype.fromObject = function(obj) {
  if (obj === null) {
    return null;
  }
  
  let msg = new proto.spine.system.server.CommandTarget();
  
  if (obj.entityId !== undefined) {
    if (obj.entityId === null) {
      msg.setEntityId(null);
    } else {
      let value = TypeParsers.parserFor('type.spine.io/spine.client.EntityId').fromObject(obj.entityId);
      msg.setEntityId(value);
    }
  }
  
  if (obj.typeUrl !== undefined) {
    if (obj.typeUrl !== null) {
      let value = obj.typeUrl;
      msg.setTypeUrl(value);
    }
  }
  return msg;
};

proto.spine.system.server.Substituted.Sequence.Parser = function() {
  ObjectParser.call(this);
};
proto.spine.system.server.Substituted.Sequence.Parser.prototype = Object.create(ObjectParser.prototype);
proto.spine.system.server.Substituted.Sequence.Parser.prototype.constructor = proto.spine.system.server.Substituted.Sequence.Parser;
proto.spine.system.server.Substituted.Sequence.Parser.prototype.fromObject = function(obj) {
  if (obj === null) {
    return null;
  }
  
  let msg = new proto.spine.system.server.Substituted.Sequence();
  
  if (obj.item !== undefined && obj.item !== null) {
    obj.item.forEach(
      (listItem, index, array) => {
        if (listItem === null) {
          msg.addItem(null);
        } else {
          let value = TypeParsers.parserFor('type.spine.io/spine.core.CommandId').fromObject(listItem);
          msg.addItem(value);
        }
      }
    );
  }
  return msg;
};

proto.spine.system.server.CommandLog.Parser = function() {
  ObjectParser.call(this);
};
proto.spine.system.server.CommandLog.Parser.prototype = Object.create(ObjectParser.prototype);
proto.spine.system.server.CommandLog.Parser.prototype.constructor = proto.spine.system.server.CommandLog.Parser;
proto.spine.system.server.CommandLog.Parser.prototype.fromObject = function(obj) {
  if (obj === null) {
    return null;
  }
  
  let msg = new proto.spine.system.server.CommandLog();
  
  if (obj.id !== undefined) {
    if (obj.id === null) {
      msg.setId(null);
    } else {
      let value = TypeParsers.parserFor('type.spine.io/spine.core.CommandId').fromObject(obj.id);
      msg.setId(value);
    }
  }
  
  if (obj.command !== undefined) {
    if (obj.command === null) {
      msg.setCommand(null);
    } else {
      let value = TypeParsers.parserFor('type.spine.io/spine.core.Command').fromObject(obj.command);
      msg.setCommand(value);
    }
  }
  
  if (obj.target !== undefined) {
    if (obj.target === null) {
      msg.setTarget(null);
    } else {
      let value = TypeParsers.parserFor('type.spine.io/spine.system.server.CommandTarget').fromObject(obj.target);
      msg.setTarget(value);
    }
  }
  
  if (obj.timeline !== undefined) {
    if (obj.timeline === null) {
      msg.setTimeline(null);
    } else {
      let value = TypeParsers.parserFor('type.spine.io/spine.system.server.CommandTimeline').fromObject(obj.timeline);
      msg.setTimeline(value);
    }
  }
  return msg;
};

proto.spine.system.server.Substituted.Parser = function() {
  ObjectParser.call(this);
};
proto.spine.system.server.Substituted.Parser.prototype = Object.create(ObjectParser.prototype);
proto.spine.system.server.Substituted.Parser.prototype.constructor = proto.spine.system.server.Substituted.Parser;
proto.spine.system.server.Substituted.Parser.prototype.fromObject = function(obj) {
  if (obj === null) {
    return null;
  }
  
  let msg = new proto.spine.system.server.Substituted();
  
  if (obj.command !== undefined) {
    if (obj.command === null) {
      msg.setCommand(null);
    } else {
      let value = TypeParsers.parserFor('type.spine.io/spine.core.CommandId').fromObject(obj.command);
      msg.setCommand(value);
    }
  }
  
  if (obj.sequence !== undefined) {
    if (obj.sequence === null) {
      msg.setSequence(null);
    } else {
      let value = TypeParsers.parserFor('type.spine.io/spine.system.server.Substituted.Sequence').fromObject(obj.sequence);
      msg.setSequence(value);
    }
  }
  return msg;
};

// Generated by Spine ProtoJs Plugin
proto.spine.system.server.CommandTimeline.typeUrl = function() {
  return 'type.spine.io/spine.system.server.CommandTimeline';
};

// Generated by Spine ProtoJs Plugin
proto.spine.system.server.CommandTarget.typeUrl = function() {
  return 'type.spine.io/spine.system.server.CommandTarget';
};

// Generated by Spine ProtoJs Plugin
proto.spine.system.server.Substituted.Sequence.typeUrl = function() {
  return 'type.spine.io/spine.system.server.Substituted.Sequence';
};

// Generated by Spine ProtoJs Plugin
proto.spine.system.server.CommandLog.typeUrl = function() {
  return 'type.spine.io/spine.system.server.CommandLog';
};

// Generated by Spine ProtoJs Plugin
proto.spine.system.server.Substituted.typeUrl = function() {
  return 'type.spine.io/spine.system.server.Substituted';
};