# coding: utf-8

"""
    Vidispine API

    No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)  # noqa: E501

    The version of the OpenAPI document: 5.x
    Contact: info@vidispine.com
    Generated by: https://openapi-generator.tech
"""


import pprint
import re  # noqa: F401

import six
from . import *

class PartialFileRandomIndexTypePacket(object):
    """NOTE: This class is auto generated by OpenAPI Generator.
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    """

    """
    Attributes:
      openapi_types (dict): The key is attribute name
                            and the value is attribute type.
      attribute_map (dict): The key is attribute name
                            and the value is json key in definition.
    """
    openapi_types = {
        'stream': 'int',
        'duration': 'int',
        'length': 'int',
        'offset': 'int',
        'dts': 'int',
        'pts': 'int',
        'is_key_frame': 'bool'
    }

    attribute_map = {
        'stream': 'stream',
        'duration': 'duration',
        'length': 'length',
        'offset': 'offset',
        'dts': 'dts',
        'pts': 'pts',
        'is_key_frame': 'isKeyFrame'
    }

    def __init__(self, stream=None, duration=None, length=None, offset=None, dts=None, pts=None, is_key_frame=None):  # noqa: E501
        """PartialFileRandomIndexTypePacket - a model defined in OpenAPI"""  # noqa: E501

        self._stream = None
        self._duration = None
        self._length = None
        self._offset = None
        self._dts = None
        self._pts = None
        self._is_key_frame = None
        self.discriminator = None

        if stream is not None:
            self.stream = stream
        if duration is not None:
            self.duration = duration
        if length is not None:
            self.length = length
        if offset is not None:
            self.offset = offset
        if dts is not None:
            self.dts = dts
        if pts is not None:
            self.pts = pts
        if is_key_frame is not None:
            self.is_key_frame = is_key_frame

    @property
    def stream(self):
        """Gets the stream of this PartialFileRandomIndexTypePacket.  # noqa: E501


        :return: The stream of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :rtype: int
        """
        return self._stream

    @stream.setter
    def stream(self, stream):
        """Sets the stream of this PartialFileRandomIndexTypePacket.


        :param stream: The stream of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :type: int
        """

        self._stream = stream

    @property
    def duration(self):
        """Gets the duration of this PartialFileRandomIndexTypePacket.  # noqa: E501


        :return: The duration of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :rtype: int
        """
        return self._duration

    @duration.setter
    def duration(self, duration):
        """Sets the duration of this PartialFileRandomIndexTypePacket.


        :param duration: The duration of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :type: int
        """

        self._duration = duration

    @property
    def length(self):
        """Gets the length of this PartialFileRandomIndexTypePacket.  # noqa: E501


        :return: The length of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :rtype: int
        """
        return self._length

    @length.setter
    def length(self, length):
        """Sets the length of this PartialFileRandomIndexTypePacket.


        :param length: The length of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :type: int
        """

        self._length = length

    @property
    def offset(self):
        """Gets the offset of this PartialFileRandomIndexTypePacket.  # noqa: E501


        :return: The offset of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :rtype: int
        """
        return self._offset

    @offset.setter
    def offset(self, offset):
        """Sets the offset of this PartialFileRandomIndexTypePacket.


        :param offset: The offset of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :type: int
        """

        self._offset = offset

    @property
    def dts(self):
        """Gets the dts of this PartialFileRandomIndexTypePacket.  # noqa: E501


        :return: The dts of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :rtype: int
        """
        return self._dts

    @dts.setter
    def dts(self, dts):
        """Sets the dts of this PartialFileRandomIndexTypePacket.


        :param dts: The dts of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :type: int
        """

        self._dts = dts

    @property
    def pts(self):
        """Gets the pts of this PartialFileRandomIndexTypePacket.  # noqa: E501


        :return: The pts of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :rtype: int
        """
        return self._pts

    @pts.setter
    def pts(self, pts):
        """Sets the pts of this PartialFileRandomIndexTypePacket.


        :param pts: The pts of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :type: int
        """

        self._pts = pts

    @property
    def is_key_frame(self):
        """Gets the is_key_frame of this PartialFileRandomIndexTypePacket.  # noqa: E501


        :return: The is_key_frame of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :rtype: bool
        """
        return self._is_key_frame

    @is_key_frame.setter
    def is_key_frame(self, is_key_frame):
        """Sets the is_key_frame of this PartialFileRandomIndexTypePacket.


        :param is_key_frame: The is_key_frame of this PartialFileRandomIndexTypePacket.  # noqa: E501
        :type: bool
        """

        self._is_key_frame = is_key_frame

    def to_dict(self):
        """Returns the model properties as a dict"""
        result = {}

        for attr, _ in six.iteritems(self.openapi_types):
            value = getattr(self, attr)
            if isinstance(value, list):
                result[attr] = list(map(
                    lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
                    value
                ))
            elif hasattr(value, "to_dict"):
                result[attr] = value.to_dict()
            elif isinstance(value, dict):
                result[attr] = dict(map(
                    lambda item: (item[0], item[1].to_dict())
                    if hasattr(item[1], "to_dict") else item,
                    value.items()
                ))
            else:
                result[attr] = value

        return result

    def to_str(self):
        """Returns the string representation of the model"""
        return pprint.pformat(self.to_dict())

    def __repr__(self):
        """For `print` and `pprint`"""
        return self.to_str()

    def __eq__(self, other):
        """Returns true if both objects are equal"""
        if not isinstance(other, PartialFileRandomIndexTypePacket):
            return False

        return self.__dict__ == other.__dict__

    def __ne__(self, other):
        """Returns true if both objects are not equal"""
        return not self == other
