29 lines
473 B
C++
29 lines
473 B
C++
|
/*
|
|||
|
* address.hpp
|
|||
|
*
|
|||
|
* Created on: 5 сент. 2022 г.
|
|||
|
* Author: alexander
|
|||
|
*/
|
|||
|
|
|||
|
#pragma once
|
|||
|
|
|||
|
#include <netinet/in.h>
|
|||
|
#include <string.h>
|
|||
|
|
|||
|
namespace zh {
|
|||
|
|
|||
|
class Address
|
|||
|
{
|
|||
|
private:
|
|||
|
struct sockaddr_in _addr;
|
|||
|
unsigned int _len;
|
|||
|
public:
|
|||
|
Address();
|
|||
|
Address(const Address &address);
|
|||
|
Address(const unsigned short int family, const unsigned int addr, const unsigned short int port);
|
|||
|
unsigned int& size();
|
|||
|
struct sockaddr_in& operator*();
|
|||
|
};
|
|||
|
|
|||
|
}
|