asio 0.1.5 Main Page | Class Index | Member Index | Tutorial

integer Class Template Reference

Helper template for implementing integer options. More...

List of all members.

Public Member Functions

 integer ()
 Default constructor.

 integer (int value)
 Construct with a specific option value.

int level () const
 Get the level of the socket option.

int name () const
 Get the name of the socket option.

void set (int value)
 Set the value of the int option.

int get () const
 Get the current value of the int option.

void * data ()
 Get the address of the int data.

const void * data () const
 Get the address of the int data.

size_t size () const
 Get the size of the int data.


Private Attributes

int value_
 The underlying value of the int option.


Detailed Description

template<int Level, int Name>
class asio::socket_option::integer< Level, Name >

Helper template for implementing integer options.


Constructor & Destructor Documentation

integer  ) 
 

Default constructor.

integer int  value  ) 
 

Construct with a specific option value.


Member Function Documentation

int level  )  const
 

Get the level of the socket option.

int name  )  const
 

Get the name of the socket option.

void set int  value  ) 
 

Set the value of the int option.

int get  )  const
 

Get the current value of the int option.

void* data  ) 
 

Get the address of the int data.

const void* data  )  const
 

Get the address of the int data.

size_t size  )  const
 

Get the size of the int data.


Member Data Documentation

int value_ [private]
 

The underlying value of the int option.