# coding: utf-8

"""
    Collibra Data Governance Center Core API

    <p>The Core REST API allows you to create your own integrations with Collibra Data Governance Center.</p><p><i>Create custom applications to help users get access to the right data.</i></p>  # noqa: E501

    The version of the OpenAPI document: 2.0
    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 collibra_core import schemas  # noqa: F401


class AddComplexRelationTypeRequest(
    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 = {
            "attributeTypes",
            "legTypes",
            "name",
            "symbolType",
        }
        
        class properties:
            
            
            class name(
                schemas.StrSchema
            ):
            
            
                class MetaOapg:
                    max_length = 255
                    min_length = 1
            
            
            class symbolType(
                schemas.EnumBase,
                schemas.StrSchema
            ):
            
            
                class MetaOapg:
                    enum_value_to_name = {
                        "NONE": "NONE",
                        "ICON_CODE": "ICON_CODE",
                        "ACRONYM_CODE": "ACRONYM_CODE",
                    }
                
                @schemas.classproperty
                def NONE(cls):
                    return cls("NONE")
                
                @schemas.classproperty
                def ICON_CODE(cls):
                    return cls("ICON_CODE")
                
                @schemas.classproperty
                def ACRONYM_CODE(cls):
                    return cls("ACRONYM_CODE")
            
            
            class attributeTypes(
                schemas.ListSchema
            ):
            
            
                class MetaOapg:
                    
                    @staticmethod
                    def items() -> typing.Type['ComplexRelationAttributeTypeRequest']:
                        return ComplexRelationAttributeTypeRequest
            
                def __new__(
                    cls,
                    arg: typing.Union[typing.Tuple['ComplexRelationAttributeTypeRequest'], typing.List['ComplexRelationAttributeTypeRequest']],
                    _configuration: typing.Optional[schemas.Configuration] = None,
                ) -> 'attributeTypes':
                    return super().__new__(
                        cls,
                        arg,
                        _configuration=_configuration,
                    )
            
                def __getitem__(self, i: int) -> 'ComplexRelationAttributeTypeRequest':
                    return super().__getitem__(i)
            
            
            class legTypes(
                schemas.ListSchema
            ):
            
            
                class MetaOapg:
                    max_items = 2147483647
                    min_items = 1
                    
                    @staticmethod
                    def items() -> typing.Type['ComplexRelationLegTypeRequest']:
                        return ComplexRelationLegTypeRequest
            
                def __new__(
                    cls,
                    arg: typing.Union[typing.Tuple['ComplexRelationLegTypeRequest'], typing.List['ComplexRelationLegTypeRequest']],
                    _configuration: typing.Optional[schemas.Configuration] = None,
                ) -> 'legTypes':
                    return super().__new__(
                        cls,
                        arg,
                        _configuration=_configuration,
                    )
            
                def __getitem__(self, i: int) -> 'ComplexRelationLegTypeRequest':
                    return super().__getitem__(i)
            id = schemas.UUIDSchema
            
            
            class description(
                schemas.StrSchema
            ):
            
            
                class MetaOapg:
                    max_length = 4000
                    min_length = 0
            
            
            class color(
                schemas.StrSchema
            ):
            
            
                class MetaOapg:
                    max_length = 7
                    min_length = 0
                    regex=[{
                        'pattern': r'^#([A-Fa-f0-9]{6})$',  # noqa: E501
                    }]
            iconCode = schemas.StrSchema
            
            
            class acronymCode(
                schemas.StrSchema
            ):
            
            
                class MetaOapg:
                    regex=[{
                        'pattern': r'^([A-Za-z0-9]{1,4})$',  # noqa: E501
                    }]
            __annotations__ = {
                "name": name,
                "symbolType": symbolType,
                "attributeTypes": attributeTypes,
                "legTypes": legTypes,
                "id": id,
                "description": description,
                "color": color,
                "iconCode": iconCode,
                "acronymCode": acronymCode,
            }
    
    attributeTypes: MetaOapg.properties.attributeTypes
    legTypes: MetaOapg.properties.legTypes
    name: MetaOapg.properties.name
    symbolType: MetaOapg.properties.symbolType
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["symbolType"]) -> MetaOapg.properties.symbolType: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["attributeTypes"]) -> MetaOapg.properties.attributeTypes: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["legTypes"]) -> MetaOapg.properties.legTypes: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["id"]) -> MetaOapg.properties.id: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["description"]) -> MetaOapg.properties.description: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["color"]) -> MetaOapg.properties.color: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["iconCode"]) -> MetaOapg.properties.iconCode: ...
    
    @typing.overload
    def __getitem__(self, name: typing_extensions.Literal["acronymCode"]) -> MetaOapg.properties.acronymCode: ...
    
    @typing.overload
    def __getitem__(self, name: str) -> schemas.UnsetAnyTypeSchema: ...
    
    def __getitem__(self, name: typing.Union[typing_extensions.Literal["name", "symbolType", "attributeTypes", "legTypes", "id", "description", "color", "iconCode", "acronymCode", ], str]):
        # dict_instance[name] accessor
        return super().__getitem__(name)
    
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["name"]) -> MetaOapg.properties.name: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["symbolType"]) -> MetaOapg.properties.symbolType: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["attributeTypes"]) -> MetaOapg.properties.attributeTypes: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["legTypes"]) -> MetaOapg.properties.legTypes: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["id"]) -> typing.Union[MetaOapg.properties.id, schemas.Unset]: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["description"]) -> typing.Union[MetaOapg.properties.description, schemas.Unset]: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["color"]) -> typing.Union[MetaOapg.properties.color, schemas.Unset]: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["iconCode"]) -> typing.Union[MetaOapg.properties.iconCode, schemas.Unset]: ...
    
    @typing.overload
    def get_item_oapg(self, name: typing_extensions.Literal["acronymCode"]) -> typing.Union[MetaOapg.properties.acronymCode, schemas.Unset]: ...
    
    @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["name", "symbolType", "attributeTypes", "legTypes", "id", "description", "color", "iconCode", "acronymCode", ], str]):
        return super().get_item_oapg(name)
    

    def __new__(
        cls,
        *args: typing.Union[dict, frozendict.frozendict, ],
        attributeTypes: typing.Union[MetaOapg.properties.attributeTypes, list, tuple, ],
        legTypes: typing.Union[MetaOapg.properties.legTypes, list, tuple, ],
        name: typing.Union[MetaOapg.properties.name, str, ],
        symbolType: typing.Union[MetaOapg.properties.symbolType, str, ],
        id: typing.Union[MetaOapg.properties.id, str, uuid.UUID, schemas.Unset] = schemas.unset,
        description: typing.Union[MetaOapg.properties.description, str, schemas.Unset] = schemas.unset,
        color: typing.Union[MetaOapg.properties.color, str, schemas.Unset] = schemas.unset,
        iconCode: typing.Union[MetaOapg.properties.iconCode, str, schemas.Unset] = schemas.unset,
        acronymCode: typing.Union[MetaOapg.properties.acronymCode, str, schemas.Unset] = schemas.unset,
        _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],
    ) -> 'AddComplexRelationTypeRequest':
        return super().__new__(
            cls,
            *args,
            attributeTypes=attributeTypes,
            legTypes=legTypes,
            name=name,
            symbolType=symbolType,
            id=id,
            description=description,
            color=color,
            iconCode=iconCode,
            acronymCode=acronymCode,
            _configuration=_configuration,
            **kwargs,
        )

from collibra_core.model.complex_relation_attribute_type_request import ComplexRelationAttributeTypeRequest
from collibra_core.model.complex_relation_leg_type_request import ComplexRelationLegTypeRequest
