arbb::auto_closure Class Reference

A dynamically-typed closure. More...

List of all members.

Public Member Functions

 auto_closure ()
 Default constructor. Creates an empty closure.
 auto_closure (const auto_closure &other)
 Copy constructor.
bool empty () const
 Returns true if the closure is empty.
auto_closureoperator= (const auto_closure &other)
 Assignment operator.
bool operator== (const detail::closure_base &other) const
 Returns true if the closure is the same as other.
bool operator!= (const detail::closure_base &other) const
 Returns true if the closure is not the same as other.
template<typename T >
bool has_type () const
 Returns true if the closure has the same type as a function of type T.

Detailed Description

A dynamically-typed closure.

The arbb::auto_closure class generally behaves like arbb::closure, but performs run-time type checking instead of static type checking, and can be used to store arbitrary captured functions.

See Also

Closures

Definition at line 39 of file auto_closure.hpp.


Constructor & Destructor Documentation

arbb::auto_closure::auto_closure (  ) 

Default constructor. Creates an empty closure.

arbb::auto_closure::auto_closure ( const auto_closure other  ) 

Copy constructor.


Member Function Documentation

bool arbb::auto_closure::empty (  )  const

Returns true if the closure is empty.

auto_closure& arbb::auto_closure::operator= ( const auto_closure other  ) 

Assignment operator.

bool arbb::auto_closure::operator== ( const detail::closure_base &  other  )  const

Returns true if the closure is the same as other.

bool arbb::auto_closure::operator!= ( const detail::closure_base &  other  )  const

Returns true if the closure is not the same as other.

template<typename T >
bool arbb::auto_closure::has_type (  )  const [inline]

Returns true if the closure has the same type as a function of type T.

Template Parameters:

T The type of the function to compare to. For example, void (arbb::f32&, arbb::f32).

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

Submit feedback on this help topic

Copyright © 2010, Intel Corporation. All rights reserved.