<?php
/**
 * Order
 *
 * PHP version 8.1.1
 *
 * @category Class
 * @package  OpenAPI\Server\Model
 * @author   OpenAPI Generator team
 * @link     https://github.com/openapitools/openapi-generator
 */

/**
 * OpenAPI Petstore
 *
 * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
 *
 * The version of the OpenAPI document: 1.0.0
 * 
 * Generated by: https://github.com/openapitools/openapi-generator.git
 *
 */

/**
 * NOTE: This class is auto generated by the openapi generator program.
 * https://github.com/openapitools/openapi-generator
 * Do not edit the class manually.
 */

namespace OpenAPI\Server\Model;

use Symfony\Component\Validator\Constraints as Assert;
use JMS\Serializer\Annotation\Type;
use JMS\Serializer\Annotation\SerializedName;

/**
 * Class representing the Order model.
 *
 * An order for a pets from the pet store
 *
 * @package OpenAPI\Server\Model
 * @author  OpenAPI Generator team
 */

class Order 
{
        /**
     * @var int|null
     * @SerializedName("id")
     * @Assert\Type("int")
     * @Type("int")
     */
    protected ?int $id = null;

    /**
     * @var int|null
     * @SerializedName("petId")
     * @Assert\Type("int")
     * @Type("int")
     */
    protected ?int $petId = null;

    /**
     * @var int|null
     * @SerializedName("quantity")
     * @Assert\Type("int")
     * @Type("int")
     */
    protected ?int $quantity = null;

    /**
     * @var \DateTime|null
     * @SerializedName("shipDate")
     * @Assert\DateTime()
     * @Type("DateTime")
     */
    protected ?\DateTime $shipDate = null;

    /**
     * Order Status
     *
     * @var string|null
     * @SerializedName("status")
     * @Assert\Choice({ "placed", "approved", "delivered" })
     * @Assert\Type("string")
     * @Type("string")
     */
    protected ?string $status = null;

    /**
     * @var bool|null
     * @SerializedName("complete")
     * @Assert\Type("bool")
     * @Type("bool")
     */
    protected ?bool $complete = null;

    /**
     * Constructor
     * @param array|null $data Associated array of property values initializing the model
     */
    public function __construct(array $data = null)
    {
        $this->id = $data['id'] ?? null;
        $this->petId = $data['petId'] ?? null;
        $this->quantity = $data['quantity'] ?? null;
        $this->shipDate = $data['shipDate'] ?? null;
        $this->status = $data['status'] ?? null;
        $this->complete = $data['complete'] ?? null;
    }

    /**
     * Gets id.
     *
     * @return int|null
     */
    public function getId(): ?int
    {
        return $this->id;
    }

    /**
     * Sets id.
     *
     * @param int|null $id
     *
     * @return $this
     */
    public function setId(?int $id = null): self
    {
        $this->id = $id;

        return $this;
    }

    /**
     * Gets petId.
     *
     * @return int|null
     */
    public function getPetId(): ?int
    {
        return $this->petId;
    }

    /**
     * Sets petId.
     *
     * @param int|null $petId
     *
     * @return $this
     */
    public function setPetId(?int $petId = null): self
    {
        $this->petId = $petId;

        return $this;
    }

    /**
     * Gets quantity.
     *
     * @return int|null
     */
    public function getQuantity(): ?int
    {
        return $this->quantity;
    }

    /**
     * Sets quantity.
     *
     * @param int|null $quantity
     *
     * @return $this
     */
    public function setQuantity(?int $quantity = null): self
    {
        $this->quantity = $quantity;

        return $this;
    }

    /**
     * Gets shipDate.
     *
     * @return \DateTime|null
     */
    public function getShipDate(): ?\DateTime
    {
        return $this->shipDate;
    }

    /**
     * Sets shipDate.
     *
     * @param \DateTime|null $shipDate
     *
     * @return $this
     */
    public function setShipDate(?\DateTime $shipDate = null): self
    {
        $this->shipDate = $shipDate;

        return $this;
    }

    /**
     * Gets status.
     *
     * @return string|null
     */
    public function getStatus(): ?string
    {
        return $this->status;
    }

    /**
     * Sets status.
     *
     * @param string|null $status  Order Status
     *
     * @return $this
     */
    public function setStatus(?string $status = null): self
    {
        $this->status = $status;

        return $this;
    }

    /**
     * Gets complete.
     *
     * @return bool|null
     */
    public function isComplete(): ?bool
    {
        return $this->complete;
    }

    /**
     * Sets complete.
     *
     * @param bool|null $complete
     *
     * @return $this
     */
    public function setComplete(?bool $complete = null): self
    {
        $this->complete = $complete;

        return $this;
    }
}


