Skip to content

Commit

Permalink
enums: add DSSObjectFlags
Browse files Browse the repository at this point in the history
  • Loading branch information
PMeira committed Mar 19, 2024
1 parent bb497cd commit 2ffe0ca
Showing 1 changed file with 44 additions and 1 deletion.
45 changes: 44 additions & 1 deletion dss_python_backend/enums.py
Original file line number Diff line number Diff line change
Expand Up @@ -423,7 +423,7 @@ class DSSCompatFlags(IntFlag):
the current state of DSS objects.
Set this flag to disable this behavior, following the original OpenDSS implementation for potential
compatibility with older software that may require the original behavior; note that may lead to
errorneous interpretation of the data in the DSS properties. This was introduced in DSS C-API v0.14.0
erroneous interpretation of the data in the DSS properties. This was introduced in DSS C-API v0.14.0
and will be further developed for future versions.
"""

Expand Down Expand Up @@ -617,6 +617,48 @@ class SetterFlags(IntFlag):
"""


class DSSObjectFlags(IntFlag):
"""
Object flags are bit flags used by various of the internal processes of the DSS engine.
Most are internal state, but advanced/expert users can manipulate them for some interesting uses.
"""

Editing = 0x0001

HasBeenSaved = 0x0002

DefaultAndUnedited = 0x0004

Checked = 0x0008

Flag = 0x0010
"""General purpose flag for each object"""

HasEnergyMeter = 0x0020

HasSensorObj = 0x0040

IsIsolated = 0x0080

HasControl = 0x0100

IsMonitored = 0x0200
"""Indicates some control is monitoring this element"""

HasOCPDevice = 0x0400,
"""Fuse, Relay, or Recloser"""

HasAutoOCPDevice = 0x0800
"""Relay or Recloser only"""

NeedsRecalc = 0x1000
"""Used for Edit command loops"""

NeedsYPrim = 0x2000
"""Used for Edit command loops + setter flags"""


class GeneratorVariables(IntEnum):
"""
Generator variables
Expand Down Expand Up @@ -1015,6 +1057,7 @@ class VCCSNonRMSVariables(IntEnum):
'CoreType',
'DSSCompatFlags',
'DSSJSONFlags',
'DSSObjectFlags',
'DSSPropertyNameStyle',
'DSSSaveFlags',
'EnergyMeterRegisters',
Expand Down

0 comments on commit 2ffe0ca

Please sign in to comment.