objectclasses::SpareHWType Class Reference

Inheritance diagram for objectclasses::SpareHWType:

objectclasses::DBInfo cdbVisCore::dbUpdate

List of all members.


Detailed Description

There are several device types, and each device is of only one device type. A device type contains information that is common for devices of the same type. It is not a physical object itself.

Definition at line 4718 of file objectclasses.py.


Public Member Functions

def __init__
def GetName
def GetPortsIn
def GetPortsOut
def GetDescription
def GetSystem
def GetColour
def GetErrorMessage
def SetErrorMessage
def SetName
def SetPortsIn
def SetPortsOut
def SetDescription
def SetColour
def SetSystem
def SetDict
def SetSaveStatus
def SetDictInfo
def GetObjectInfo
def Update
def GetHWSparesByLocation
def GetSpareDevices
def Delete
def Modify
def Create

Private Attributes

 __errormessage
 __SpareHWTypeInfo
 __devices
 __cfg
 _deviceTypeInfo

Member Function Documentation

def objectclasses::SpareHWType::__init__ (   self,
  hwType = "",
  new = True 
)

Constructor.

Parameters: - name of the subsystem(s) the device type is available in - device type name set by the user; which identifies a device type - if True, this device type is newly created, not stored in ConfDB yet if False, this is a device type that is already created, and hence we can retrieve information for the object from ConfDB or dirty objects list. That is done by calling the Update(...) function in the constructor.

Definition at line 4731 of file objectclasses.py.

def objectclasses::SpareHWType::GetName (   self  ) 

Definition at line 4753 of file objectclasses.py.

def objectclasses::SpareHWType::GetPortsIn (   self  ) 

Definition at line 4755 of file objectclasses.py.

def objectclasses::SpareHWType::GetPortsOut (   self  ) 

Definition at line 4757 of file objectclasses.py.

def objectclasses::SpareHWType::GetDescription (   self  ) 

Definition at line 4759 of file objectclasses.py.

def objectclasses::SpareHWType::GetSystem (   self  ) 

Definition at line 4761 of file objectclasses.py.

def objectclasses::SpareHWType::GetColour (   self  ) 

Definition at line 4763 of file objectclasses.py.

def objectclasses::SpareHWType::GetErrorMessage (   self  ) 

Get the error message that was set most recently.

!return - the error message string

Reimplemented from objectclasses::DBInfo.

Definition at line 4765 of file objectclasses.py.

def objectclasses::SpareHWType::SetErrorMessage (   self,
  msg 
)

Set the error message so that it can be looked up. - the message string

Reimplemented from objectclasses::DBInfo.

Definition at line 4769 of file objectclasses.py.

def objectclasses::SpareHWType::SetName (   self,
  name 
)

Definition at line 4771 of file objectclasses.py.

def objectclasses::SpareHWType::SetPortsIn (   self,
  nbr 
)

Definition at line 4774 of file objectclasses.py.

def objectclasses::SpareHWType::SetPortsOut (   self,
  nbr 
)

Definition at line 4777 of file objectclasses.py.

def objectclasses::SpareHWType::SetDescription (   self,
  descr 
)

Definition at line 4780 of file objectclasses.py.

def objectclasses::SpareHWType::SetColour (   self,
  colour 
)

Definition at line 4783 of file objectclasses.py.

def objectclasses::SpareHWType::SetSystem (   self,
  name 
)

Definition at line 4786 of file objectclasses.py.

def objectclasses::SpareHWType::SetDict (   self,
  newdict 
)

Definition at line 4790 of file objectclasses.py.

def objectclasses::SpareHWType::SetSaveStatus (   self,
  status 
)

Definition at line 4796 of file objectclasses.py.

def objectclasses::SpareHWType::SetDictInfo (   self,
  dict 
)

Definition at line 4798 of file objectclasses.py.

def objectclasses::SpareHWType::GetObjectInfo (   self,
  doNotLookUp = True 
)

Get all info about a device type in a subsystem, when given the name of a device type in the constructor. Here we can set up to check different statuses (TODO), f.ex. if it is the most recent version of an object; then just return the contents; else look in dl and db.

- whether we should look for more recent information in dirty objects list or ConfDB.

!return - a dictionary with all the parameters set.

Definition at line 4813 of file objectclasses.py.

def objectclasses::SpareHWType::Update (   self,
  doNotCheckInDirtyList = False 
)

Check first in dirty objects list for most recent version of this object; if in creation mode. If in navigation mode or alredy looked in dirty objects list and not found; check in ConfDB.

- if True, we skip the check in the dirty list, else we check. But only in creation mode

!return - a dictionary with all the parameters set.

Definition at line 4829 of file objectclasses.py.

def objectclasses::SpareHWType::GetHWSparesByLocation (   self,
  location_string 
)

General get a device at a given location. TODO: should also be moved to SubSystem class. NB! This function does not look for devices that are not yet stored in the ConfDB.

- the location string which looks for devices with the same location string set.

Definition at line 4901 of file objectclasses.py.

def objectclasses::SpareHWType::GetSpareDevices (   self  ) 

Get all _sparedevice_names_ for a given device type; each device name is unique. Looks both in dirty objects list and ConfDB.

!Return - list of device names; both in db and in dirtylist

Definition at line 4930 of file objectclasses.py.

def objectclasses::SpareHWType::Delete (   self  ) 

Delete this object. This object is put in the dirty list and set for deletion. Sets the save status to deletion.

Reimplemented from objectclasses::DBInfo.

Definition at line 5019 of file objectclasses.py.

def objectclasses::SpareHWType::Modify (   self  ) 

Modifies a device type with new values set by the user through the set functions. The modify status is set through SetModifyStatus(...) if needed. Sets the save status to modify, and adds the object to the dirty objects list.

Reimplemented from objectclasses::DBInfo.

Definition at line 5029 of file objectclasses.py.

def objectclasses::SpareHWType::Create (   self  ) 

Create a device type. Set save status to creation, and adds the object to the dirty objects list.

Reimplemented from objectclasses::DBInfo.

Definition at line 5037 of file objectclasses.py.


Member Data Documentation

objectclasses::SpareHWType::__errormessage [private]

Reimplemented from objectclasses::DBInfo.

Definition at line 4732 of file objectclasses.py.

objectclasses::SpareHWType::__SpareHWTypeInfo [private]

Definition at line 4733 of file objectclasses.py.

objectclasses::SpareHWType::__devices [private]

Definition at line 4742 of file objectclasses.py.

objectclasses::SpareHWType::__cfg [private]

Definition at line 4746 of file objectclasses.py.

objectclasses::SpareHWType::_deviceTypeInfo [private]

Definition at line 4871 of file objectclasses.py.


The documentation for this class was generated from the following file:
Generated on Fri Aug 31 11:11:20 2007 for CDBVis by  doxygen 1.5.3