// Auto-generated. Do not edit!

// (in-package teleop_tools_msgs.msg)


"use strict";

const _serializer = _ros_msg_utils.Serialize;
const _arraySerializer = _serializer.Array;
const _deserializer = _ros_msg_utils.Deserialize;
const _arrayDeserializer = _deserializer.Array;
const _finder = _ros_msg_utils.Find;
const _getByteLength = _ros_msg_utils.getByteLength;

//-----------------------------------------------------------

class IncrementGoal {
  constructor(initObj={}) {
    if (initObj === null) {
      // initObj === null is a special case for deserialization where we don't initialize fields
      this.increment_by = null;
    }
    else {
      if (initObj.hasOwnProperty('increment_by')) {
        this.increment_by = initObj.increment_by
      }
      else {
        this.increment_by = [];
      }
    }
  }

  static serialize(obj, buffer, bufferOffset) {
    // Serializes a message object of type IncrementGoal
    // Serialize message field [increment_by]
    bufferOffset = _arraySerializer.float32(obj.increment_by, buffer, bufferOffset, null);
    return bufferOffset;
  }

  static deserialize(buffer, bufferOffset=[0]) {
    //deserializes a message object of type IncrementGoal
    let len;
    let data = new IncrementGoal(null);
    // Deserialize message field [increment_by]
    data.increment_by = _arrayDeserializer.float32(buffer, bufferOffset, null)
    return data;
  }

  static getMessageSize(object) {
    let length = 0;
    length += 4 * object.increment_by.length;
    return length + 4;
  }

  static datatype() {
    // Returns string type for a message object
    return 'teleop_tools_msgs/IncrementGoal';
  }

  static md5sum() {
    //Returns md5sum for a message object
    return '6801194f49dae2bee5b8f17b6ce4596f';
  }

  static messageDefinition() {
    // Returns full string definition for message
    return `
    # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
    float32[] increment_by
    
    `;
  }

  static Resolve(msg) {
    // deep-construct a valid message object instance of whatever was passed in
    if (typeof msg !== 'object' || msg === null) {
      msg = {};
    }
    const resolved = new IncrementGoal(null);
    if (msg.increment_by !== undefined) {
      resolved.increment_by = msg.increment_by;
    }
    else {
      resolved.increment_by = []
    }

    return resolved;
    }
};

module.exports = IncrementGoal;
