policyengine-api-simulation-client 0.20251210.56__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- policyengine_api_simulation_client/__init__.py +8 -0
- policyengine_api_simulation_client/api/__init__.py +1 -0
- policyengine_api_simulation_client/api/default/__init__.py +1 -0
- policyengine_api_simulation_client/api/default/alive_ping_alive_get.py +139 -0
- policyengine_api_simulation_client/api/default/ping_ping_post.py +174 -0
- policyengine_api_simulation_client/api/default/simulate_simulate_economy_comparison_post.py +166 -0
- policyengine_api_simulation_client/api/default/started_ping_started_get.py +129 -0
- policyengine_api_simulation_client/client.py +268 -0
- policyengine_api_simulation_client/errors.py +16 -0
- policyengine_api_simulation_client/models/__init__.py +109 -0
- policyengine_api_simulation_client/models/age_group_baseline_reform_values.py +91 -0
- policyengine_api_simulation_client/models/baseline_reform_values.py +69 -0
- policyengine_api_simulation_client/models/budgetary_impact.py +101 -0
- policyengine_api_simulation_client/models/cliff_impact.py +75 -0
- policyengine_api_simulation_client/models/cliff_impact_in_simulation.py +69 -0
- policyengine_api_simulation_client/models/decile_impact.py +77 -0
- policyengine_api_simulation_client/models/decile_impact_average.py +46 -0
- policyengine_api_simulation_client/models/decile_impact_relative.py +46 -0
- policyengine_api_simulation_client/models/economy_comparison.py +338 -0
- policyengine_api_simulation_client/models/economy_comparison_detailed_budget_type_0.py +59 -0
- policyengine_api_simulation_client/models/gender_baseline_reform_values.py +75 -0
- policyengine_api_simulation_client/models/health_status.py +83 -0
- policyengine_api_simulation_client/models/hours_response.py +93 -0
- policyengine_api_simulation_client/models/http_validation_error.py +79 -0
- policyengine_api_simulation_client/models/inequality_impact.py +83 -0
- policyengine_api_simulation_client/models/intra_decile_impact.py +77 -0
- policyengine_api_simulation_client/models/intra_decile_impact_all.py +46 -0
- policyengine_api_simulation_client/models/intra_decile_impact_deciles.py +53 -0
- policyengine_api_simulation_client/models/intra_wealth_decile_impact_with_values.py +77 -0
- policyengine_api_simulation_client/models/intra_wealth_decile_impact_with_values_all.py +46 -0
- policyengine_api_simulation_client/models/intra_wealth_decile_impact_with_values_deciles.py +53 -0
- policyengine_api_simulation_client/models/labor_supply_response.py +119 -0
- policyengine_api_simulation_client/models/labor_supply_response_decile.py +63 -0
- policyengine_api_simulation_client/models/labor_supply_response_decile_additional_property.py +65 -0
- policyengine_api_simulation_client/models/labor_supply_response_decile_additional_property_additional_property.py +46 -0
- policyengine_api_simulation_client/models/labor_supply_response_relative_lsr.py +46 -0
- policyengine_api_simulation_client/models/parameter_change_dict.py +53 -0
- policyengine_api_simulation_client/models/parametric_reform.py +80 -0
- policyengine_api_simulation_client/models/ping_request.py +61 -0
- policyengine_api_simulation_client/models/ping_response.py +61 -0
- policyengine_api_simulation_client/models/poverty_gender_breakdown.py +75 -0
- policyengine_api_simulation_client/models/poverty_impact.py +75 -0
- policyengine_api_simulation_client/models/poverty_racial_breakdown_with_values.py +67 -0
- policyengine_api_simulation_client/models/probe_status.py +91 -0
- policyengine_api_simulation_client/models/program_specific_impact.py +77 -0
- policyengine_api_simulation_client/models/racial_baseline_reform_values.py +91 -0
- policyengine_api_simulation_client/models/simulation_options.py +309 -0
- policyengine_api_simulation_client/models/simulation_options_country.py +9 -0
- policyengine_api_simulation_client/models/simulation_options_data_type_1.py +46 -0
- policyengine_api_simulation_client/models/simulation_options_scope.py +9 -0
- policyengine_api_simulation_client/models/system_status.py +91 -0
- policyengine_api_simulation_client/models/uk_constituency_breakdown_by_constituency.py +85 -0
- policyengine_api_simulation_client/models/uk_constituency_breakdown_with_values.py +85 -0
- policyengine_api_simulation_client/models/uk_constituency_breakdown_with_values_by_constituency.py +59 -0
- policyengine_api_simulation_client/models/uk_constituency_breakdown_with_values_outcomes_by_region.py +67 -0
- policyengine_api_simulation_client/models/uk_constituency_breakdown_with_values_outcomes_by_region_additional_property.py +46 -0
- policyengine_api_simulation_client/models/validation_error.py +90 -0
- policyengine_api_simulation_client/models/wealth_decile_impact_with_values.py +77 -0
- policyengine_api_simulation_client/models/wealth_decile_impact_with_values_average.py +46 -0
- policyengine_api_simulation_client/models/wealth_decile_impact_with_values_relative.py +46 -0
- policyengine_api_simulation_client/py.typed +1 -0
- policyengine_api_simulation_client/types.py +54 -0
- policyengine_api_simulation_client-0.20251210.56.dist-info/METADATA +141 -0
- policyengine_api_simulation_client-0.20251210.56.dist-info/RECORD +65 -0
- policyengine_api_simulation_client-0.20251210.56.dist-info/WHEEL +4 -0
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from collections.abc import Mapping
|
|
4
|
+
from typing import TYPE_CHECKING, Any, TypeVar
|
|
5
|
+
|
|
6
|
+
from attrs import define as _attrs_define
|
|
7
|
+
from attrs import field as _attrs_field
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
from ..models.intra_wealth_decile_impact_with_values_all import IntraWealthDecileImpactWithValuesAll
|
|
11
|
+
from ..models.intra_wealth_decile_impact_with_values_deciles import IntraWealthDecileImpactWithValuesDeciles
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
T = TypeVar("T", bound="IntraWealthDecileImpactWithValues")
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
@_attrs_define
|
|
18
|
+
class IntraWealthDecileImpactWithValues:
|
|
19
|
+
"""
|
|
20
|
+
Attributes:
|
|
21
|
+
deciles (IntraWealthDecileImpactWithValuesDeciles):
|
|
22
|
+
all_ (IntraWealthDecileImpactWithValuesAll):
|
|
23
|
+
"""
|
|
24
|
+
|
|
25
|
+
deciles: IntraWealthDecileImpactWithValuesDeciles
|
|
26
|
+
all_: IntraWealthDecileImpactWithValuesAll
|
|
27
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
28
|
+
|
|
29
|
+
def to_dict(self) -> dict[str, Any]:
|
|
30
|
+
deciles = self.deciles.to_dict()
|
|
31
|
+
|
|
32
|
+
all_ = self.all_.to_dict()
|
|
33
|
+
|
|
34
|
+
field_dict: dict[str, Any] = {}
|
|
35
|
+
field_dict.update(self.additional_properties)
|
|
36
|
+
field_dict.update(
|
|
37
|
+
{
|
|
38
|
+
"deciles": deciles,
|
|
39
|
+
"all": all_,
|
|
40
|
+
}
|
|
41
|
+
)
|
|
42
|
+
|
|
43
|
+
return field_dict
|
|
44
|
+
|
|
45
|
+
@classmethod
|
|
46
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
47
|
+
from ..models.intra_wealth_decile_impact_with_values_all import IntraWealthDecileImpactWithValuesAll
|
|
48
|
+
from ..models.intra_wealth_decile_impact_with_values_deciles import IntraWealthDecileImpactWithValuesDeciles
|
|
49
|
+
|
|
50
|
+
d = dict(src_dict)
|
|
51
|
+
deciles = IntraWealthDecileImpactWithValuesDeciles.from_dict(d.pop("deciles"))
|
|
52
|
+
|
|
53
|
+
all_ = IntraWealthDecileImpactWithValuesAll.from_dict(d.pop("all"))
|
|
54
|
+
|
|
55
|
+
intra_wealth_decile_impact_with_values = cls(
|
|
56
|
+
deciles=deciles,
|
|
57
|
+
all_=all_,
|
|
58
|
+
)
|
|
59
|
+
|
|
60
|
+
intra_wealth_decile_impact_with_values.additional_properties = d
|
|
61
|
+
return intra_wealth_decile_impact_with_values
|
|
62
|
+
|
|
63
|
+
@property
|
|
64
|
+
def additional_keys(self) -> list[str]:
|
|
65
|
+
return list(self.additional_properties.keys())
|
|
66
|
+
|
|
67
|
+
def __getitem__(self, key: str) -> Any:
|
|
68
|
+
return self.additional_properties[key]
|
|
69
|
+
|
|
70
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
71
|
+
self.additional_properties[key] = value
|
|
72
|
+
|
|
73
|
+
def __delitem__(self, key: str) -> None:
|
|
74
|
+
del self.additional_properties[key]
|
|
75
|
+
|
|
76
|
+
def __contains__(self, key: str) -> bool:
|
|
77
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from collections.abc import Mapping
|
|
4
|
+
from typing import Any, TypeVar
|
|
5
|
+
|
|
6
|
+
from attrs import define as _attrs_define
|
|
7
|
+
from attrs import field as _attrs_field
|
|
8
|
+
|
|
9
|
+
T = TypeVar("T", bound="IntraWealthDecileImpactWithValuesAll")
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
@_attrs_define
|
|
13
|
+
class IntraWealthDecileImpactWithValuesAll:
|
|
14
|
+
""" """
|
|
15
|
+
|
|
16
|
+
additional_properties: dict[str, float] = _attrs_field(init=False, factory=dict)
|
|
17
|
+
|
|
18
|
+
def to_dict(self) -> dict[str, Any]:
|
|
19
|
+
field_dict: dict[str, Any] = {}
|
|
20
|
+
field_dict.update(self.additional_properties)
|
|
21
|
+
|
|
22
|
+
return field_dict
|
|
23
|
+
|
|
24
|
+
@classmethod
|
|
25
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
26
|
+
d = dict(src_dict)
|
|
27
|
+
intra_wealth_decile_impact_with_values_all = cls()
|
|
28
|
+
|
|
29
|
+
intra_wealth_decile_impact_with_values_all.additional_properties = d
|
|
30
|
+
return intra_wealth_decile_impact_with_values_all
|
|
31
|
+
|
|
32
|
+
@property
|
|
33
|
+
def additional_keys(self) -> list[str]:
|
|
34
|
+
return list(self.additional_properties.keys())
|
|
35
|
+
|
|
36
|
+
def __getitem__(self, key: str) -> float:
|
|
37
|
+
return self.additional_properties[key]
|
|
38
|
+
|
|
39
|
+
def __setitem__(self, key: str, value: float) -> None:
|
|
40
|
+
self.additional_properties[key] = value
|
|
41
|
+
|
|
42
|
+
def __delitem__(self, key: str) -> None:
|
|
43
|
+
del self.additional_properties[key]
|
|
44
|
+
|
|
45
|
+
def __contains__(self, key: str) -> bool:
|
|
46
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from collections.abc import Mapping
|
|
4
|
+
from typing import Any, TypeVar, cast
|
|
5
|
+
|
|
6
|
+
from attrs import define as _attrs_define
|
|
7
|
+
from attrs import field as _attrs_field
|
|
8
|
+
|
|
9
|
+
T = TypeVar("T", bound="IntraWealthDecileImpactWithValuesDeciles")
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
@_attrs_define
|
|
13
|
+
class IntraWealthDecileImpactWithValuesDeciles:
|
|
14
|
+
""" """
|
|
15
|
+
|
|
16
|
+
additional_properties: dict[str, list[float]] = _attrs_field(init=False, factory=dict)
|
|
17
|
+
|
|
18
|
+
def to_dict(self) -> dict[str, Any]:
|
|
19
|
+
field_dict: dict[str, Any] = {}
|
|
20
|
+
for prop_name, prop in self.additional_properties.items():
|
|
21
|
+
field_dict[prop_name] = prop
|
|
22
|
+
|
|
23
|
+
return field_dict
|
|
24
|
+
|
|
25
|
+
@classmethod
|
|
26
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
27
|
+
d = dict(src_dict)
|
|
28
|
+
intra_wealth_decile_impact_with_values_deciles = cls()
|
|
29
|
+
|
|
30
|
+
additional_properties = {}
|
|
31
|
+
for prop_name, prop_dict in d.items():
|
|
32
|
+
additional_property = cast(list[float], prop_dict)
|
|
33
|
+
|
|
34
|
+
additional_properties[prop_name] = additional_property
|
|
35
|
+
|
|
36
|
+
intra_wealth_decile_impact_with_values_deciles.additional_properties = additional_properties
|
|
37
|
+
return intra_wealth_decile_impact_with_values_deciles
|
|
38
|
+
|
|
39
|
+
@property
|
|
40
|
+
def additional_keys(self) -> list[str]:
|
|
41
|
+
return list(self.additional_properties.keys())
|
|
42
|
+
|
|
43
|
+
def __getitem__(self, key: str) -> list[float]:
|
|
44
|
+
return self.additional_properties[key]
|
|
45
|
+
|
|
46
|
+
def __setitem__(self, key: str, value: list[float]) -> None:
|
|
47
|
+
self.additional_properties[key] = value
|
|
48
|
+
|
|
49
|
+
def __delitem__(self, key: str) -> None:
|
|
50
|
+
del self.additional_properties[key]
|
|
51
|
+
|
|
52
|
+
def __contains__(self, key: str) -> bool:
|
|
53
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from collections.abc import Mapping
|
|
4
|
+
from typing import TYPE_CHECKING, Any, TypeVar
|
|
5
|
+
|
|
6
|
+
from attrs import define as _attrs_define
|
|
7
|
+
from attrs import field as _attrs_field
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
from ..models.hours_response import HoursResponse
|
|
11
|
+
from ..models.labor_supply_response_decile import LaborSupplyResponseDecile
|
|
12
|
+
from ..models.labor_supply_response_relative_lsr import LaborSupplyResponseRelativeLsr
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
T = TypeVar("T", bound="LaborSupplyResponse")
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
@_attrs_define
|
|
19
|
+
class LaborSupplyResponse:
|
|
20
|
+
"""
|
|
21
|
+
Attributes:
|
|
22
|
+
substitution_lsr (float):
|
|
23
|
+
income_lsr (float):
|
|
24
|
+
relative_lsr (LaborSupplyResponseRelativeLsr):
|
|
25
|
+
total_change (float):
|
|
26
|
+
revenue_change (float):
|
|
27
|
+
decile (LaborSupplyResponseDecile):
|
|
28
|
+
hours (HoursResponse):
|
|
29
|
+
"""
|
|
30
|
+
|
|
31
|
+
substitution_lsr: float
|
|
32
|
+
income_lsr: float
|
|
33
|
+
relative_lsr: LaborSupplyResponseRelativeLsr
|
|
34
|
+
total_change: float
|
|
35
|
+
revenue_change: float
|
|
36
|
+
decile: LaborSupplyResponseDecile
|
|
37
|
+
hours: HoursResponse
|
|
38
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
39
|
+
|
|
40
|
+
def to_dict(self) -> dict[str, Any]:
|
|
41
|
+
substitution_lsr = self.substitution_lsr
|
|
42
|
+
|
|
43
|
+
income_lsr = self.income_lsr
|
|
44
|
+
|
|
45
|
+
relative_lsr = self.relative_lsr.to_dict()
|
|
46
|
+
|
|
47
|
+
total_change = self.total_change
|
|
48
|
+
|
|
49
|
+
revenue_change = self.revenue_change
|
|
50
|
+
|
|
51
|
+
decile = self.decile.to_dict()
|
|
52
|
+
|
|
53
|
+
hours = self.hours.to_dict()
|
|
54
|
+
|
|
55
|
+
field_dict: dict[str, Any] = {}
|
|
56
|
+
field_dict.update(self.additional_properties)
|
|
57
|
+
field_dict.update(
|
|
58
|
+
{
|
|
59
|
+
"substitution_lsr": substitution_lsr,
|
|
60
|
+
"income_lsr": income_lsr,
|
|
61
|
+
"relative_lsr": relative_lsr,
|
|
62
|
+
"total_change": total_change,
|
|
63
|
+
"revenue_change": revenue_change,
|
|
64
|
+
"decile": decile,
|
|
65
|
+
"hours": hours,
|
|
66
|
+
}
|
|
67
|
+
)
|
|
68
|
+
|
|
69
|
+
return field_dict
|
|
70
|
+
|
|
71
|
+
@classmethod
|
|
72
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
73
|
+
from ..models.hours_response import HoursResponse
|
|
74
|
+
from ..models.labor_supply_response_decile import LaborSupplyResponseDecile
|
|
75
|
+
from ..models.labor_supply_response_relative_lsr import LaborSupplyResponseRelativeLsr
|
|
76
|
+
|
|
77
|
+
d = dict(src_dict)
|
|
78
|
+
substitution_lsr = d.pop("substitution_lsr")
|
|
79
|
+
|
|
80
|
+
income_lsr = d.pop("income_lsr")
|
|
81
|
+
|
|
82
|
+
relative_lsr = LaborSupplyResponseRelativeLsr.from_dict(d.pop("relative_lsr"))
|
|
83
|
+
|
|
84
|
+
total_change = d.pop("total_change")
|
|
85
|
+
|
|
86
|
+
revenue_change = d.pop("revenue_change")
|
|
87
|
+
|
|
88
|
+
decile = LaborSupplyResponseDecile.from_dict(d.pop("decile"))
|
|
89
|
+
|
|
90
|
+
hours = HoursResponse.from_dict(d.pop("hours"))
|
|
91
|
+
|
|
92
|
+
labor_supply_response = cls(
|
|
93
|
+
substitution_lsr=substitution_lsr,
|
|
94
|
+
income_lsr=income_lsr,
|
|
95
|
+
relative_lsr=relative_lsr,
|
|
96
|
+
total_change=total_change,
|
|
97
|
+
revenue_change=revenue_change,
|
|
98
|
+
decile=decile,
|
|
99
|
+
hours=hours,
|
|
100
|
+
)
|
|
101
|
+
|
|
102
|
+
labor_supply_response.additional_properties = d
|
|
103
|
+
return labor_supply_response
|
|
104
|
+
|
|
105
|
+
@property
|
|
106
|
+
def additional_keys(self) -> list[str]:
|
|
107
|
+
return list(self.additional_properties.keys())
|
|
108
|
+
|
|
109
|
+
def __getitem__(self, key: str) -> Any:
|
|
110
|
+
return self.additional_properties[key]
|
|
111
|
+
|
|
112
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
113
|
+
self.additional_properties[key] = value
|
|
114
|
+
|
|
115
|
+
def __delitem__(self, key: str) -> None:
|
|
116
|
+
del self.additional_properties[key]
|
|
117
|
+
|
|
118
|
+
def __contains__(self, key: str) -> bool:
|
|
119
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from collections.abc import Mapping
|
|
4
|
+
from typing import TYPE_CHECKING, Any, TypeVar
|
|
5
|
+
|
|
6
|
+
from attrs import define as _attrs_define
|
|
7
|
+
from attrs import field as _attrs_field
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
from ..models.labor_supply_response_decile_additional_property import LaborSupplyResponseDecileAdditionalProperty
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
T = TypeVar("T", bound="LaborSupplyResponseDecile")
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
@_attrs_define
|
|
17
|
+
class LaborSupplyResponseDecile:
|
|
18
|
+
""" """
|
|
19
|
+
|
|
20
|
+
additional_properties: dict[str, LaborSupplyResponseDecileAdditionalProperty] = _attrs_field(
|
|
21
|
+
init=False, factory=dict
|
|
22
|
+
)
|
|
23
|
+
|
|
24
|
+
def to_dict(self) -> dict[str, Any]:
|
|
25
|
+
field_dict: dict[str, Any] = {}
|
|
26
|
+
for prop_name, prop in self.additional_properties.items():
|
|
27
|
+
field_dict[prop_name] = prop.to_dict()
|
|
28
|
+
|
|
29
|
+
return field_dict
|
|
30
|
+
|
|
31
|
+
@classmethod
|
|
32
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
33
|
+
from ..models.labor_supply_response_decile_additional_property import (
|
|
34
|
+
LaborSupplyResponseDecileAdditionalProperty,
|
|
35
|
+
)
|
|
36
|
+
|
|
37
|
+
d = dict(src_dict)
|
|
38
|
+
labor_supply_response_decile = cls()
|
|
39
|
+
|
|
40
|
+
additional_properties = {}
|
|
41
|
+
for prop_name, prop_dict in d.items():
|
|
42
|
+
additional_property = LaborSupplyResponseDecileAdditionalProperty.from_dict(prop_dict)
|
|
43
|
+
|
|
44
|
+
additional_properties[prop_name] = additional_property
|
|
45
|
+
|
|
46
|
+
labor_supply_response_decile.additional_properties = additional_properties
|
|
47
|
+
return labor_supply_response_decile
|
|
48
|
+
|
|
49
|
+
@property
|
|
50
|
+
def additional_keys(self) -> list[str]:
|
|
51
|
+
return list(self.additional_properties.keys())
|
|
52
|
+
|
|
53
|
+
def __getitem__(self, key: str) -> LaborSupplyResponseDecileAdditionalProperty:
|
|
54
|
+
return self.additional_properties[key]
|
|
55
|
+
|
|
56
|
+
def __setitem__(self, key: str, value: LaborSupplyResponseDecileAdditionalProperty) -> None:
|
|
57
|
+
self.additional_properties[key] = value
|
|
58
|
+
|
|
59
|
+
def __delitem__(self, key: str) -> None:
|
|
60
|
+
del self.additional_properties[key]
|
|
61
|
+
|
|
62
|
+
def __contains__(self, key: str) -> bool:
|
|
63
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from collections.abc import Mapping
|
|
4
|
+
from typing import TYPE_CHECKING, Any, TypeVar
|
|
5
|
+
|
|
6
|
+
from attrs import define as _attrs_define
|
|
7
|
+
from attrs import field as _attrs_field
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
from ..models.labor_supply_response_decile_additional_property_additional_property import (
|
|
11
|
+
LaborSupplyResponseDecileAdditionalPropertyAdditionalProperty,
|
|
12
|
+
)
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
T = TypeVar("T", bound="LaborSupplyResponseDecileAdditionalProperty")
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
@_attrs_define
|
|
19
|
+
class LaborSupplyResponseDecileAdditionalProperty:
|
|
20
|
+
""" """
|
|
21
|
+
|
|
22
|
+
additional_properties: dict[str, LaborSupplyResponseDecileAdditionalPropertyAdditionalProperty] = _attrs_field(
|
|
23
|
+
init=False, factory=dict
|
|
24
|
+
)
|
|
25
|
+
|
|
26
|
+
def to_dict(self) -> dict[str, Any]:
|
|
27
|
+
field_dict: dict[str, Any] = {}
|
|
28
|
+
for prop_name, prop in self.additional_properties.items():
|
|
29
|
+
field_dict[prop_name] = prop.to_dict()
|
|
30
|
+
|
|
31
|
+
return field_dict
|
|
32
|
+
|
|
33
|
+
@classmethod
|
|
34
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
35
|
+
from ..models.labor_supply_response_decile_additional_property_additional_property import (
|
|
36
|
+
LaborSupplyResponseDecileAdditionalPropertyAdditionalProperty,
|
|
37
|
+
)
|
|
38
|
+
|
|
39
|
+
d = dict(src_dict)
|
|
40
|
+
labor_supply_response_decile_additional_property = cls()
|
|
41
|
+
|
|
42
|
+
additional_properties = {}
|
|
43
|
+
for prop_name, prop_dict in d.items():
|
|
44
|
+
additional_property = LaborSupplyResponseDecileAdditionalPropertyAdditionalProperty.from_dict(prop_dict)
|
|
45
|
+
|
|
46
|
+
additional_properties[prop_name] = additional_property
|
|
47
|
+
|
|
48
|
+
labor_supply_response_decile_additional_property.additional_properties = additional_properties
|
|
49
|
+
return labor_supply_response_decile_additional_property
|
|
50
|
+
|
|
51
|
+
@property
|
|
52
|
+
def additional_keys(self) -> list[str]:
|
|
53
|
+
return list(self.additional_properties.keys())
|
|
54
|
+
|
|
55
|
+
def __getitem__(self, key: str) -> LaborSupplyResponseDecileAdditionalPropertyAdditionalProperty:
|
|
56
|
+
return self.additional_properties[key]
|
|
57
|
+
|
|
58
|
+
def __setitem__(self, key: str, value: LaborSupplyResponseDecileAdditionalPropertyAdditionalProperty) -> None:
|
|
59
|
+
self.additional_properties[key] = value
|
|
60
|
+
|
|
61
|
+
def __delitem__(self, key: str) -> None:
|
|
62
|
+
del self.additional_properties[key]
|
|
63
|
+
|
|
64
|
+
def __contains__(self, key: str) -> bool:
|
|
65
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from collections.abc import Mapping
|
|
4
|
+
from typing import Any, TypeVar
|
|
5
|
+
|
|
6
|
+
from attrs import define as _attrs_define
|
|
7
|
+
from attrs import field as _attrs_field
|
|
8
|
+
|
|
9
|
+
T = TypeVar("T", bound="LaborSupplyResponseDecileAdditionalPropertyAdditionalProperty")
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
@_attrs_define
|
|
13
|
+
class LaborSupplyResponseDecileAdditionalPropertyAdditionalProperty:
|
|
14
|
+
""" """
|
|
15
|
+
|
|
16
|
+
additional_properties: dict[str, float] = _attrs_field(init=False, factory=dict)
|
|
17
|
+
|
|
18
|
+
def to_dict(self) -> dict[str, Any]:
|
|
19
|
+
field_dict: dict[str, Any] = {}
|
|
20
|
+
field_dict.update(self.additional_properties)
|
|
21
|
+
|
|
22
|
+
return field_dict
|
|
23
|
+
|
|
24
|
+
@classmethod
|
|
25
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
26
|
+
d = dict(src_dict)
|
|
27
|
+
labor_supply_response_decile_additional_property_additional_property = cls()
|
|
28
|
+
|
|
29
|
+
labor_supply_response_decile_additional_property_additional_property.additional_properties = d
|
|
30
|
+
return labor_supply_response_decile_additional_property_additional_property
|
|
31
|
+
|
|
32
|
+
@property
|
|
33
|
+
def additional_keys(self) -> list[str]:
|
|
34
|
+
return list(self.additional_properties.keys())
|
|
35
|
+
|
|
36
|
+
def __getitem__(self, key: str) -> float:
|
|
37
|
+
return self.additional_properties[key]
|
|
38
|
+
|
|
39
|
+
def __setitem__(self, key: str, value: float) -> None:
|
|
40
|
+
self.additional_properties[key] = value
|
|
41
|
+
|
|
42
|
+
def __delitem__(self, key: str) -> None:
|
|
43
|
+
del self.additional_properties[key]
|
|
44
|
+
|
|
45
|
+
def __contains__(self, key: str) -> bool:
|
|
46
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from collections.abc import Mapping
|
|
4
|
+
from typing import Any, TypeVar
|
|
5
|
+
|
|
6
|
+
from attrs import define as _attrs_define
|
|
7
|
+
from attrs import field as _attrs_field
|
|
8
|
+
|
|
9
|
+
T = TypeVar("T", bound="LaborSupplyResponseRelativeLsr")
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
@_attrs_define
|
|
13
|
+
class LaborSupplyResponseRelativeLsr:
|
|
14
|
+
""" """
|
|
15
|
+
|
|
16
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
17
|
+
|
|
18
|
+
def to_dict(self) -> dict[str, Any]:
|
|
19
|
+
field_dict: dict[str, Any] = {}
|
|
20
|
+
field_dict.update(self.additional_properties)
|
|
21
|
+
|
|
22
|
+
return field_dict
|
|
23
|
+
|
|
24
|
+
@classmethod
|
|
25
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
26
|
+
d = dict(src_dict)
|
|
27
|
+
labor_supply_response_relative_lsr = cls()
|
|
28
|
+
|
|
29
|
+
labor_supply_response_relative_lsr.additional_properties = d
|
|
30
|
+
return labor_supply_response_relative_lsr
|
|
31
|
+
|
|
32
|
+
@property
|
|
33
|
+
def additional_keys(self) -> list[str]:
|
|
34
|
+
return list(self.additional_properties.keys())
|
|
35
|
+
|
|
36
|
+
def __getitem__(self, key: str) -> Any:
|
|
37
|
+
return self.additional_properties[key]
|
|
38
|
+
|
|
39
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
40
|
+
self.additional_properties[key] = value
|
|
41
|
+
|
|
42
|
+
def __delitem__(self, key: str) -> None:
|
|
43
|
+
del self.additional_properties[key]
|
|
44
|
+
|
|
45
|
+
def __contains__(self, key: str) -> bool:
|
|
46
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from collections.abc import Mapping
|
|
4
|
+
from typing import Any, TypeVar
|
|
5
|
+
|
|
6
|
+
from attrs import define as _attrs_define
|
|
7
|
+
from attrs import field as _attrs_field
|
|
8
|
+
|
|
9
|
+
T = TypeVar("T", bound="ParameterChangeDict")
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
@_attrs_define
|
|
13
|
+
class ParameterChangeDict:
|
|
14
|
+
"""A dict of changes to a parameter, with custom date string as keys
|
|
15
|
+
and various possible value types.
|
|
16
|
+
|
|
17
|
+
Keys can be formatted one of two ways:
|
|
18
|
+
1. A single year (e.g., "YYYY")
|
|
19
|
+
2. A date range (e.g., "YYYY-MM-DD.YYYY-MM-DD")
|
|
20
|
+
|
|
21
|
+
"""
|
|
22
|
+
|
|
23
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
24
|
+
|
|
25
|
+
def to_dict(self) -> dict[str, Any]:
|
|
26
|
+
field_dict: dict[str, Any] = {}
|
|
27
|
+
field_dict.update(self.additional_properties)
|
|
28
|
+
|
|
29
|
+
return field_dict
|
|
30
|
+
|
|
31
|
+
@classmethod
|
|
32
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
33
|
+
d = dict(src_dict)
|
|
34
|
+
parameter_change_dict = cls()
|
|
35
|
+
|
|
36
|
+
parameter_change_dict.additional_properties = d
|
|
37
|
+
return parameter_change_dict
|
|
38
|
+
|
|
39
|
+
@property
|
|
40
|
+
def additional_keys(self) -> list[str]:
|
|
41
|
+
return list(self.additional_properties.keys())
|
|
42
|
+
|
|
43
|
+
def __getitem__(self, key: str) -> Any:
|
|
44
|
+
return self.additional_properties[key]
|
|
45
|
+
|
|
46
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
47
|
+
self.additional_properties[key] = value
|
|
48
|
+
|
|
49
|
+
def __delitem__(self, key: str) -> None:
|
|
50
|
+
del self.additional_properties[key]
|
|
51
|
+
|
|
52
|
+
def __contains__(self, key: str) -> bool:
|
|
53
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from collections.abc import Mapping
|
|
4
|
+
from typing import TYPE_CHECKING, Any, TypeVar, cast
|
|
5
|
+
|
|
6
|
+
from attrs import define as _attrs_define
|
|
7
|
+
from attrs import field as _attrs_field
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
from ..models.parameter_change_dict import ParameterChangeDict
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
T = TypeVar("T", bound="ParametricReform")
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
@_attrs_define
|
|
17
|
+
class ParametricReform:
|
|
18
|
+
"""A reform that just changes parameter values.
|
|
19
|
+
|
|
20
|
+
This is a dict that equates a parameter name to either a single value or a dict of changes.
|
|
21
|
+
|
|
22
|
+
"""
|
|
23
|
+
|
|
24
|
+
additional_properties: dict[str, Any | ParameterChangeDict] = _attrs_field(init=False, factory=dict)
|
|
25
|
+
|
|
26
|
+
def to_dict(self) -> dict[str, Any]:
|
|
27
|
+
from ..models.parameter_change_dict import ParameterChangeDict
|
|
28
|
+
|
|
29
|
+
field_dict: dict[str, Any] = {}
|
|
30
|
+
for prop_name, prop in self.additional_properties.items():
|
|
31
|
+
if isinstance(prop, ParameterChangeDict):
|
|
32
|
+
field_dict[prop_name] = prop.to_dict()
|
|
33
|
+
else:
|
|
34
|
+
field_dict[prop_name] = prop
|
|
35
|
+
|
|
36
|
+
return field_dict
|
|
37
|
+
|
|
38
|
+
@classmethod
|
|
39
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
40
|
+
from ..models.parameter_change_dict import ParameterChangeDict
|
|
41
|
+
|
|
42
|
+
d = dict(src_dict)
|
|
43
|
+
parametric_reform = cls()
|
|
44
|
+
|
|
45
|
+
additional_properties = {}
|
|
46
|
+
for prop_name, prop_dict in d.items():
|
|
47
|
+
|
|
48
|
+
def _parse_additional_property(data: object) -> Any | ParameterChangeDict:
|
|
49
|
+
try:
|
|
50
|
+
if not isinstance(data, dict):
|
|
51
|
+
raise TypeError()
|
|
52
|
+
additional_property_type_1 = ParameterChangeDict.from_dict(data)
|
|
53
|
+
|
|
54
|
+
return additional_property_type_1
|
|
55
|
+
except (TypeError, ValueError, AttributeError, KeyError):
|
|
56
|
+
pass
|
|
57
|
+
return cast(Any | ParameterChangeDict, data)
|
|
58
|
+
|
|
59
|
+
additional_property = _parse_additional_property(prop_dict)
|
|
60
|
+
|
|
61
|
+
additional_properties[prop_name] = additional_property
|
|
62
|
+
|
|
63
|
+
parametric_reform.additional_properties = additional_properties
|
|
64
|
+
return parametric_reform
|
|
65
|
+
|
|
66
|
+
@property
|
|
67
|
+
def additional_keys(self) -> list[str]:
|
|
68
|
+
return list(self.additional_properties.keys())
|
|
69
|
+
|
|
70
|
+
def __getitem__(self, key: str) -> Any | ParameterChangeDict:
|
|
71
|
+
return self.additional_properties[key]
|
|
72
|
+
|
|
73
|
+
def __setitem__(self, key: str, value: Any | ParameterChangeDict) -> None:
|
|
74
|
+
self.additional_properties[key] = value
|
|
75
|
+
|
|
76
|
+
def __delitem__(self, key: str) -> None:
|
|
77
|
+
del self.additional_properties[key]
|
|
78
|
+
|
|
79
|
+
def __contains__(self, key: str) -> bool:
|
|
80
|
+
return key in self.additional_properties
|