Skip to content

Commit

Permalink
Regenerate bindings for 4.6.0 release
Browse files Browse the repository at this point in the history
  • Loading branch information
JakubFrejlach committed Dec 10, 2024
1 parent ca318e3 commit 871af12
Show file tree
Hide file tree
Showing 7 changed files with 134 additions and 66 deletions.
43 changes: 28 additions & 15 deletions osidb_bindings/bindings/python_client/models/affect.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ class Affect(OSIDBModel):
uuid: str
ps_module: str
ps_product: str
ps_component: str
trackers: List[Tracker]
delegated_resolution: str
cvss_scores: List[AffectCVSS]
Expand All @@ -35,14 +34,15 @@ class Affect(OSIDBModel):
flaw: Optional[str]
affectedness: Union[AffectednessEnum, BlankEnum, Unset] = UNSET
resolution: Union[BlankEnum, ResolutionEnum, Unset] = UNSET
ps_component: Union[Unset, None, str] = UNSET
impact: Union[BlankEnum, ImpactEnum, Unset] = UNSET
purl: Union[Unset, None, str] = UNSET
additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict)

def to_dict(self) -> Dict[str, Any]:
uuid = self.uuid
ps_module = self.ps_module
ps_product = self.ps_product
ps_component = self.ps_component
trackers: List[Dict[str, Any]] = UNSET
if not isinstance(self.trackers, Unset):
trackers = []
Expand Down Expand Up @@ -114,6 +114,7 @@ def to_dict(self) -> Dict[str, Any]:

resolution = BlankEnum(self.resolution).value

ps_component = self.ps_component
impact: Union[Unset, str]
if isinstance(self.impact, Unset):
impact = UNSET
Expand All @@ -129,6 +130,8 @@ def to_dict(self) -> Dict[str, Any]:

impact = BlankEnum(self.impact).value

purl = self.purl

field_dict: Dict[str, Any] = {}
field_dict.update(self.additional_properties)
if not isinstance(uuid, Unset):
Expand All @@ -137,8 +140,6 @@ def to_dict(self) -> Dict[str, Any]:
field_dict["ps_module"] = ps_module
if not isinstance(ps_product, Unset):
field_dict["ps_product"] = ps_product
if not isinstance(ps_component, Unset):
field_dict["ps_component"] = ps_component
if not isinstance(trackers, Unset):
field_dict["trackers"] = trackers
if not isinstance(delegated_resolution, Unset):
Expand All @@ -159,8 +160,12 @@ def to_dict(self) -> Dict[str, Any]:
field_dict["affectedness"] = affectedness
if not isinstance(resolution, Unset):
field_dict["resolution"] = resolution
if not isinstance(ps_component, Unset):
field_dict["ps_component"] = ps_component
if not isinstance(impact, Unset):
field_dict["impact"] = impact
if not isinstance(purl, Unset):
field_dict["purl"] = purl

return field_dict

Expand All @@ -176,11 +181,6 @@ def to_multipart(self) -> Dict[str, Any]:
if self.ps_product is UNSET
else (None, str(self.ps_product), "text/plain")
)
ps_component = (
self.ps_component
if self.ps_component is UNSET
else (None, str(self.ps_component), "text/plain")
)
trackers: Union[Unset, Tuple[None, str, str]] = UNSET
if not isinstance(self.trackers, Unset):
_temp_trackers = []
Expand Down Expand Up @@ -263,6 +263,11 @@ def to_multipart(self) -> Dict[str, Any]:

resolution = BlankEnum(self.resolution).value

ps_component = (
self.ps_component
if self.ps_component is UNSET
else (None, str(self.ps_component), "text/plain")
)
impact: Union[Unset, str]
if isinstance(self.impact, Unset):
impact = UNSET
Expand All @@ -278,6 +283,8 @@ def to_multipart(self) -> Dict[str, Any]:

impact = BlankEnum(self.impact).value

purl = self.purl if self.purl is UNSET else (None, str(self.purl), "text/plain")

field_dict: Dict[str, Any] = {}
field_dict.update(
{
Expand All @@ -291,8 +298,6 @@ def to_multipart(self) -> Dict[str, Any]:
field_dict["ps_module"] = ps_module
if not isinstance(ps_product, Unset):
field_dict["ps_product"] = ps_product
if not isinstance(ps_component, Unset):
field_dict["ps_component"] = ps_component
if not isinstance(trackers, Unset):
field_dict["trackers"] = trackers
if not isinstance(delegated_resolution, Unset):
Expand All @@ -313,8 +318,12 @@ def to_multipart(self) -> Dict[str, Any]:
field_dict["affectedness"] = affectedness
if not isinstance(resolution, Unset):
field_dict["resolution"] = resolution
if not isinstance(ps_component, Unset):
field_dict["ps_component"] = ps_component
if not isinstance(impact, Unset):
field_dict["impact"] = impact
if not isinstance(purl, Unset):
field_dict["purl"] = purl

return field_dict

Expand All @@ -327,8 +336,6 @@ def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:

ps_product = d.pop("ps_product", UNSET)

ps_component = d.pop("ps_component", UNSET)

trackers = []
_trackers = d.pop("trackers", UNSET)
if _trackers is UNSET:
Expand Down Expand Up @@ -454,6 +461,8 @@ def _parse_resolution(data: object) -> Union[BlankEnum, ResolutionEnum, Unset]:

resolution = _parse_resolution(d.pop("resolution", UNSET))

ps_component = d.pop("ps_component", UNSET)

def _parse_impact(data: object) -> Union[BlankEnum, ImpactEnum, Unset]:
if isinstance(data, Unset):
return data
Expand Down Expand Up @@ -483,11 +492,12 @@ def _parse_impact(data: object) -> Union[BlankEnum, ImpactEnum, Unset]:

impact = _parse_impact(d.pop("impact", UNSET))

purl = d.pop("purl", UNSET)

affect = cls(
uuid=uuid,
ps_module=ps_module,
ps_product=ps_product,
ps_component=ps_component,
trackers=trackers,
delegated_resolution=delegated_resolution,
cvss_scores=cvss_scores,
Expand All @@ -498,7 +508,9 @@ def _parse_impact(data: object) -> Union[BlankEnum, ImpactEnum, Unset]:
flaw=flaw,
affectedness=affectedness,
resolution=resolution,
ps_component=ps_component,
impact=impact,
purl=purl,
)

affect.additional_properties = d
Expand All @@ -510,7 +522,6 @@ def get_fields():
"uuid": str,
"ps_module": str,
"ps_product": str,
"ps_component": str,
"trackers": List[Tracker],
"delegated_resolution": str,
"cvss_scores": List[AffectCVSS],
Expand All @@ -521,7 +532,9 @@ def get_fields():
"flaw": str,
"affectedness": Union[AffectednessEnum, BlankEnum],
"resolution": Union[BlankEnum, ResolutionEnum],
"ps_component": str,
"impact": Union[BlankEnum, ImpactEnum],
"purl": str,
}

@property
Expand Down
25 changes: 17 additions & 8 deletions osidb_bindings/bindings/python_client/models/affect_bulk_put.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ class AffectBulkPut(OSIDBModel):
uuid: str
ps_module: str
ps_product: str
ps_component: str
trackers: List[Tracker]
delegated_resolution: str
cvss_scores: List[AffectCVSS]
Expand All @@ -34,14 +33,15 @@ class AffectBulkPut(OSIDBModel):
flaw: Optional[str]
affectedness: Union[AffectednessEnum, BlankEnum, Unset] = UNSET
resolution: Union[BlankEnum, ResolutionEnum, Unset] = UNSET
ps_component: Union[Unset, None, str] = UNSET
impact: Union[BlankEnum, ImpactEnum, Unset] = UNSET
purl: Union[Unset, None, str] = UNSET
additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict)

