from datetime import date, datetime  # noqa: F401
from typing import Dict, List  # noqa: F401

from timestep.api.openai.v1 import util
from timestep.api.openai.v1.models.base_model import Model


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

    Do not edit the class manually.
    """

    def __init__(self, word=None, start=None, end=None):  # noqa: E501
        """TranscriptionWord - a model defined in OpenAPI

        :param word: The word of this TranscriptionWord.  # noqa: E501
        :type word: str
        :param start: The start of this TranscriptionWord.  # noqa: E501
        :type start: float
        :param end: The end of this TranscriptionWord.  # noqa: E501
        :type end: float
        """
        self.openapi_types = {
            'word': str,
            'start': float,
            'end': float
        }

        self.attribute_map = {
            'word': 'word',
            'start': 'start',
            'end': 'end'
        }

        self._word = word
        self._start = start
        self._end = end

    @classmethod
    def from_dict(cls, dikt) -> 'TranscriptionWord':
        """Returns the dict as a model

        :param dikt: A dict.
        :type: dict
        :return: The TranscriptionWord of this TranscriptionWord.  # noqa: E501
        :rtype: TranscriptionWord
        """
        return util.deserialize_model(dikt, cls)

    @property
    def word(self) -> str:
        """Gets the word of this TranscriptionWord.

        The text content of the word.  # noqa: E501

        :return: The word of this TranscriptionWord.
        :rtype: str
        """
        return self._word

    @word.setter
    def word(self, word: str):
        """Sets the word of this TranscriptionWord.

        The text content of the word.  # noqa: E501

        :param word: The word of this TranscriptionWord.
        :type word: str
        """
        if word is None:
            raise ValueError("Invalid value for `word`, must not be `None`")  # noqa: E501

        self._word = word

    @property
    def start(self) -> float:
        """Gets the start of this TranscriptionWord.

        Start time of the word in seconds.  # noqa: E501

        :return: The start of this TranscriptionWord.
        :rtype: float
        """
        return self._start

    @start.setter
    def start(self, start: float):
        """Sets the start of this TranscriptionWord.

        Start time of the word in seconds.  # noqa: E501

        :param start: The start of this TranscriptionWord.
        :type start: float
        """
        if start is None:
            raise ValueError("Invalid value for `start`, must not be `None`")  # noqa: E501

        self._start = start

    @property
    def end(self) -> float:
        """Gets the end of this TranscriptionWord.

        End time of the word in seconds.  # noqa: E501

        :return: The end of this TranscriptionWord.
        :rtype: float
        """
        return self._end

    @end.setter
    def end(self, end: float):
        """Sets the end of this TranscriptionWord.

        End time of the word in seconds.  # noqa: E501

        :param end: The end of this TranscriptionWord.
        :type end: float
        """
        if end is None:
            raise ValueError("Invalid value for `end`, must not be `None`")  # noqa: E501

        self._end = end
