wallaroo.wallaroo_ml_ops_api_client.models.assays_get_assay_results_json_body API documentation

# wallaroo.wallaroo_ml_ops_api_client.models.assays_get_assay_results_json_body

View Source

     1import datetime
     2from typing import Any, Dict, List, Type, TypeVar
     3
     4import attr
     5from dateutil.parser import isoparse
     6
     7T = TypeVar("T", bound="AssaysGetAssayResultsJsonBody")
     8
     9@attr.s(auto_attribs=True)
    10class AssaysGetAssayResultsJsonBody:
    11    """ Request to return assay results.
    12
    13    Attributes:
    14        assay_id (int):
    15        start (datetime.datetime):
    16        end (datetime.datetime):
    17    """
    18
    19    assay_id: int
    20    start: datetime.datetime
    21    end: datetime.datetime
    22    additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict)
    23
    24
    25    def to_dict(self) -> Dict[str, Any]:
    26        assay_id = self.assay_id
    27        start = self.start.isoformat()
    28
    29        end = self.end.isoformat()
    30
    31
    32        field_dict: Dict[str, Any] = {}
    33        field_dict.update(self.additional_properties)
    34        field_dict.update({
    35            "assay_id": assay_id,
    36            "start": start,
    37            "end": end,
    38        })
    39
    40        return field_dict
    41
    42
    43
    44    @classmethod
    45    def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
    46        d = src_dict.copy()
    47        assay_id = d.pop("assay_id")
    48
    49        start = isoparse(d.pop("start"))
    50
    51
    52
    53
    54        end = isoparse(d.pop("end"))
    55
    56
    57
    58
    59        assays_get_assay_results_json_body = cls(
    60            assay_id=assay_id,
    61            start=start,
    62            end=end,
    63        )
    64
    65        assays_get_assay_results_json_body.additional_properties = d
    66        return assays_get_assay_results_json_body
    67
    68    @property
    69    def additional_keys(self) -> List[str]:
    70        return list(self.additional_properties.keys())
    71
    72    def __getitem__(self, key: str) -> Any:
    73        return self.additional_properties[key]
    74
    75    def __setitem__(self, key: str, value: Any) -> None:
    76        self.additional_properties[key] = value
    77
    78    def __delitem__(self, key: str) -> None:
    79        del self.additional_properties[key]
    80
    81    def __contains__(self, key: str) -> bool:
    82        return key in self.additional_properties

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

    10@attr.s(auto_attribs=True)
    11class AssaysGetAssayResultsJsonBody:
    12    """ Request to return assay results.
    13
    14    Attributes:
    15        assay_id (int):
    16        start (datetime.datetime):
    17        end (datetime.datetime):
    18    """
    19
    20    assay_id: int
    21    start: datetime.datetime
    22    end: datetime.datetime
    23    additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict)
    24
    25
    26    def to_dict(self) -> Dict[str, Any]:
    27        assay_id = self.assay_id
    28        start = self.start.isoformat()
    29
    30        end = self.end.isoformat()
    31
    32
    33        field_dict: Dict[str, Any] = {}
    34        field_dict.update(self.additional_properties)
    35        field_dict.update({
    36            "assay_id": assay_id,
    37            "start": start,
    38            "end": end,
    39        })
    40
    41        return field_dict
    42
    43
    44
    45    @classmethod
    46    def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
    47        d = src_dict.copy()
    48        assay_id = d.pop("assay_id")
    49
    50        start = isoparse(d.pop("start"))
    51
    52
    53
    54
    55        end = isoparse(d.pop("end"))
    56
    57
    58
    59
    60        assays_get_assay_results_json_body = cls(
    61            assay_id=assay_id,
    62            start=start,
    63            end=end,
    64        )
    65
    66        assays_get_assay_results_json_body.additional_properties = d
    67        return assays_get_assay_results_json_body
    68
    69    @property
    70    def additional_keys(self) -> List[str]:
    71        return list(self.additional_properties.keys())
    72
    73    def __getitem__(self, key: str) -> Any:
    74        return self.additional_properties[key]
    75
    76    def __setitem__(self, key: str, value: Any) -> None:
    77        self.additional_properties[key] = value
    78
    79    def __delitem__(self, key: str) -> None:
    80        del self.additional_properties[key]
    81
    82    def __contains__(self, key: str) -> bool:
    83        return key in self.additional_properties

Request to return assay results.

Attributes: assay_id (int): start (datetime.datetime): end (datetime.datetime):

AssaysGetAssayResultsJsonBody(assay_id: int, start: datetime.datetime, end: datetime.datetime) View Source

    2def __init__(self, assay_id, start, end):
    3    self.assay_id = assay_id
    4    self.start = start
    5    self.end = end
    6    self.additional_properties = __attr_factory_additional_properties()

Method generated by attrs for class AssaysGetAssayResultsJsonBody.

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

    26    def to_dict(self) -> Dict[str, Any]:
    27        assay_id = self.assay_id
    28        start = self.start.isoformat()
    29
    30        end = self.end.isoformat()
    31
    32
    33        field_dict: Dict[str, Any] = {}
    34        field_dict.update(self.additional_properties)
    35        field_dict.update({
    36            "assay_id": assay_id,
    37            "start": start,
    38            "end": end,
    39        })
    40
    41        return field_dict

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

    45    @classmethod
    46    def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
    47        d = src_dict.copy()
    48        assay_id = d.pop("assay_id")
    49
    50        start = isoparse(d.pop("start"))
    51
    52
    53
    54
    55        end = isoparse(d.pop("end"))
    56
    57
    58
    59
    60        assays_get_assay_results_json_body = cls(
    61            assay_id=assay_id,
    62            start=start,
    63            end=end,
    64        )
    65
    66        assays_get_assay_results_json_body.additional_properties = d
    67        return assays_get_assay_results_json_body

additional_keys: List[str]