- Main Page
- Namespaces
- Classes
- Files

- Class List
- Class Hierarchy
- Class Members

Public Member Functions | List of all members
GNet::AddressStorage Class Reference

A helper class for calling getsockname() and getpeername() and hiding the definition of sockaddr_storage. More...

`#include <gaddress.h>`

## Public Member Functions
| AddressStorage ()
| Default constructor. More...
| ~AddressStorage ()
| Destructor. More...
sockaddr * | p1 ()
| Returns the sockaddr pointer for getsockname()/getpeername() to write into. More...
socklen_t * | p2 ()
| Returns the length pointer for getsockname()/getpeername() to write into. More...
const sockaddr * | p () const
| Returns the pointer. More...
socklen_t | n () const
| Returns the length. More...

## Detailed Description

A helper class for calling getsockname() and getpeername() and hiding the definition of sockaddr_storage.

Definition at line 225 of file gaddress.h.

## Constructor & Destructor Documentation

GNet::AddressStorage::AddressStorage | ( |  | ) |

Default constructor.

Definition at line 643 of file gaddress_ipv4.cpp.

References GNet::AddressStorageImp::n.

GNet::AddressStorage::~AddressStorage | ( |  | ) |

Destructor.

Definition at line 649 of file gaddress_ipv4.cpp.

## Member Function Documentation

socklen_t GNet::AddressStorage::n | ( |  | ) | const

Returns the length.

Definition at line 669 of file gaddress_ipv4.cpp.

const sockaddr * GNet::AddressStorage::p | ( |  | ) | const

Returns the pointer.

Definition at line 664 of file gaddress_ipv4.cpp.

sockaddr * GNet::AddressStorage::p1 | ( |  | ) |

Returns the sockaddr pointer for getsockname()/getpeername() to write into.

Definition at line 654 of file gaddress_ipv4.cpp.

Referenced by GNet::Socket::getAddress().

socklen_t * GNet::AddressStorage::p2 | ( |  | ) |

Returns the length pointer for getsockname()/getpeername() to write into.

Definition at line 659 of file gaddress_ipv4.cpp.

Referenced by GNet::Socket::getAddress().

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

- gaddress.h
- gaddress_ipv4.cpp