Adobe Source Libraries 1.49.0
A collection of C++ libraries.
Loading...
Searching...
No Matches
single< T > Struct Template Reference

holds a single value, and returns it as an arg n (default 1) times More...

#include <arg_stream.hpp>

Public Types

typedef T value_type

Public Member Functions

 single (typename boost::add_reference< T const >::type t, unsigned int count=1)
bool eof ()
template<typename R>
convert_or_throw (value_type &value, typename boost::enable_if< boost::is_convertible< value_type, R > >::type *dummy=0)
template<typename R>
convert_or_throw (value_type &value, typename boost::disable_if< boost::is_convertible< value_type, R > >::type *dummy=0)
template<typename R>
get_next_arg ()

Public Attributes

value
unsigned int repeat

Detailed Description

template<typename T>
struct adobe::arg_stream::single< T >
this is useful (in combination with arg_stream::chain) when you need to slip a single value
at the front/back of an arg_stream.

Definition at line 377 of file arg_stream.hpp.

Member Typedef Documentation

◆ value_type

template<typename T>
typedef T value_type

Definition at line 378 of file arg_stream.hpp.

Constructor & Destructor Documentation

◆ single()

template<typename T>
single ( typename boost::add_reference< T const >::type t,
unsigned int count = 1 )

Definition at line 383 of file arg_stream.hpp.

Member Function Documentation

◆ eof()

template<typename T>
bool eof ( )

Definition at line 386 of file arg_stream.hpp.

◆ convert_or_throw() [1/2]

template<typename T>
template<typename R>
R convert_or_throw ( value_type & value,
typename boost::enable_if< boost::is_convertible< value_type, R > >::type * dummy = 0 )

Definition at line 389 of file arg_stream.hpp.

◆ convert_or_throw() [2/2]

template<typename T>
template<typename R>
R convert_or_throw ( value_type & value,
typename boost::disable_if< boost::is_convertible< value_type, R > >::type * dummy = 0 )

Definition at line 395 of file arg_stream.hpp.

◆ get_next_arg()

template<typename T>
template<typename R>
R get_next_arg ( )

Definition at line 403 of file arg_stream.hpp.

Member Data Documentation

◆ value

template<typename T>
T value

Definition at line 380 of file arg_stream.hpp.

◆ repeat

template<typename T>
unsigned int repeat

Definition at line 381 of file arg_stream.hpp.