casacore
Public Member Functions | Private Types | Private Attributes | List of all members
casacore::OrderedPair< K, V > Class Template Reference

More...

#include <OrderedPair.h>

Public Member Functions

 OrderedPair ()
 Needed for "operator>>(AipsIO &ios, Slist<elem> &list)". More...
 
 OrderedPair (const K &k, const V &v)
 This is the "standard" constructor which takes a key and a value and constructs an ordered pair. More...
 
 OrderedPair (const OrderedPair< K, V > &that)
 Copy constructor (copy semantics). More...
 
OrderedPair< K, V > & operator= (const OrderedPair< K, V > &that)
 Assignment (copy semantics). More...
 
K & x ()
 Get access to the key or value. More...
 
const K & x () const
 
V & y ()
 
const V & y () const
 

Private Types

enum  { OrderedPairVersion }
 

Private Attributes

Key
 
Val
 

Detailed Description

template<class K, class V>
class casacore::OrderedPair< K, V >

Ordered pair class

Review Status

Reviewed By:
UNKNOWN
Date Reviewed:
before2004/08/25

Intended use:

Internal

Synopsis

This class is a simple class used in the Map<key,value> classes to manage key/value pairs for maps. The default constructor is needed for use in containers. This implies that ALL classes ever used in OrderedPair should have a default constructor!!!!


Note: This should probably be cleaned up in the future and made into a generally useful class;

Definition at line 60 of file OrderedPair.h.

Member Enumeration Documentation

◆ anonymous enum

template<class K , class V >
anonymous enum
private
Enumerator
OrderedPairVersion 

Definition at line 96 of file OrderedPair.h.

Constructor & Destructor Documentation

◆ OrderedPair() [1/3]

template<class K , class V >
casacore::OrderedPair< K, V >::OrderedPair ( )

Needed for "operator>>(AipsIO &ios, Slist<elem> &list)".

◆ OrderedPair() [2/3]

template<class K , class V >
casacore::OrderedPair< K, V >::OrderedPair ( const K &  k,
const V &  v 
)

This is the "standard" constructor which takes a key and a value and constructs an ordered pair.

◆ OrderedPair() [3/3]

template<class K , class V >
casacore::OrderedPair< K, V >::OrderedPair ( const OrderedPair< K, V > &  that)

Copy constructor (copy semantics).

Member Function Documentation

◆ operator=()

template<class K , class V >
OrderedPair<K,V>& casacore::OrderedPair< K, V >::operator= ( const OrderedPair< K, V > &  that)

Assignment (copy semantics).

◆ x() [1/2]

template<class K , class V >
K& casacore::OrderedPair< K, V >::x ( )
inline

Get access to the key or value.

Definition at line 86 of file OrderedPair.h.

References casacore::OrderedPair< K, V >::Key.

◆ x() [2/2]

template<class K , class V >
const K& casacore::OrderedPair< K, V >::x ( ) const
inline

Definition at line 87 of file OrderedPair.h.

References casacore::OrderedPair< K, V >::Key.

◆ y() [1/2]

template<class K , class V >
V& casacore::OrderedPair< K, V >::y ( )
inline

Definition at line 88 of file OrderedPair.h.

References casacore::OrderedPair< K, V >::Val.

◆ y() [2/2]

template<class K , class V >
const V& casacore::OrderedPair< K, V >::y ( ) const
inline

Definition at line 89 of file OrderedPair.h.

References casacore::OrderedPair< K, V >::Val.

Member Data Documentation

◆ Key

template<class K , class V >
K casacore::OrderedPair< K, V >::Key
private

Definition at line 93 of file OrderedPair.h.

Referenced by casacore::OrderedPair< K, V >::x().

◆ Val

template<class K , class V >
V casacore::OrderedPair< K, V >::Val
private

Definition at line 94 of file OrderedPair.h.

Referenced by casacore::OrderedPair< K, V >::y().


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