xtd 0.2.0
Loading...
Searching...
No Matches
end_point.h
Go to the documentation of this file.
1
4#pragma once
5#include "socket_address.h"
7#include "../core_export.h"
8#include "../object.h"
9#include "../types.h"
10#include "../string.h"
11#include <memory>
12
14namespace xtd {
16 namespace net {
28 public:
30 end_point(end_point&& end_point) = default;
31 end_point(const end_point& end_point) = default;
32 end_point& operator =(const end_point&) = default;
34
36
42
44
50 virtual xtd::uptr<end_point> create(const socket_address& socket_address) const;
51
54 virtual socket_address serialize() const;
55
58 string to_string() const noexcept override;
60
61 protected:
63
66 explicit end_point(sockets::address_family address_family) : address_family_(address_family) {}
68
70 end_point() = default;
71
72 sockets::address_family address_family_ = sockets::address_family::unknown;
74 };
75 }
76}
Contains xtd::net::sockets::address_family enum.
Identifies a network address. This is an abstract class.
Definition end_point.h:27
sockets::address_family address_family() const noexcept
Gets the address family to which the endpoint belongs.
Stores serialized information from end_point derived classes.
Definition socket_address.h:31
Supports all classes in the xtd class hierarchy and provides low-level services to derived classes....
Definition object.h:42
#define core_export_
Define shared library export.
Definition core_export.h:13
std::unique_ptr< type_t > uptr
The xtd::uptr object is a unique pointer.
Definition uptr.h:25
address_family
Specifies the addressing scheme that an instance of the xtd::net::sockets::socket class can use.
Definition address_family.h:30
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition xtd_about_box.h:10
Contains xtd::net::socket_address class.