Public Member Functions | |
Category | getDefaultCategory () |
ACSCategoryDAOImpl (Logger log, com.cosylab.acs.laser.dao.ACSAlarmDAOImpl alarmDAO) | |
Category | findCategory (Integer identifier) |
Category | getCategory (Integer identifier) |
Category | findByCategoryTreeRoot () |
Category | findBySurveillanceCategory () |
Category[] | findAllCategories () |
Category | findCategoryByPath (String path) |
Category | getCategoryByPathInitialized (String path) |
Category | getCategoryByPath (String path) |
void | saveCategory (Category category) |
void | updateCategory (Category category) |
void | deleteCategory (Category category) |
String[] | getAlarms (Integer categoryId) |
Integer[] | getChildren (Integer parentId) |
alma.acs.alarmsystem.generated.Category[] | loadCategories () throws Exception |
void | linkWithAlarms () |
void | flushCategory () |
void | setConfAccessor (ConfigurationAccessor conf) |
void | setCategoryTreeRoot (String categoryTreeRoot) |
void | setSurveillanceCategoryPath (String surveillanceCategoryPath) |
Integer[] | getAllCategoryIDs () |
Categories | getCategories () |
void | flushCategories (Categories cats) |
void | addCategory (Categories cats, alma.acs.alarmsystem.generated.Category cat) |
void | updateCategory (Categories cats, alma.acs.alarmsystem.generated.Category cat) |
void | deleteCategory (Categories cats, alma.acs.alarmsystem.generated.Category cat) |
Package Attributes | |
int | nextCatID = 1 |
AlarmDAO | alarmDao |
ConfigurationAccessor | conf |
HashMap< String, Category > | catPathToCategory = new HashMap<String, Category>() |
HashMap< Integer, Category > | categories = new HashMap<Integer, Category>() |
String | surveillanceCategoryPath |
String | categoryTreeRoot |
Logger | logger |
cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.ACSCategoryDAOImpl | ( | Logger | log, | |
com.cosylab.acs.laser.dao.ACSAlarmDAOImpl | alarmDAO | |||
) |
Constructor
log | The log (not null) |
References cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.alarmDao, and cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.logger.
void cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.addCategory | ( | Categories | cats, | |
alma.acs.alarmsystem.generated.Category | cat | |||
) |
void cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.deleteCategory | ( | Category | category | ) |
void cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.deleteCategory | ( | Categories | cats, | |
alma.acs.alarmsystem.generated.Category | cat | |||
) |
Category [] cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.findAllCategories | ( | ) |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
References cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.categories.
Category cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.findByCategoryTreeRoot | ( | ) |
Category cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.findBySurveillanceCategory | ( | ) |
Category cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.findCategory | ( | Integer | identifier | ) |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
References cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getCategory().
Category cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.findCategoryByPath | ( | String | path | ) |
void cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.flushCategories | ( | Categories | cats | ) |
References cl.utfsm.acs.acg.dao.ConfigurationAccessor.addConfiguration(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.conf, com.cosylab.acs.laser.dao.ConfigurationAccessor.deleteConfiguration(), com.cosylab.acs.laser.dao.ConfigurationAccessor.isWriteable(), org.exolab.castor.xml.Marshaller.marshal(), org.exolab.castor.core.exceptions.CastorException.printStackTrace(), and org.exolab.castor.xml.Marshaller.setValidation().
void cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.flushCategory | ( | ) |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
References cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.alarmDao, cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.catPathToCategory, cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.conf, cern.laser.business.dao.AlarmDAO.getAlarm(), cern.laser.business.data.CategoryImpl.getAlarmIds(), cern.laser.business.data.CategoryImpl.getDescription(), cern.laser.business.data.Triplet.getFaultCode(), cern.laser.business.data.Triplet.getFaultFamily(), cern.laser.business.data.Triplet.getFaultMember(), cern.laser.business.data.CategoryImpl.getPath(), cern.laser.business.data.Alarm.getTriplet(), com.cosylab.acs.laser.dao.ConfigurationAccessor.isWriteable(), and com.cosylab.acs.laser.dao.ConfigurationAccessor.setConfiguration().
String [] cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getAlarms | ( | Integer | categoryId | ) |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
References cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getCategory().
Integer [] cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getAllCategoryIDs | ( | ) |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
Categories cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getCategories | ( | ) |
References cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.conf, com.cosylab.acs.laser.dao.ConfigurationAccessor.getConfiguration(), com.cosylab.acs.laser.dao.ConfigurationAccessor.isWriteable(), org.exolab.castor.core.exceptions.CastorException.printStackTrace(), org.exolab.castor.xml.Unmarshaller.setValidation(), and org.exolab.castor.xml.Unmarshaller.unmarshal().
Category cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getCategory | ( | Integer | identifier | ) |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
References cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.categories.
Referenced by cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.findCategory(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getAlarms(), and cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getChildren().
Category cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getCategoryByPath | ( | String | path | ) |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
References cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.catPathToCategory.
Referenced by cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.findCategoryByPath(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getCategoryByPathInitialized(), and cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.linkWithAlarms().
Category cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getCategoryByPathInitialized | ( | String | path | ) |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
References cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getCategoryByPath().
Integer [] cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getChildren | ( | Integer | parentId | ) |
Category cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getDefaultCategory | ( | ) |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
void cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.linkWithAlarms | ( | ) |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
References cern.laser.business.data.CategoryImpl.addChildCategory(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.alarmDao, cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.catPathToCategory, cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.conf, cern.laser.business.dao.AlarmDAO.getAlarm(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getCategoryByPath(), com.cosylab.acs.laser.dao.ConfigurationAccessor.getConfiguration(), and cern.laser.business.data.CategoryImpl.getPath().
alma.acs.alarmsystem.generated.Category [] cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.loadCategories | ( | ) | throws Exception |
Load the categories from the CDB.
Loads all the category from the CDB and build an internal representation of category. The category is also added to all the alarms having the fault family specified in the XML.
All the categories derive from ROOT that is built here as default (in this way the user does ot need to add the ROOT entry in the CDB).
Exception | In case of error reading the values from the CDB |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
References cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.categories, cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.catPathToCategory, cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.conf, cern.laser.business.data.CategoryImpl.getCategoryId(), com.cosylab.acs.laser.dao.ConfigurationAccessor.getConfiguration(), cern.laser.business.data.CategoryImpl.getName(), cern.laser.business.data.Category.getPath(), cern.laser.business.data.CategoryImpl.getPath(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.logger, cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.nextCatID, cern.laser.business.data.CategoryImpl.setAlarmIds(), cern.laser.business.data.CategoryImpl.setCategoryId(), cern.laser.business.data.CategoryImpl.setChildrenIds(), cern.laser.business.data.CategoryImpl.setDescription(), cern.laser.business.data.CategoryImpl.setName(), cern.laser.business.data.CategoryImpl.setPath(), org.exolab.castor.xml.Unmarshaller.setValidation(), org.exolab.castor.xml.Unmarshaller.setWhitespacePreserve(), and org.exolab.castor.xml.Unmarshaller.unmarshal().
void cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.saveCategory | ( | Category | category | ) |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
References cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.categories, cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.catPathToCategory, cern.laser.business.data.CategoryImpl.getCategoryId(), cern.laser.business.data.CategoryImpl.getPath(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.nextCatID, and cern.laser.business.data.CategoryImpl.setCategoryId().
void cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.setCategoryTreeRoot | ( | String | categoryTreeRoot | ) |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
void cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.setConfAccessor | ( | ConfigurationAccessor | conf | ) |
void cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.setSurveillanceCategoryPath | ( | String | surveillanceCategoryPath | ) |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
void cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.updateCategory | ( | Category | category | ) |
void cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.updateCategory | ( | Categories | cats, | |
alma.acs.alarmsystem.generated.Category | cat | |||
) |
HashMap<Integer, Category> cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.categories = new HashMap<Integer, Category>() [package] |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
Referenced by cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.deleteCategory(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.findAllCategories(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getCategory(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getChildren(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.loadCategories(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.saveCategory(), and cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.updateCategory().
String cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.categoryTreeRoot [package] |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
Referenced by cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.findByCategoryTreeRoot().
HashMap<String, Category> cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.catPathToCategory = new HashMap<String, Category>() [package] |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
Referenced by cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.deleteCategory(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.flushCategory(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getCategoryByPath(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.linkWithAlarms(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.loadCategories(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.saveCategory(), and cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.updateCategory().
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
Referenced by cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.flushCategories(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.flushCategory(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.getCategories(), cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.linkWithAlarms(), and cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.loadCategories().
Logger cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.logger [package] |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
Referenced by cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.ACSCategoryDAOImpl(), and cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.loadCategories().
int cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.nextCatID = 1 [package] |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
Referenced by cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.loadCategories(), and cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.saveCategory().
String cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.surveillanceCategoryPath [package] |
Reimplemented from com.cosylab.acs.laser.dao.ACSCategoryDAOImpl.
Referenced by cl.utfsm.acs.acg.dao.ACSCategoryDAOImpl.findBySurveillanceCategory().