cl::utfsm::acs::acg::core::ReductionManager Class Reference

Inheritance diagram for cl::utfsm::acs::acg::core::ReductionManager:
Inheritance graph
[legend]
Collaboration diagram for cl::utfsm::acs::acg::core::ReductionManager:
Collaboration graph
[legend]

List of all members.

Public Member Functions

List< ReductionRulegetNodeReductionRules ()
List< ReductionRulegetMultiReductionRules ()
void loadFromCDB ()
ReductionRule getNRParentByTriplet (String ff, String fm, int fc)
ReductionRule getMRParentByTriplet (String ff, String fm, int fc)
boolean deleteNodeReductionRule (Alarm p, Alarm c) throws IllegalOperationException
boolean deleteMultiReductionRule (Alarm p, Alarm c) throws IllegalOperationException
void addNodeReductionRule (Alarm p, Alarm c) throws IllegalOperationException, NullPointerException
void addMultiReductionRule (Alarm p, Alarm c) throws IllegalOperationException, NullPointerException
void updateMultiThreshold (Alarm p, int v) throws IllegalOperationException, NullPointerException
void saveToCDB ()

Static Public Member Functions

static ReductionManager getInstance (AlarmDAO alarmDAO)
static void destroy ()

Private Member Functions

 ReductionManager (AlarmDAO alarmDAO)
boolean deleteReductionRule (List< ReductionRule > rrL, ReductionRule rr, Alarm p, Alarm c)
void addReductionRule (List< ReductionRule > rrL, ReductionRule rr, Alarm p, Alarm c, boolean isNodeReductionRule) throws IllegalOperationException, NullPointerException

Private Attributes

List< ReductionRule_nodeReductionRules
List< ReductionRule_multiReductionRules
HashMap< String, ObjectState_objState
HashMap< String, ObjectState_thrState
AlarmDAO _alarmDAO

Static Private Attributes

static ReductionManager _instance

Detailed Description

Author:
rtobar

Constructor & Destructor Documentation

cl::utfsm::acs::acg::core::ReductionManager::ReductionManager ( AlarmDAO  alarmDAO  )  [inline, private]

Member Function Documentation

void cl::utfsm::acs::acg::core::ReductionManager::addMultiReductionRule ( Alarm  p,
Alarm  c 
) throws IllegalOperationException, NullPointerException [inline]
void cl::utfsm::acs::acg::core::ReductionManager::addNodeReductionRule ( Alarm  p,
Alarm  c 
) throws IllegalOperationException, NullPointerException [inline]
void cl::utfsm::acs::acg::core::ReductionManager::addReductionRule ( List< ReductionRule rrL,
ReductionRule  rr,
Alarm  p,
Alarm  c,
boolean  isNodeReductionRule 
) throws IllegalOperationException, NullPointerException [inline, private]

Adds a Reduction Rule

Parameters:
rrL List of Reduction Rules where the rule will be added (if it is null).
rr Reduction Rule to add to (if not null).
p Parent of the Rule to be added
c Child of the Rule to be added

References _objState, cl::utfsm::acs::acg::core::ObjectState::create(), and cl::utfsm::acs::acg::core::ObjectState::update().

Referenced by addMultiReductionRule(), and addNodeReductionRule().

boolean cl::utfsm::acs::acg::core::ReductionManager::deleteMultiReductionRule ( Alarm  p,
Alarm  c 
) throws IllegalOperationException [inline]

Deletes a Node Reduction Rule

Parameters:
p Parent of the Rule to be deleted
c Child of the Rule to be deleted

References _multiReductionRules, deleteReductionRule(), and getMRParentByTriplet().

Referenced by cl::utfsm::acs::acg::gui::ReductionsView::createMRParentWidgets(), and cl::utfsm::acs::acg::gui::ReductionsView::createViewWidgets().

boolean cl::utfsm::acs::acg::core::ReductionManager::deleteNodeReductionRule ( Alarm  p,
Alarm  c 
) throws IllegalOperationException [inline]

Deletes a Node Reduction Rule

Parameters:
p Parent of the Rule to be deleted
c Child of the Rule to be deleted

References _nodeReductionRules, deleteReductionRule(), and getNRParentByTriplet().

Referenced by cl::utfsm::acs::acg::gui::ReductionsView::createNRParentWidgets(), and cl::utfsm::acs::acg::gui::ReductionsView::createViewWidgets().

boolean cl::utfsm::acs::acg::core::ReductionManager::deleteReductionRule ( List< ReductionRule rrL,
ReductionRule  rr,
Alarm  p,
Alarm  c 
) [inline, private]
static void cl::utfsm::acs::acg::core::ReductionManager::destroy (  )  [inline, static]

Destroys the singleton instance of this class. This is needed to renew the internal reference to the AlarmDAO if a new connection to the DAL and the ACS Manager has been performed

References _instance.

static ReductionManager cl::utfsm::acs::acg::core::ReductionManager::getInstance ( AlarmDAO  alarmDAO  )  [inline, static]
ReductionRule cl::utfsm::acs::acg::core::ReductionManager::getMRParentByTriplet ( String  ff,
String  fm,
int  fc 
) [inline]
List<ReductionRule> cl::utfsm::acs::acg::core::ReductionManager::getMultiReductionRules (  )  [inline]
List<ReductionRule> cl::utfsm::acs::acg::core::ReductionManager::getNodeReductionRules (  )  [inline]
ReductionRule cl::utfsm::acs::acg::core::ReductionManager::getNRParentByTriplet ( String  ff,
String  fm,
int  fc 
) [inline]
void cl::utfsm::acs::acg::core::ReductionManager::loadFromCDB (  )  [inline]
void cl::utfsm::acs::acg::core::ReductionManager::saveToCDB (  )  [inline]

Performs a full save of the contents of the Manager to the CDB. All the modified contents of the CDB are updated, and replaced by the ones that are currently available on the EntityManager. Therefore, this call should be done with great care.

Implements cl::utfsm::acs::acg::core::EntityManager.

References _alarmDAO, _multiReductionRules, _nodeReductionRules, _objState, _thrState, cl::utfsm::acs::acg::core::ObjectState::getAction(), getMRParentByTriplet(), and cl::utfsm::acs::acg::core::ReductionRule::getThreshold().

Referenced by cl::utfsm::acs::acg::core::AlarmSystemManager::saveToCDB(), and cl::utfsm::acs::acg::core::ReductionManagerTest::testSaveToCDB().

void cl::utfsm::acs::acg::core::ReductionManager::updateMultiThreshold ( Alarm  p,
int  v 
) throws IllegalOperationException, NullPointerException [inline]

Member Data Documentation

The singleton instance shared across the project

Referenced by destroy(), and getInstance().


The documentation for this class was generated from the following file:

Generated by  doxygen 1.6.2