xtd 0.2.0
ip_v6_multicast_option.hpp
Go to the documentation of this file.
1
4#pragma once
5#include "../ip_address.hpp"
8#include "../../object.hpp"
9#include "../../types.hpp"
10#include "../../string.hpp"
11
13namespace xtd {
15 namespace net {
17 namespace sockets {
33 class core_export_ ip_v6_multicast_option : public xtd::object, public xtd::iequatable<xtd::net::sockets::ip_v6_multicast_option> {
34 public:
36
48
51 ip_v6_multicast_option& operator =(ip_v6_multicast_option&&) = default;
53 ip_v6_multicast_option& operator =(const ip_v6_multicast_option&) = default;
55
57
61 const xtd::net::ip_address& group() const noexcept;
65 ip_v6_multicast_option& group(const xtd::net::ip_address& value) noexcept;
66
70 uint64 interface_index() const noexcept;
78
80
85 bool equals(const object& obj) const noexcept override;
89 bool equals(const ip_v6_multicast_option& other) const noexcept override;
90
93 xtd::size get_hash_code() const noexcept override;
95
96 private:
97 xtd::net::ip_address group_ = xtd::net::ip_address::ip_v6_none;
98 uint64 interface_index_ = 0;
99 };
100 }
101 }
102}
Defines a generalized method that a value type or class implements to create a type-specific method f...
Definition iequatable.hpp:22
Provides an Internet Protocol (IP) address.
Definition ip_address.hpp:42
uint64 interface_index() const noexcept
Gets the interface index that is associated with a multicast group.
ip_v6_multicast_option(const xtd::net::ip_address &group, uint64 interface_index)
Initializes a new instance of the xtd::net::sockets::ip_v6_multicast_option class with the specified ...
ip_v6_multicast_option()=default
Initializes a new instance of the xtd::net::sockets::ip_v6_multicast_option class.
xtd::size get_hash_code() const noexcept override
Serves as a hash function for a particular type.
ip_v6_multicast_option(const xtd::net::ip_address &group)
Initializes a new version of the xtd::net::sockets::ip_v6_multicast_option class for the specified IP...
bool equals(const object &obj) const noexcept override
Determines whether the specified object is equal to the current object.
const xtd::net::ip_address & group() const noexcept
Gets the IP address of a multicast group.
Supports all classes in the xtd class hierarchy and provides low-level services to derived classes....
Definition object.hpp:44
Contains core_export_ keyword.
#define core_export_
Define shared library export.
Definition core_export.hpp:13
size_t size
Represents a size of any object in bytes.
Definition size.hpp:23
uint64_t uint64
Represents a 64-bit unsigned integer.
Definition uint64.hpp:23
@ other
The operating system is other.
Definition platform_id.hpp:58
Contains xtd::iequatable interface.
The xtd::net::sockets namespace provides a managed implementation of the Berkeley Sockets interface f...
Definition address_family.hpp:16
The xtd::net namespace provides a simple programming interface for many of the protocols used on netw...
Definition cookie_exception.hpp:10
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition abstract_object.hpp:8
Contains xtd::net::ip_address class.
Contains xtd::object class.
Contains xtd::string alias.
Contains xtd fundamental types.