# generated by datamodel-codegen:
#   filename:  root_model_with_additional_properties.json
#   timestamp: 2019-07-26T00:00:00+00:00

from __future__ import annotations

from collections.abc import Mapping
from enum import Enum

from pydantic import BaseModel, Field


class NestedObjectResult(BaseModel):
    status: int


class NestedEnumResult(Enum):
    red = 'red'
    green = 'green'


class OneOfResult(BaseModel):
    description: str | None = None


class AnyOfResult(BaseModel):
    description: str | None = None


class User(BaseModel):
    name: str | None = None


class AllOfResult(User):
    description: str | None = None


class Model(BaseModel):
    test_id: str = Field(..., description='test ID')
    test_ip: str = Field(..., description='test IP')
    result: Mapping[str, int]
    nested_object_result: Mapping[str, NestedObjectResult]
    nested_enum_result: Mapping[str, NestedEnumResult]
    all_of_result: Mapping[str, AllOfResult] | None = None
    one_of_result: Mapping[str, User | OneOfResult] | None = None
    any_of_result: Mapping[str, User | AnyOfResult] | None = None
    all_of_with_unknown_object: Mapping[str, User] | None = None
    objectRef: Mapping[str, User] | None = None
    deepNestedObjectRef: Mapping[str, Mapping[str, Mapping[str, User]]] | None = None
