|
13 | 13 |
|
14 | 14 | @dataclass
|
15 | 15 | class ActiveClass(ActiveClassS, ActiveClassI, ActiveClassV):
|
16 |
| - """This interface implements the ActiveClass (IActiveClass) interface of OpenDSS by declaring 3 procedures for |
17 |
| - accessing the different properties included in this interface: ActiveClassS, ActiveClassI, ActiveClassV. Ih the |
18 |
| - original paper Davis cited that are 4 procedures, but only 3 were described.""" |
| 16 | + """This class implements the ActiveClass interface of OpenDSS. |
| 17 | +
|
| 18 | + The ActiveClass interface provides methods for accessing properties of DSS classes. |
| 19 | + This class defines the methods for accessing the different properties included in this interface: |
| 20 | + ActiveClassS, ActiveClassI, ActiveClassV. |
| 21 | +
|
| 22 | + Args: |
| 23 | + obj_dss: The COM object that provides access to the OpenDSS engine. |
| 24 | + """ |
19 | 25 |
|
20 | 26 | def __init__(self, obj_dss):
|
21 | 27 | super().__init__(obj_dss)
|
22 | 28 |
|
23 | 29 | def first(self) -> int:
|
| 30 | + """Sets first element in the active class to be the active DSS object. |
| 31 | + If object is a CktElement, ActiveCktElement also points to this element. |
| 32 | + Returns 0 if none.""" |
24 | 33 | return ActiveClassI._first(self)
|
25 | 34 |
|
26 | 35 | def next(self) -> int:
|
| 36 | + """Sets next element in the active class to be the active DSS object. |
| 37 | + If object is a CktElement, ActiveCktElement also points to this element. |
| 38 | + Returns 0 if none.""" |
27 | 39 | return ActiveClassI._next(self)
|
28 | 40 |
|
29 | 41 | @property
|
30 | 42 | def num_elements(self) -> int:
|
| 43 | + """Gets the number of elements in this class. Same as Count Property.""" |
31 | 44 | return ActiveClassI._num_elements(self)
|
32 | 45 |
|
33 | 46 | @property
|
34 | 47 | def count(self) -> int:
|
| 48 | + """Gets the number of elements in this class. Same as NumElements Property.""" |
35 | 49 | return ActiveClassI._count(self)
|
36 | 50 |
|
37 | 51 | @property
|
38 | 52 | def name(self) -> str:
|
| 53 | + """Gets the name of the active Element of the Active class.""" |
39 | 54 | return ActiveClassS._name(self)
|
40 | 55 |
|
41 | 56 | @name.setter
|
42 | 57 | def name(self, argument: str):
|
| 58 | + """Sets the name of the active Element of the Active class.""" |
43 | 59 | ActiveClassS._name_write(self, argument)
|
44 | 60 |
|
45 | 61 | @property
|
46 | 62 | def class_name(self) -> str:
|
| 63 | + """Gets the name of the active Element's class.""" |
47 | 64 | return ActiveClassS._class_name(self)
|
48 | 65 |
|
49 | 66 | @property
|
50 | 67 | def parent_class_name(self) -> str:
|
| 68 | + """Gets the name of the Parent Element of the Active class.""" |
51 | 69 | return ActiveClassS._parent_class_name(self)
|
52 | 70 |
|
53 | 71 | @property
|
54 | 72 | def names(self) -> List[str]:
|
| 73 | + """Gets a list of all element names in the active Class.""" |
55 | 74 | return ActiveClassV._names(self)
|
| 75 | + |
0 commit comments