std::size_t size() const
return the current size (number of defined elements) of the collection
Defines the fields and offsets for a table.
A proxy type for name lookups in a Schema.
std::string join(std::string const &a, std::string const &b) const
Join strings using the field delimiter appropriate for this Schema.
Simple class used to define and document flags The name and doc constitute the identity of the FlagDe...
Exception to be thrown when a measurement algorithm experiences a known failure mode.
FlagDefinition addFailureFlag(std::string const &doc="General Failure Flag")
Add a Flag Defintion to act as a "General" failure flag This flag will be set if a Measurement error ...
static constexpr std::size_t number_undefined
Utility class for handling flag fields that indicate the failure modes of an algorithm.
A base class for image defects.
std::size_t failureFlagNumber
FlagHandler()
Each error should have a corresponding static FlagDefinition object.
bool hasDefinition(std::string const &name) const
See if there is a FlagDefinition with specified name.
FlagDefinition add(std::string const &name, std::string const &doc)
Add a new FlagDefinition to this list.
static FlagHandler addFields(afw::table::Schema &schema, std::string const &prefix, FlagDefinitionList const &flagDefs, FlagDefinitionList const &exclDefs=FlagDefinitionList::getEmptyList())
Add Flag fields to a schema, creating a FlagHandler object to manage them.
static std::string const & getFailureFlagName()
Define the universal name of the general failure flag.
Base class for all records.
std::size_t getFlagBit() const
Return the flag bit associated with the error.
void handleFailure(afw::table::BaseRecord &record, MeasurementError const *error=nullptr) const
Handle an expected or unexpected Exception thrown by a measurement algorithm.
void set(Key< T > const &key, U const &value)
Set value of a field for the given key.
vector-type utility class to build a collection of FlagDefinitions
Key< T > addField(Field< T > const &field, bool doReplace=false)
Add a new field to the Schema, and return the associated Key.