2 #ifndef AFW_TABLE_AliasMap_h_INCLUDED
3 #define AFW_TABLE_AliasMap_h_INCLUDED
8 namespace lsst {
namespace afw {
namespace table {
35 typedef std::map<std::string,std::string>
Internal;
49 typedef std::map<std::string,std::string>::const_iterator
Iterator;
79 std::string
apply(std::string
const &
name)
const;
88 std::string
get(std::string
const & alias)
const;
91 void set(std::string
const & alias, std::string
const & target);
98 bool erase(std::string
const & alias);
130 #endif // !AFW_TABLE_AliasMap_h_INCLUDED
Defines the fields and offsets for a table.
A proxy type for name lookups in a Schema.
table::Key< std::string > name
bool contains(AliasMap const &other) const
Return true if all aliases in this are also in other (with the same targets).
Mapping class that holds aliases for a Schema.
bool operator!=(AliasMap const &other) const
Iterator begin() const
Return a iterator to the beginning of the map.
AliasMap(AliasMap const &other)
bool empty() const
Return the true if there are no aliases.
bool erase(std::string const &alias)
Remove an alias from the schema if it is present.
void _apply(std::string &name) const
std::string apply(std::string const &name) const
bool operator==(AliasMap const &other) const
std::map< std::string, std::string >::const_iterator Iterator
An iterator over alias->target pairs.
std::size_t size() const
Return the number of aliases.
std::map< std::string, std::string > Internal
void set(std::string const &alias, std::string const &target)
Add an alias to the schema or replace an existing one.
Iterator end() const
Return a iterator to one past the end of the map.
Base class for all tables.