Represents a network endpoint as an IP address and a port number.
Fields | |
| static constexpr uint16 | min_port = 0x0000 |
| Specifies the minimum value that can be assigned to the port property. The min_port value is set to 0x0000. This field is read-only. More... | |
| static constexpr uint16 | max_port = 0xFFFF |
| Specifies the maximum value that can be assigned to the port property. The max_port value is set to 0xFFFF. This field is read-only. More... | |
Constructors | |
| ip_end_point (uint32 address, uint16 port) | |
| Initializes a new instance of the xtd::net::ip_end_point class. More... | |
| ip_end_point (const xtd::net::ip_address &address, uint16 port) | |
| Initializes a new instance of the xtd::net::ip_end_point class. More... | |
Properties | |
| const xtd::net::ip_address & | address () const noexcept |
| Gets the IP address of the endpoint. More... | |
| ip_end_point & | address (const xtd::net::ip_address &value) |
| Sets the IP address of the endpoint. More... | |
| uint16 | port () const noexcept |
| Gets or sets the port number of the endpoint. More... | |
| ip_end_point & | port (uint16 value) |
| Sets the port number of the endpoint. More... | |
Methods | |
| std::unique_ptr< end_point > | create (const xtd::net::socket_address &socket_address) const override |
| Creates an xtd::net::end_point instance from a xtd::net::socket_address instance. More... | |
| xtd::net::socket_address | serialize () const override |
| Serializes endpoint information into a socket_address instance. More... | |
| xtd::ustring | to_string () const noexcept override |
| Returns a string that represents the current object. More... | |
Additional Inherited Members | |
Public Member Functions inherited from xtd::net::end_point | |
| sockets::address_family | address_family () const noexcept |
| Gets the address family to which the endpoint belongs. More... | |
Public Member Functions inherited from xtd::object | |
| object ()=default | |
| Create a new instance of the ultimate base class object. More... | |
| bool | equals (const object &obj) const noexcept |
| Determines whether the specified object is equal to the current object. More... | |
| virtual size_t | get_hash_code () const noexcept |
| Serves as a hash function for a particular type. More... | |
| virtual type_object | get_type () const noexcept |
| Gets the type of the current instance. More... | |
| template<typename object_t > | |
| std::unique_ptr< object_t > | memberwise_clone () const noexcept |
| Creates a shallow copy of the current object. More... | |
Static Public Member Functions inherited from xtd::object | |
| static bool | equals (const object &object_a, const object &object_b) noexcept |
| Determines whether the specified object instances are considered equal. More... | |
| static bool | reference_equals (const object &object_a, const object &object_b) noexcept |
| Determines whether the specified object instances are the same instance. More... | |
Protected Member Functions inherited from xtd::net::end_point | |
| end_point (sockets::address_family address_family) | |
| Initializes a new instance of the xtd::net::end_point class. More... | |
Initializes a new instance of the xtd::net::ip_end_point class.
| address | The IP address of the Internet host. |
| port | The port number associated with the address, or 0 to specify any available port. port is in host order. |
| xtd::net::ip_end_point::ip_end_point | ( | const xtd::net::ip_address & | address, |
| uint16 | port | ||
| ) |
Initializes a new instance of the xtd::net::ip_end_point class.
| address | An xtd::net::ip_address. |
| port | The port number associated with the address, or 0 to specify any available port. port is in host order. |
|
noexcept |
Gets the IP address of the endpoint.
| ip_end_point& xtd::net::ip_end_point::address | ( | const xtd::net::ip_address & | value | ) |
Sets the IP address of the endpoint.
| value | An ip_address instance containing the IP address of the endpoint. |
|
overridevirtual |
Creates an xtd::net::end_point instance from a xtd::net::socket_address instance.
| socket_address | The socket address that serves as the endpoint for a connection. |
| xtd::not_supported_exception | Any attempt is made to access the method when the method is not overridden in a descendant class. |
Reimplemented from xtd::net::end_point.
|
noexcept |
Gets or sets the port number of the endpoint.
| value | An integer value in the range min_port to max_port indicating the port number of the endpoint. |
| ip_end_point& xtd::net::ip_end_point::port | ( | uint16 | value | ) |
Sets the port number of the endpoint.
| value | An integer value in the range min_port to max_port indicating the port number of the endpoint. |
|
overridevirtual |
Serializes endpoint information into a socket_address instance.
Reimplemented from xtd::net::end_point.
|
overridevirtualnoexcept |
Returns a string that represents the current object.
Reimplemented from xtd::net::end_point.
|
static |
Specifies the maximum value that can be assigned to the port property. The max_port value is set to 0xFFFF. This field is read-only.
|
static |
Specifies the minimum value that can be assigned to the port property. The min_port value is set to 0x0000. This field is read-only.