clingo
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups
Classes | Public Types | Public Member Functions | Static Public Member Functions | List of all members
Gringo::Flyweight< T > Class Template Reference

#include <flyweight.hh>

Inheritance diagram for Gringo::Flyweight< T >:
Inheritance graph
Collaboration diagram for Gringo::Flyweight< T >:
Collaboration graph

Classes

struct  Equal
 
struct  Hash
 

Public Types

using value_type = T
 
using key_iterator = typename std::unordered_set< unsigned, Hash, Equal >::const_iterator
 
using return_type = T &
 

Public Member Functions

 Flyweight (value_type &&val)
 
 Flyweight (unsigned uid)
 
template<typename... Args>
 Flyweight (Args...args)
 
unsigned uid () const
 
return_type operator* () const
 
bool operator== (Flyweight const &other) const
 
bool operator!= (Flyweight const &other) const
 
bool operator< (Flyweight const &other) const
 
bool operator> (Flyweight const &other) const
 
bool operator<= (Flyweight const &other) const
 
bool operator>= (Flyweight const &other) const
 

Static Public Member Functions

static unsigned uid (value_type &&val)
 
static key_iterator beginKey ()
 
static key_iterator endKey ()
 
static void erase (unsigned uid)
 
static void clear ()
 

Member Typedef Documentation

template<class T>
using Gringo::Flyweight< T >::key_iterator = typename std::unordered_set<unsigned, Hash, Equal>::const_iterator
template<class T>
using Gringo::Flyweight< T >::return_type = T&
template<class T>
using Gringo::Flyweight< T >::value_type = T

Constructor & Destructor Documentation

template<class T >
Gringo::Flyweight< T >::Flyweight ( value_type &&  val)
template<class T >
Gringo::Flyweight< T >::Flyweight ( unsigned  uid)
template<class T >
template<typename... Args>
Gringo::Flyweight< T >::Flyweight ( Args...  args)

Member Function Documentation

template<class T >
Flyweight< T >::key_iterator Gringo::Flyweight< T >::beginKey ( )
static
template<class T >
void Gringo::Flyweight< T >::clear ( )
static
template<class T >
Flyweight< T >::key_iterator Gringo::Flyweight< T >::endKey ( )
static
template<class T >
void Gringo::Flyweight< T >::erase ( unsigned  uid)
static
template<class T >
bool Gringo::Flyweight< T >::operator!= ( Flyweight< T > const &  other) const
template<class T >
Flyweight< T >::return_type Gringo::Flyweight< T >::operator* ( ) const
template<class T >
bool Gringo::Flyweight< T >::operator< ( Flyweight< T > const &  other) const
template<class T >
bool Gringo::Flyweight< T >::operator<= ( Flyweight< T > const &  other) const
template<class T >
bool Gringo::Flyweight< T >::operator== ( Flyweight< T > const &  other) const
template<class T >
bool Gringo::Flyweight< T >::operator> ( Flyweight< T > const &  other) const
template<class T >
bool Gringo::Flyweight< T >::operator>= ( Flyweight< T > const &  other) const
template<class T >
unsigned Gringo::Flyweight< T >::uid ( value_type &&  val)
static

Here is the call graph for this function:

template<class T >
unsigned Gringo::Flyweight< T >::uid ( ) const

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