2 #ifndef LSST_AFW_TABLE_Flag_h_INCLUDED 3 #define LSST_AFW_TABLE_Flag_h_INCLUDED 49 "Constructor disabled (this Field type is not sized).");
69 static bool const HAS_NAMED_SUBFIELDS =
false;
106 template <
typename OtherT>
110 template <
typename OtherT>
148 Key(
Key const &) =
default;
150 Key &operator=(
Key const &) =
default;
151 Key &operator=(
Key &&) =
default;
157 <<
", bit=" <<
key.getBit() <<
")";
165 Value getValue(
Element const *p, ndarray::Manager::Ptr
const &)
const {
166 return (*p) & (
Element(1) << _bit);
170 void setValue(
Element *p, ndarray::Manager::Ptr
const &,
Value v)
const {
178 explicit Key(
int offset,
int bit) : _offset(offset), _bit(bit) {}
189 struct hash<
lsst::afw::table::Key<lsst::afw::table::Flag>> {
196 #endif // !LSST_AFW_TABLE_Flag_h_INCLUDED Field base class default implementation (used for numeric scalars and lsst::geom::Angle).
Key()
Default construct a field.
bool Value
the type returned by BaseRecord::get
std::size_t hash_value() const noexcept
Return a hash of this object.
ItemVariant const * other
bool isValid() const
Return true if the key was initialized to valid offset.
A base class for image defects.
bool operator!=(Key< OtherT > const &other) const
Equality comparison.
static std::string getTypeString()
Return a string description of the field type.
int getBit() const
The index of this field's bit within the integer it shares with other Flag fields.
#define LSST_EXCEPT(type,...)
A base class for Key that allows subfield keys to be extracted for some field types.
bool operator==(Key const &other) const
Equality comparison.
Base class for all records.
A class used as a handle to a particular field in a table.
size_t operator()(argument_type const &obj) const noexcept
int getElementCount() const
Return the number of subfield elements (always one for scalars).
void stream(std::ostream &os) const
Defines how fields are printed.
bool operator==(Key< OtherT > const &other) const
Equality comparison.
std::size_t hashCombine(std::size_t seed) noexcept
int getOffset() const
Return the offset in bytes of the integer element that holds this field's bit.
static std::string getTypeString()
Return a string description of the field type.
std::int64_t Element
the actual storage type (shared by multiple flag fields)
bool operator!=(Key const &other) const
Equality comparison.