# coding: utf-8

"""
    lakeFS API

    lakeFS HTTP API  # noqa: E501

    The version of the OpenAPI document: 0.1.0
    Contact: services@treeverse.io
    Generated by: https://openapi-generator.tech
"""

from datetime import date, datetime  # noqa: F401
import decimal  # noqa: F401
import functools  # noqa: F401
import io  # noqa: F401
import re  # noqa: F401
import typing  # noqa: F401
import typing_extensions  # noqa: F401
import uuid  # noqa: F401

import frozendict  # noqa: F401

from lakefs_client import schemas  # noqa: F401


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

    Do not edit the class manually.
    """


    class MetaOapg:
        required = {
            "operation_content",
            "operation_type",
            "id",
            "operation",
            "timestamp",
        }
        
        class properties:
            id = schemas.StrSchema
            timestamp = schemas.IntSchema
            operation = schemas.StrSchema
            operation_content = schemas.DictSchema
            
            
            class operation_type(
                schemas.EnumBase,
                schemas.StrSchema
            ):
            
            
                class MetaOapg:
                    enum_value_to_name = {
                        "create": "CREATE",
                        "update": "UPDATE",
                        "delete": "DELETE",
                    }
                
                @schemas.classproperty
                def CREATE(cls):
                    return cls("create")
                
                @schemas.classproperty
                def UPDATE(cls):
                    return cls("update")
                
                @schemas.classproperty
                def DELETE(cls):
                    return cls("delete")
            __annotations__ = {
                "id": id,
                "timestamp": timestamp,
                "operation": operation,
                "operation_content": operation_content,
                "operation_type": operation_type,
            }
    
    operation_content: MetaOapg.properties.operation_content
    operation_type: MetaOapg.properties.operation_type
    id: MetaOapg.properties.id
    operation: MetaOapg.properties.operation
    timestamp: MetaOapg.properties.timestamp
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["id"]) -> MetaOapg.properties.id: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["timestamp"]) -> MetaOapg.properties.timestamp: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["operation"]) -> MetaOapg.properties.operation: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["operation_content"]) -> MetaOapg.properties.operation_content: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["operation_type"]) -> MetaOapg.properties.operation_type: ...
    
    @typing.overload
    def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ...
    
    def __getitem__(self, name: typing.Union[typing_extensions.Literal["id", "timestamp", "operation", "operation_content", "operation_type", ], str]):
        # dict_instance[name] accessor
        return super().__getitem__(name)
    
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["id"]) -> MetaOapg.properties.id: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["timestamp"]) -> MetaOapg.properties.timestamp: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["operation"]) -> MetaOapg.properties.operation: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["operation_content"]) -> MetaOapg.properties.operation_content: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["operation_type"]) -> MetaOapg.properties.operation_type: ...
    
    @typing.overload
    def get_item_oapg(self, name: str) -> typing.Union[schemas.UnsetAnyTypeSchema, schemas.Unset]: ...
    
    def get_item_oapg(self, name: typing.Union[typing_extensions.Literal["id", "timestamp", "operation", "operation_content", "operation_type", ], str]):
        return super().get_item_oapg(name)
    

    def __new__(
        cls,
        *_args: typing.Union[dict, frozendict.frozendict, ],
        operation_content: typing.Union[MetaOapg.properties.operation_content, dict, frozendict.frozendict, ],
        operation_type: typing.Union[MetaOapg.properties.operation_type, str, ],
        id: typing.Union[MetaOapg.properties.id, str, ],
        operation: typing.Union[MetaOapg.properties.operation, str, ],
        timestamp: typing.Union[MetaOapg.properties.timestamp, decimal.Decimal, int, ],
        _configuration: typing.Optional[schemas.Configuration] = None,
        **kwargs: typing.Union[schemas.AnyTypeSchema, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, None, list, tuple, bytes],
    ) -> 'OtfDiffEntry':
        return super().__new__(
            cls,
            *_args,
            operation_content=operation_content,
            operation_type=operation_type,
            id=id,
            operation=operation,
            timestamp=timestamp,
            _configuration=_configuration,
            **kwargs,
        )
