Package org.jlab.detector.swaps
Class SwapManager
java.lang.Object
org.jlab.detector.swaps.SwapManager
Cache manager for cable swaps across multiple run numbers and CCDB tables,
 interpreted from two ConstantsManager instances, implemented to enable
 transforming a decoded HIPO file's sector/layer/component/order from the
 translation tables used at decoding time into a different one.
- Author:
- baltzell
- 
Field SummaryFields
- 
Constructor SummaryConstructorsConstructorDescriptionSwapManager(List<String> detectorNames, String prevTimestamp, String currTimestamp) SwapManager(List<String> detectorNames, ConstantsManager previous, ConstantsManager current) 
- 
Method SummaryModifier and TypeMethodDescriptionint[]intint[]int[]static SwapManagervoidinitialize(List<String> detectorNames, String prevTimestamp, String currTimestamp) voidinitialize(List<String> detectorNames, ConstantsManager previous, ConstantsManager current) static voidtoString()
- 
Field Details- 
DEF_CURRENT_CCDB_VARIATION- See Also:
 
- 
DEF_PREVIOUS_CCDB_VARIATION- See Also:
 
- 
DEF_DETECTOR_NAMES
 
- 
- 
Constructor Details- 
SwapManager- Parameters:
- detectorNames-
- prevTimestamp- in CCDB format: MM/DD/YYYY
- currTimestamp- in CCDB format: MM/DD/YYYY
 
- 
SwapManager- Parameters:
- detectorNames-
- previous- timestamp/variation used for translation tables during decoding
- current- timestamp/variation with correct translation tables
 
 
- 
- 
Method Details- 
getDetectors
- 
getTable
- 
getBanks
- 
getInstance
- 
initialize- Parameters:
- detectorNames-
- prevTimestamp- in CCDB format: MM/DD/YYYY
- currTimestamp- in CCDB format: MM/DD/YYYY
 
- 
initializepublic void initialize(List<String> detectorNames, ConstantsManager previous, ConstantsManager current) - Parameters:
- detectorNames-
- previous- timestamp/variation used for translation tables during decoding
- current- timestamp/variation with correct translation tables
 
- 
get- Parameters:
- run- run number
- tableName- CCDB translation table name, e.g. "/dat/tt/ecal"
- slco- array of old indices (sector,layer,component,order)
- Returns:
- array of new table indices (sector/layer/component/order)
 
- 
get- Parameters:
- run- run number
- tableName- CCDB translation table name, e.g. "/daq/tt/ecal"
- varName- name of new index to retrieve (sector/layer/component/order)
- slco- array of old indices (sector/layer/component/order)
- Returns:
- new value of the requested index (sector/layer/component/order)
 
- 
get- Parameters:
- run- run number
- bank- ADC/TDC bank
- row- row index in bank
- Returns:
- array of new table indices (sector/layer/component/order)
 
- 
get- Parameters:
- event- the HIPO event
- bankName- name of ADC/TDC bank
- row- row index in bank
- Returns:
- array of new table indices (sector/layer/component/order)
 
- 
toString
- 
main
 
-