Rosetta
Public Types | Public Member Functions | Private Attributes | Friends | List of all members
utility::keys::VariantKey< K > Class Template Reference

Variant key class. More...

#include <VariantKey.hh>

Public Types

typedef K key_type
 
typedef K::index_type index_type
 
typedef K Key
 
typedef K::Index Index
 

Public Member Functions

 VariantKey ()
 Default constructor. More...
 
 VariantKey (VariantKey const &var)
 Copy constructor. More...
 
 VariantKey (Key const &key_a)
 Key constructor. More...
 
 ~VariantKey () throw ()
 Destructor. More...
 
VariantKeyoperator= (VariantKey const &var)
 Copy assignment. More...
 
 operator Key const & () const
 Key conversion. More...
 
 operator Key & ()
 Key conversion. More...
 
std::string const & id () const
 ID. More...
 
std::string & id ()
 ID. More...
 
VariantKeyid (std::string const &id_a)
 ID assignment. More...
 
std::string const & identifier () const
 Identifier. More...
 
std::string & identifier ()
 Identifier. More...
 
VariantKeyidentifier (std::string const &identifier_a)
 Identifier assignment. More...
 
std::string const & code () const
 Code. More...
 
std::string & code ()
 Code. More...
 
VariantKeycode (std::string const &code_a)
 Code assignment. More...
 
Index private_index () const
 Index. More...
 
Key const & operator() () const
 Key. More...
 
Keyoperator() ()
 Key. More...
 

Private Attributes

Keykey_p_
 Pointer to key. More...
 

Friends

bool operator== (VariantKey const &a, VariantKey const &b)
 VariantKey == VariantKey. More...
 
bool operator!= (VariantKey const &a, VariantKey const &b)
 VariantKey != VariantKey. More...
 
bool operator< (VariantKey const &a, VariantKey const &b)
 VariantKey < VariantKey. More...
 

Detailed Description

template<typename K>
class utility::keys::VariantKey< K >

Variant key class.

Member Typedef Documentation

◆ Index

template<typename K >
typedef K::Index utility::keys::VariantKey< K >::Index

◆ index_type

template<typename K >
typedef K::index_type utility::keys::VariantKey< K >::index_type

◆ Key

template<typename K >
typedef K utility::keys::VariantKey< K >::Key

◆ key_type

template<typename K >
typedef K utility::keys::VariantKey< K >::key_type

Constructor & Destructor Documentation

◆ VariantKey() [1/3]

template<typename K >
utility::keys::VariantKey< K >::VariantKey ( )
inline

Default constructor.

◆ VariantKey() [2/3]

template<typename K >
utility::keys::VariantKey< K >::VariantKey ( VariantKey< K > const &  var)
inline

Copy constructor.

◆ VariantKey() [3/3]

template<typename K >
utility::keys::VariantKey< K >::VariantKey ( Key const &  key_a)
inline

Key constructor.

◆ ~VariantKey()

template<typename K >
utility::keys::VariantKey< K >::~VariantKey ( )
throw (
)
inline

Destructor.

References utility::keys::VariantKey< K >::key_p_.

Member Function Documentation

◆ code() [1/3]

template<typename K >
std::string& utility::keys::VariantKey< K >::code ( )
inline

◆ code() [2/3]

template<typename K >
std::string const& utility::keys::VariantKey< K >::code ( ) const
inline

◆ code() [3/3]

template<typename K >
VariantKey& utility::keys::VariantKey< K >::code ( std::string const &  code_a)
inline

Code assignment.

References debug_assert, and utility::keys::VariantKey< K >::key_p_.

◆ id() [1/3]

template<typename K >
std::string& utility::keys::VariantKey< K >::id ( )
inline

◆ id() [2/3]

template<typename K >
std::string const& utility::keys::VariantKey< K >::id ( ) const
inline

◆ id() [3/3]

template<typename K >
VariantKey& utility::keys::VariantKey< K >::id ( std::string const &  id_a)
inline

ID assignment.

References debug_assert, and utility::keys::VariantKey< K >::key_p_.

Referenced by schema.Job::__repr__().

◆ identifier() [1/3]

template<typename K >
std::string& utility::keys::VariantKey< K >::identifier ( )
inline

◆ identifier() [2/3]

template<typename K >
std::string const& utility::keys::VariantKey< K >::identifier ( ) const
inline

◆ identifier() [3/3]

template<typename K >
VariantKey& utility::keys::VariantKey< K >::identifier ( std::string const &  identifier_a)
inline

Identifier assignment.

References debug_assert, and utility::keys::VariantKey< K >::key_p_.

◆ operator Key &()

template<typename K >
utility::keys::VariantKey< K >::operator Key & ( )
inline

◆ operator Key const &()

template<typename K >
utility::keys::VariantKey< K >::operator Key const & ( ) const
inline

◆ operator()() [1/2]

template<typename K >
Key& utility::keys::VariantKey< K >::operator() ( )
inline

◆ operator()() [2/2]

template<typename K >
Key const& utility::keys::VariantKey< K >::operator() ( ) const
inline

◆ operator=()

template<typename K >
VariantKey& utility::keys::VariantKey< K >::operator= ( VariantKey< K > const &  var)
inline

Copy assignment.

References utility::keys::VariantKey< K >::key_p_.

◆ private_index()

template<typename K >
Index utility::keys::VariantKey< K >::private_index ( ) const
inline

Index.

Note
Only for use as an optimization: DO NOT WRITE CODE DEPENDING ON THE SPECIFIC INDEX VALUE!

References debug_assert, and utility::keys::VariantKey< K >::key_p_.

Friends And Related Function Documentation

◆ operator!=

template<typename K >
bool operator!= ( VariantKey< K > const &  a,
VariantKey< K > const &  b 
)
friend

◆ operator<

template<typename K >
bool operator< ( VariantKey< K > const &  a,
VariantKey< K > const &  b 
)
friend

◆ operator==

template<typename K >
bool operator== ( VariantKey< K > const &  a,
VariantKey< K > const &  b 
)
friend

Member Data Documentation

◆ key_p_

template<typename K >
Key* utility::keys::VariantKey< K >::key_p_
private

The documentation for this class was generated from the following files: