2 #ifndef AFW_TABLE_Field_h_INCLUDED
3 #define AFW_TABLE_Field_h_INCLUDED
9 namespace lsst {
namespace afw {
namespace table {
47 std::string
const &
name,
48 std::string
const & doc,
49 std::string
const & units =
"",
70 std::string
const & name,
71 std::string
const & doc,
80 std::string
const & name,
81 std::string
const & doc,
82 std::string
const & units,
86 std::string
const & name,
87 std::string
const & doc,
102 inline friend std::ostream & operator<<(std::ostream & os, Field<T>
const &
field) {
104 <<
"'](name=\"" <<
field.getName() <<
"\"";
105 if (!
field.getDoc().empty())
106 os <<
", doc=\"" <<
field.getDoc() <<
"\"";
107 if (!
field.getUnits().empty())
108 os <<
", units=\"" <<
field.getUnits() <<
"\"";
126 #endif // !AFW_TABLE_Field_h_INCLUDED
Field< T > copyRenamed(std::string const &newName) const
Return a new Field with a new name and other properties the same as this.
std::string const & getName() const
Return the name of the field.
Field base class default implementation (used for numeric scalars and Angle).
std::string const & getDoc() const
Return the documentation for the field.
table::Key< std::string > name
std::string const & getUnits() const
Return the units for the field.
static std::string getTypeString()
Return a string description of the field type.
T Element
the type of subfields (the same as the type itself for scalars)
A description of a field in a table.
Field(std::string const &name, std::string const &doc, std::string const &units="", FieldBase< T > const &size=FieldBase< T >())
Construct a new field.
FieldBase< T >::Element Element
Type used to store field data in the table (a field may have multiple elements).
Field(std::string const &name, std::string const &doc, FieldBase< T > const &size)
Construct a new field.