CoreComponents 3.0.0
A Modern C++ Toolkit
All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Modules Pages Modules
Composite< T > Class Template Reference

Composite aggregate More...

#include <cc/basics>

Public Types

using Value = T
 Value type.
 

Public Member Functions

template<class... Args>
 Composite (Args... args)
 Initial construction of the aggregate.
 
T & operator() ()
 Get reference to aggregate value.
 
const T & operator() () const
 Get constant reference to aggregate value.
 
long useCount () const
 Return the usage count for this aggregate
 

Detailed Description

template<class T>
class cc::Composite< T >

Composite aggregate

Template Parameters
TValue type

Member Typedef Documentation

◆ Value

template<class T >
using Value = T

Value type.

Constructor & Destructor Documentation

◆ Composite()

template<class T >
template<class... Args>
Composite ( Args... args)
explicit

Initial construction of the aggregate.

Parameters
argsconstruction arguments for the aggregate value

Member Function Documentation

◆ operator()() [1/2]

template<class T >
T & operator() ( )

Get reference to aggregate value.

◆ operator()() [2/2]

template<class T >
const T & operator() ( ) const

Get constant reference to aggregate value.

◆ useCount()

template<class T >
long useCount ( ) const

Return the usage count for this aggregate