def to_dict(self) -> Dict[str, Any]:
uuid = self.uuid
ps_module = self.ps_module
ps_product = self.ps_product
ps_component = self.ps_component
trackers: List[Dict[str, Any]] = UNSET
if not isinstance(self.trackers, Unset):
trackers = []
Expand Down Expand Up @@ -113,6 +113,7 @@ def to_dict(self) -> Dict[str, Any]:

resolution = BlankEnum(self.resolution).value

ps_component = self.ps_component
impact: Union[Unset, str]
if isinstance(self.impact, Unset):
impact = UNSET
Expand All @@ -128,6 +129,8 @@ def to_dict(self) -> Dict[str, Any]:

impact = BlankEnum(self.impact).value

purl = self.purl

field_dict: Dict[str, Any] = {}
field_dict.update(self.additional_properties)
if not isinstance(uuid, Unset):
Expand All @@ -136,8 +139,6 @@ def to_dict(self) -> Dict[str, Any]:
field_dict["ps_module"] = ps_module
if not isinstance(ps_product, Unset):
field_dict["ps_product"] = ps_product
if not isinstance(ps_component, Unset):
field_dict["ps_component"] = ps_component
if not isinstance(trackers, Unset):
field_dict["trackers"] = trackers
if not isinstance(delegated_resolution, Unset):
Expand All @@ -158,8 +159,12 @@ def to_dict(self) -> Dict[str, Any]:
field_dict["affectedness"] = affectedness
if not isinstance(resolution, Unset):
field_dict["resolution"] = resolution
if not isinstance(ps_component, Unset):
field_dict["ps_component"] = ps_component
if not isinstance(impact, Unset):
field_dict["impact"] = impact
if not isinstance(purl, Unset):
field_dict["purl"] = purl

return field_dict

Expand All @@ -172,8 +177,6 @@ def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:

ps_product = d.pop("ps_product", UNSET)

ps_component = d.pop("ps_component", UNSET)

trackers = []
_trackers = d.pop("trackers", UNSET)
if _trackers is UNSET:
Expand Down Expand Up @@ -299,6 +302,8 @@ def _parse_resolution(data: object) -> Union[BlankEnum, ResolutionEnum, Unset]:

resolution = _parse_resolution(d.pop("resolution", UNSET))

ps_component = d.pop("ps_component", UNSET)

def _parse_impact(data: object) -> Union[BlankEnum, ImpactEnum, Unset]:
if isinstance(data, Unset):
return data
Expand Down Expand Up @@ -328,11 +333,12 @@ def _parse_impact(data: object) -> Union[BlankEnum, ImpactEnum, Unset]:

impact = _parse_impact(d.pop("impact", UNSET))

purl = d.pop("purl", UNSET)

affect_bulk_put = cls(
uuid=uuid,
ps_module=ps_module,
ps_product=ps_product,
ps_component=ps_component,
trackers=trackers,
delegated_resolution=delegated_resolution,
cvss_scores=cvss_scores,
Expand All @@ -343,7 +349,9 @@ def _parse_impact(data: object) -> Union[BlankEnum, ImpactEnum, Unset]:
flaw=flaw,
affectedness=affectedness,
resolution=resolution,
ps_component=ps_component,
impact=impact,
purl=purl,
)

affect_bulk_put.additional_properties = d
Expand All @@ -355,7 +363,6 @@ def get_fields():
"uuid": str,
"ps_module": str,
"ps_product": str,
"ps_component": str,
"trackers": List[Tracker],
"delegated_resolution": str,
"cvss_scores": List[AffectCVSS],
Expand All @@ -366,7 +373,9 @@ def get_fields():
"flaw": str,
"affectedness": Union[AffectednessEnum, BlankEnum],
"resolution": Union[BlankEnum, ResolutionEnum],
"ps_component": str,
"impact": Union[BlankEnum, ImpactEnum],
"purl": str,
}

@property
Expand Down
Loading

0 comments on commit 871af12

Please sign in to comment.