<?php

// This file is auto-generated, don't edit it. Thanks.

namespace AlibabaCloud\SDK\Dingtalk\Vjzcrm_1_0\Models;

use AlibabaCloud\SDK\Dingtalk\Vjzcrm_1_0\Models\EditOrderRequest\data;
use AlibabaCloud\Tea\Model;

class EditOrderRequest extends Model
{
    /**
     * @var data
     */
    public $data;

    /**
     * @description This parameter is required.
     *
     * @example 150
     *
     * @var int
     */
    public $datatype;

    /**
     * @example 1
     *
     * @var int
     */
    public $msgid;

    /**
     * @description This parameter is required.
     *
     * @example 1621822122
     *
     * @var int
     */
    public $stamp;
    protected $_name = [
        'data' => 'data',
        'datatype' => 'datatype',
        'msgid' => 'msgid',
        'stamp' => 'stamp',
    ];

    public function validate() {}

    public function toMap()
    {
        $res = [];
        if (null !== $this->data) {
            $res['data'] = null !== $this->data ? $this->data->toMap() : null;
        }
        if (null !== $this->datatype) {
            $res['datatype'] = $this->datatype;
        }
        if (null !== $this->msgid) {
            $res['msgid'] = $this->msgid;
        }
        if (null !== $this->stamp) {
            $res['stamp'] = $this->stamp;
        }

        return $res;
    }

    /**
     * @param array $map
     *
     * @return EditOrderRequest
     */
    public static function fromMap($map = [])
    {
        $model = new self();
        if (isset($map['data'])) {
            $model->data = data::fromMap($map['data']);
        }
        if (isset($map['datatype'])) {
            $model->datatype = $map['datatype'];
        }
        if (isset($map['msgid'])) {
            $model->msgid = $map['msgid'];
        }
        if (isset($map['stamp'])) {
            $model->stamp = $map['stamp'];
        }

        return $model;
    }
}
