wallaroo.wallaroo_ml_ops_api_client.models.users_query_response_200_users API documentation

# wallaroo.wallaroo_ml_ops_api_client.models.users_query_response_200_users

View Source

     1from typing import Any, Dict, List, Optional, Type, TypeVar
     2
     3import attr
     4
     5from ..models.users_query_response_200_users_additional_property import \
     6    UsersQueryResponse200UsersAdditionalProperty
     7
     8T = TypeVar("T", bound="UsersQueryResponse200Users")
     9
    10@attr.s(auto_attribs=True)
    11class UsersQueryResponse200Users:
    12    """ User details keyed by User ID.
    13
    14    """
    15
    16    additional_properties: Dict[str, Optional[UsersQueryResponse200UsersAdditionalProperty]] = attr.ib(init=False, factory=dict)
    17
    18
    19    def to_dict(self) -> Dict[str, Any]:
    20
    21        field_dict: Dict[str, Any] = {}
    22        for prop_name, prop in self.additional_properties.items():
    23            field_dict[prop_name] = prop.to_dict() if prop else None
    24
    25        field_dict.update({
    26        })
    27
    28        return field_dict
    29
    30
    31
    32    @classmethod
    33    def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
    34        d = src_dict.copy()
    35        users_query_response_200_users = cls(
    36        )
    37
    38        additional_properties = {}
    39        for prop_name, prop_dict in d.items():
    40            _additional_property = prop_dict
    41            additional_property: Optional[UsersQueryResponse200UsersAdditionalProperty]
    42            if _additional_property is None:
    43                additional_property = None
    44            else:
    45                additional_property = UsersQueryResponse200UsersAdditionalProperty.from_dict(_additional_property)
    46
    47
    48
    49            additional_properties[prop_name] = additional_property
    50
    51        users_query_response_200_users.additional_properties = additional_properties
    52        return users_query_response_200_users
    53
    54    @property
    55    def additional_keys(self) -> List[str]:
    56        return list(self.additional_properties.keys())
    57
    58    def __getitem__(self, key: str) -> Optional[UsersQueryResponse200UsersAdditionalProperty]:
    59        return self.additional_properties[key]
    60
    61    def __setitem__(self, key: str, value: Optional[UsersQueryResponse200UsersAdditionalProperty]) -> None:
    62        self.additional_properties[key] = value
    63
    64    def __delitem__(self, key: str) -> None:
    65        del self.additional_properties[key]
    66
    67    def __contains__(self, key: str) -> bool:
    68        return key in self.additional_properties

@attr.s(auto_attribs=True)
class UsersQueryResponse200Users: View Source

    11@attr.s(auto_attribs=True)
    12class UsersQueryResponse200Users:
    13    """ User details keyed by User ID.
    14
    15    """
    16
    17    additional_properties: Dict[str, Optional[UsersQueryResponse200UsersAdditionalProperty]] = attr.ib(init=False, factory=dict)
    18
    19
    20    def to_dict(self) -> Dict[str, Any]:
    21
    22        field_dict: Dict[str, Any] = {}
    23        for prop_name, prop in self.additional_properties.items():
    24            field_dict[prop_name] = prop.to_dict() if prop else None
    25
    26        field_dict.update({
    27        })
    28
    29        return field_dict
    30
    31
    32
    33    @classmethod
    34    def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
    35        d = src_dict.copy()
    36        users_query_response_200_users = cls(
    37        )
    38
    39        additional_properties = {}
    40        for prop_name, prop_dict in d.items():
    41            _additional_property = prop_dict
    42            additional_property: Optional[UsersQueryResponse200UsersAdditionalProperty]
    43            if _additional_property is None:
    44                additional_property = None
    45            else:
    46                additional_property = UsersQueryResponse200UsersAdditionalProperty.from_dict(_additional_property)
    47
    48
    49
    50            additional_properties[prop_name] = additional_property
    51
    52        users_query_response_200_users.additional_properties = additional_properties
    53        return users_query_response_200_users
    54
    55    @property
    56    def additional_keys(self) -> List[str]:
    57        return list(self.additional_properties.keys())
    58
    59    def __getitem__(self, key: str) -> Optional[UsersQueryResponse200UsersAdditionalProperty]:
    60        return self.additional_properties[key]
    61
    62    def __setitem__(self, key: str, value: Optional[UsersQueryResponse200UsersAdditionalProperty]) -> None:
    63        self.additional_properties[key] = value
    64
    65    def __delitem__(self, key: str) -> None:
    66        del self.additional_properties[key]
    67
    68    def __contains__(self, key: str) -> bool:
    69        return key in self.additional_properties

User details keyed by User ID.

UsersQueryResponse200Users() View Source

    2def __init__(self, ):
    3    self.additional_properties = __attr_factory_additional_properties()

Method generated by attrs for class UsersQueryResponse200Users.

def to_dict(self) -> Dict[str, Any]: View Source

    20    def to_dict(self) -> Dict[str, Any]:
    21
    22        field_dict: Dict[str, Any] = {}
    23        for prop_name, prop in self.additional_properties.items():
    24            field_dict[prop_name] = prop.to_dict() if prop else None
    25
    26        field_dict.update({
    27        })
    28
    29        return field_dict

@classmethod
def from_dict(cls: Type[~T], src_dict: Dict[str, Any]) -> ~T: View Source

    33    @classmethod
    34    def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
    35        d = src_dict.copy()
    36        users_query_response_200_users = cls(
    37        )
    38
    39        additional_properties = {}
    40        for prop_name, prop_dict in d.items():
    41            _additional_property = prop_dict
    42            additional_property: Optional[UsersQueryResponse200UsersAdditionalProperty]
    43            if _additional_property is None:
    44                additional_property = None
    45            else:
    46                additional_property = UsersQueryResponse200UsersAdditionalProperty.from_dict(_additional_property)
    47
    48
    49
    50            additional_properties[prop_name] = additional_property
    51
    52        users_query_response_200_users.additional_properties = additional_properties
    53        return users_query_response_200_users

additional_keys: List[str]