public interface IIdentifierDictionary
IIdentifierField
objects
that define the fields of an IIdentifier
.Modifier and Type | Method and Description |
---|---|
IIdentifierField |
getField(int index)
Get the
IIdentifierField at specified index. |
IIdentifierField |
getField(String fieldName)
Get a field by name.
|
int |
getFieldIndex(String fieldName)
Get the index of a named field.
|
List<IIdentifierField> |
getFieldList()
Get the list of fields.
|
List<String> |
getFieldNames()
Get the list of field names.
|
int |
getFieldValue(IIdentifier compact,
int idx)
Get the value of a field extracted from a packed id by index.
|
int |
getFieldValue(IIdentifier compact,
String field)
Get the value of a field extracted from a packed id by name.
|
int |
getMaxIndex()
Get the max index in the field array.
|
String |
getName()
Get the name of this dictionary.
|
int |
getNumberOfFields()
Get the number of fields in this dictionary.
|
boolean |
hasField(String fieldName)
True if this
IdentifierDictionary contains the field; false if not. |
boolean |
isValid(IExpandedIdentifier id)
Check whether an expanded identifier is valid for this dictionary.
|
IIdentifier |
pack(IExpandedIdentifier id)
Pack an expanded id .
|
IExpandedIdentifier |
unpack(IIdentifier compact)
Unpack a packed id into an expanded id.
|
IExpandedIdentifier |
unpack(IIdentifier compact,
List<Integer> indices)
Unpack id, only including fields with indices in list.
|
String getName()
IIdentifierField getField(String fieldName)
fieldName
- The field.boolean hasField(String fieldName)
IdentifierDictionary
contains the field; false if not.fieldName
- The name of the field.IIdentifierField getField(int index)
IIdentifierField
at specified index.index
in the field array.ArrayIndexOutOfBoundsException
- if the index is not in bounds.int getFieldIndex(String fieldName)
fieldName
- The name of the field.List<String> getFieldNames()
List<IIdentifierField> getFieldList()
int getNumberOfFields()
int getMaxIndex()
IIdentifier pack(IExpandedIdentifier id)
id
- The expanded id.IExpandedIdentifier unpack(IIdentifier compact)
compact
- The packed id.IExpandedIdentifier unpack(IIdentifier compact, List<Integer> indices)
compact
- The packed idindices
- The indices of the fields to unpack.int getFieldValue(IIdentifier compact, String field)
compact
- The packed id.field
- The field name.int getFieldValue(IIdentifier compact, int idx)
compact
- The packed id.field
- The field name.boolean isValid(IExpandedIdentifier id)
Copyright © 2016 Linear Collider Detector (LCD). All rights reserved.