public static class EcalChannel.EcalChannelCollection extends BaseConditionsObjectCollection<EcalChannel>
EcalChannel
objects.Modifier and Type | Class and Description |
---|---|
(package private) class |
EcalChannel.EcalChannelCollection.ChannelIdComparator
Comparison of ECAL channel objects.
|
Modifier and Type | Field and Description |
---|---|
private Map<Long,EcalChannel> |
channelMap
Map of
#ChannelId to channel object. |
private Map<Long,EcalChannel> |
daqMap
Map of
#DaqId to channel object. |
private Map<Long,EcalChannel> |
geometryMap
Map of
#GeometryId to channel object. |
Constructor and Description |
---|
EcalChannelCollection() |
Modifier and Type | Method and Description |
---|---|
boolean |
add(EcalChannel channel)
Add an
EcalChannel to the collection and cache its ID information. |
(package private) void |
buildGeometryMap(org.lcsim.detector.identifier.IIdentifierHelper helper,
int system)
Build the map of
#GeometryId objects. |
EcalChannel |
findChannel(EcalChannel.ChannelId channelId)
Find a channel by its channel ID.
|
EcalChannel |
findChannel(EcalChannel.DaqId daqId)
Find a channel by using DAQ information.
|
EcalChannel |
findChannel(EcalChannel.GeometryId geometryId)
Find a channel by using its physical ID information.
|
EcalChannel |
findChannel(long id)
Find a channel by its encoded channel ID.
|
EcalChannel |
findDaq(long id)
Find a channel by its encoded DAQ ID.
|
EcalChannel |
findGeometric(long id)
Find a channel by its encoded geometric ID.
|
ConditionsObjectCollection<EcalChannel> |
sorted()
Sort collection and return but do not sort in place.
|
addAll, clear, contains, delete, get, getCollectionId, getObjects, getTableMetaData, insert, isNew, iterator, loadCsv, select, setCollectionId, setConnection, setTableMetaData, size, sort, sorted, toString, update, writeCsv
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
forEach, spliterator
private final Map<Long,EcalChannel> channelMap
#ChannelId
to channel object.private final Map<Long,EcalChannel> daqMap
#DaqId
to channel object.private final Map<Long,EcalChannel> geometryMap
#GeometryId
to channel object.public boolean add(EcalChannel channel) throws ConditionsObjectException
EcalChannel
to the collection and cache its ID information. The GeometryId must be
created later as it requires access to the Detector API.add
in interface ConditionsObjectCollection<EcalChannel>
add
in class BaseConditionsObjectCollection<EcalChannel>
channel
- the ECAL channel objecttrue
if object was added successfullyConditionsObjectException
- if there was an error adding the objectvoid buildGeometryMap(org.lcsim.detector.identifier.IIdentifierHelper helper, int system)
#GeometryId
objects.helper
- the ID helper of the subdetectorsystem
- the system ID of the subdetectorpublic EcalChannel findChannel(EcalChannel.ChannelId channelId)
channelId
- the channel ID objectnull
if does not existpublic EcalChannel findChannel(EcalChannel.DaqId daqId)
daqId
- the DAQ ID objectnull
if does not exist.public EcalChannel findChannel(EcalChannel.GeometryId geometryId)
geometryId
- the geometric ID objectnull
if does not existpublic EcalChannel findChannel(long id)
id
- the encoded channel IDnull
if does not existpublic EcalChannel findDaq(long id)
id
- the encoded DAQ IDnull
if does not existpublic EcalChannel findGeometric(long id)
id
- the encoded geometric IDnull
if does not existpublic ConditionsObjectCollection<EcalChannel> sorted()
Copyright © 2019. All rights reserved.