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"
6#include "../../core_export.hpp"
7#include "../../iequatable.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
46 ip_v6_multicast_option(const xtd::net::ip_address& group, uint64 interface_index);
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;
76 ip_v6_multicast_option& interface_index(uint64 value);
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
Contains option values for joining an IPv6 multicast group.
Definition ip_v6_multicast_option.hpp:33
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.
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...
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
#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
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition xtd_about_box.hpp:10