Removing package directories.
[PyCIM.git] / CIM14 / IEC61970 / StateVariables / SvShuntCompensatorSections.py
blob9b8c57e7df62a2ced9d1fa6392fb75adff5eb9d2
1 # Copyright (C) 2010 Richard Lincoln
3 # This library is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU Lesser General Public
5 # License as published by the Free Software Foundation; either
6 # version 2.1 of the License, or (at your option) any later version.
8 # This library is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 # Lesser General Public License for more details.
13 # You should have received a copy of the GNU Lesser General Public
14 # License along with this library; if not, write to the Free Software
15 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA, USA
17 from CIM14.IEC61970.StateVariables.StateVariable import StateVariable
19 class SvShuntCompensatorSections(StateVariable):
20 """State variable for the number of sections in service for a shunt compensator.
21 """
23 def __init__(self, continuousSections=0.0, sections=0, ShuntCompensator=None, *args, **kw_args):
24 """Initialises a new 'SvShuntCompensatorSections' instance.
26 @param continuousSections: The number of sections in service as a continous variable.
27 @param sections: The number of sections in service.
28 @param ShuntCompensator: The shunt compensator for which the state applies.
29 """
30 #: The number of sections in service as a continous variable.
31 self.continuousSections = continuousSections
33 #: The number of sections in service.
34 self.sections = sections
36 self._ShuntCompensator = None
37 self.ShuntCompensator = ShuntCompensator
39 super(SvShuntCompensatorSections, self).__init__(*args, **kw_args)
41 _attrs = ["continuousSections", "sections"]
42 _attr_types = {"continuousSections": float, "sections": int}
43 _defaults = {"continuousSections": 0.0, "sections": 0}
44 _enums = {}
45 _refs = ["ShuntCompensator"]
46 _many_refs = []
48 def getShuntCompensator(self):
49 """The shunt compensator for which the state applies.
50 """
51 return self._ShuntCompensator
53 def setShuntCompensator(self, value):
54 if self._ShuntCompensator is not None:
55 self._ShuntCompensator._SvShuntCompensatorSections = None
57 self._ShuntCompensator = value
58 if self._ShuntCompensator is not None:
59 self._ShuntCompensator._SvShuntCompensatorSections = self
61 ShuntCompensator = property(getShuntCompensator, setShuntCompensator)