Coverage for backend/django/flowsheetInternals/unitops/config/objects/solar_config.py: 100%
5 statements
« prev ^ index » next coverage.py v7.10.7, created at 2026-06-23 21:51 +0000
« prev ^ index » next coverage.py v7.10.7, created at 2026-06-23 21:51 +0000
1from core.auxiliary.enums.unitsOfMeasure import UnitOfMeasure
3from common.config_types import *
4from common.config_utils import *
5from ..spec_helpers import *
7solar_config: ObjectType = ObjectType(
8 displayType="Solar",
9 displayName="Solar",
10 ports={
11 "outlet": PortType(
12 displayName="Generated Power",
13 type=ConType.Outlet,
14 streamType="energy_stream",
15 streamName="PS",
16 )
17 },
18 propertyPackagePorts=default_property_package_ports(),
19 graphicObject=unitop_graphic(),
20 properties=PropertiesType({
21 "efficiency": PropertyType(
22 displayName="Efficiency",
23 type="numeric",
24 unitType="ratio",
25 hasTimeIndex=False,
26 ),
27 "irradiation": PropertyType(
28 displayName="Solar Irradiation",
29 type="numeric",
30 unitType="irradiance"
31 ),
32 "area": PropertyType(
33 displayName="Panel Area",
34 type="numeric",
35 unitType="area",
36 hasTimeIndex=False,
37 ),
38 "panel_count": PropertyType(
39 displayName="Number of Panels",
40 type="numeric",
41 unitType="ratio",
42 hasTimeIndex=False,
43 ),
45 }),
46 propertySetGroups={
47 "default": {
48 "type": "stateVars",
49 "displayName": "Properties",
50 "stateVars": ("efficiency","irradiation","area","panel_count"),
51 }
52 },
53 keyProperties=[
54 "efficiency",
55 "irradiation",
56 "area",
57 "panel_count"
58 ],
59 idaes_adapter=UnitModelAdapter(
60 args=ArgAdapter({
61 "property_package": ConstantSchemaAdapter(PowerPPArgSchema()),
62 }),
63 ),
64 )