|
Packit |
306c40 |
// Generated by gmmproc 2.54.1 -- DO NOT MODIFY!
|
|
Packit |
306c40 |
#ifndef _GIOMM_INETSOCKETADDRESS_H
|
|
Packit |
306c40 |
#define _GIOMM_INETSOCKETADDRESS_H
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
#include <glibmm/ustring.h>
|
|
Packit |
306c40 |
#include <sigc++/sigc++.h>
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
/* Copyright (C) 2009 jonathon jongsma
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* This library is free software; you can redistribute it and/or
|
|
Packit |
306c40 |
* modify it under the terms of the GNU Lesser General Public
|
|
Packit |
306c40 |
* License as published by the Free Software Foundation; either
|
|
Packit |
306c40 |
* version 2.1 of the License, or (at your option) any later version.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* This library is distributed in the hope that it will be useful,
|
|
Packit |
306c40 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
Packit |
306c40 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
Packit |
306c40 |
* Lesser General Public License for more details.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* You should have received a copy of the GNU Lesser General Public
|
|
Packit |
306c40 |
* License along with this library. If not, see <http://www.gnu.org/licenses/>.
|
|
Packit |
306c40 |
*/
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
#include <giomm/socketaddress.h>
|
|
Packit |
306c40 |
#include <giomm/inetaddress.h>
|
|
Packit |
306c40 |
#include <giomm/enums.h>
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
#ifndef DOXYGEN_SHOULD_SKIP_THIS
|
|
Packit |
306c40 |
using GInetSocketAddress = struct _GInetSocketAddress;
|
|
Packit |
306c40 |
using GInetSocketAddressClass = struct _GInetSocketAddressClass;
|
|
Packit |
306c40 |
#endif /* DOXYGEN_SHOULD_SKIP_THIS */
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
#ifndef DOXYGEN_SHOULD_SKIP_THIS
|
|
Packit |
306c40 |
namespace Gio
|
|
Packit |
306c40 |
{ class InetSocketAddress_Class; } // namespace Gio
|
|
Packit |
306c40 |
#endif //DOXYGEN_SHOULD_SKIP_THIS
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
namespace Gio
|
|
Packit |
306c40 |
{
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
/** Internet SocketAddress
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* An IPv4 or IPv6 socket address; that is, the combination of a
|
|
Packit |
306c40 |
* InetAddress and a port number.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* An IPv4 or IPv6 socket address, corresponding to a struct sockaddr_in or
|
|
Packit |
306c40 |
* struct sockaddr_in6.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @newin{2,24}
|
|
Packit |
306c40 |
* @ingroup NetworkIO
|
|
Packit |
306c40 |
*/
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
class InetSocketAddress
|
|
Packit |
306c40 |
: public SocketAddress
|
|
Packit |
306c40 |
{
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
#ifndef DOXYGEN_SHOULD_SKIP_THIS
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
public:
|
|
Packit |
306c40 |
using CppObjectType = InetSocketAddress;
|
|
Packit |
306c40 |
using CppClassType = InetSocketAddress_Class;
|
|
Packit |
306c40 |
using BaseObjectType = GInetSocketAddress;
|
|
Packit |
306c40 |
using BaseClassType = GInetSocketAddressClass;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
// noncopyable
|
|
Packit |
306c40 |
InetSocketAddress(const InetSocketAddress&) = delete;
|
|
Packit |
306c40 |
InetSocketAddress& operator=(const InetSocketAddress&) = delete;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
private: friend class InetSocketAddress_Class;
|
|
Packit |
306c40 |
static CppClassType inetsocketaddress_class_;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
protected:
|
|
Packit |
306c40 |
explicit InetSocketAddress(const Glib::ConstructParams& construct_params);
|
|
Packit |
306c40 |
explicit InetSocketAddress(GInetSocketAddress* castitem);
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
#endif /* DOXYGEN_SHOULD_SKIP_THIS */
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
public:
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
InetSocketAddress(InetSocketAddress&& src) noexcept;
|
|
Packit |
306c40 |
InetSocketAddress& operator=(InetSocketAddress&& src) noexcept;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
~InetSocketAddress() noexcept override;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
/** Get the GType for this class, for use with the underlying GObject type system.
|
|
Packit |
306c40 |
*/
|
|
Packit |
306c40 |
static GType get_type() G_GNUC_CONST;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
#ifndef DOXYGEN_SHOULD_SKIP_THIS
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
static GType get_base_type() G_GNUC_CONST;
|
|
Packit |
306c40 |
#endif
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
///Provides access to the underlying C GObject.
|
|
Packit |
306c40 |
GInetSocketAddress* gobj() { return reinterpret_cast<GInetSocketAddress*>(gobject_); }
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
///Provides access to the underlying C GObject.
|
|
Packit |
306c40 |
const GInetSocketAddress* gobj() const { return reinterpret_cast<GInetSocketAddress*>(gobject_); }
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
///Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.
|
|
Packit |
306c40 |
GInetSocketAddress* gobj_copy();
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
private:
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
protected:
|
|
Packit |
306c40 |
explicit InetSocketAddress(const Glib::RefPtr<InetAddress>& address, guint16 port);
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
public:
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
static Glib::RefPtr<InetSocketAddress> create(const Glib::RefPtr<InetAddress>& address, guint16 port);
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
/** Gets @a address's InetAddress.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @newin{2,22}
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @return The InetAddress for @a address, which must be
|
|
Packit |
306c40 |
* Glib::object_ref()'d if it will be stored.
|
|
Packit |
306c40 |
*/
|
|
Packit |
306c40 |
Glib::RefPtr<InetAddress> get_address();
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
/** Gets @a address's InetAddress.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @newin{2,22}
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @return The InetAddress for @a address, which must be
|
|
Packit |
306c40 |
* Glib::object_ref()'d if it will be stored.
|
|
Packit |
306c40 |
*/
|
|
Packit |
306c40 |
Glib::RefPtr<const InetAddress> get_address() const;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
/** Gets @a address's port.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @newin{2,22}
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @return The port for @a address.
|
|
Packit |
306c40 |
*/
|
|
Packit |
306c40 |
guint16 get_port() const;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
/** Gets the `sin6_flowinfo` field from @a address,
|
|
Packit |
306c40 |
* which must be an IPv6 address.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @newin{2,32}
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @return The flowinfo field.
|
|
Packit |
306c40 |
*/
|
|
Packit |
306c40 |
guint32 get_flowinfo() const;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
/** Gets the `sin6_scope_id` field from @a address,
|
|
Packit |
306c40 |
* which must be an IPv6 address.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @newin{2,32}
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @return The scope id field.
|
|
Packit |
306c40 |
*/
|
|
Packit |
306c40 |
guint32 get_scope_id() const;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
/** The address.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @return A PropertyProxy_ReadOnly that allows you to get the value of the property,
|
|
Packit |
306c40 |
* or receive notification when the value of the property changes.
|
|
Packit |
306c40 |
*/
|
|
Packit |
306c40 |
Glib::PropertyProxy_ReadOnly< Glib::RefPtr<InetAddress> > property_address() const;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
/** The port.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* Default value: 0
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @return A PropertyProxy_ReadOnly that allows you to get the value of the property,
|
|
Packit |
306c40 |
* or receive notification when the value of the property changes.
|
|
Packit |
306c40 |
*/
|
|
Packit |
306c40 |
Glib::PropertyProxy_ReadOnly< guint16 > property_port() const;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
/** The `sin6_flowinfo` field, for IPv6 addresses.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @newin{2,32}
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* Default value: 0
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @return A PropertyProxy_ReadOnly that allows you to get the value of the property,
|
|
Packit |
306c40 |
* or receive notification when the value of the property changes.
|
|
Packit |
306c40 |
*/
|
|
Packit |
306c40 |
Glib::PropertyProxy_ReadOnly< guint32 > property_flowinfo() const;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
/** IPv6 scope ID.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* Default value: 0
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @return A PropertyProxy_ReadOnly that allows you to get the value of the property,
|
|
Packit |
306c40 |
* or receive notification when the value of the property changes.
|
|
Packit |
306c40 |
*/
|
|
Packit |
306c40 |
Glib::PropertyProxy_ReadOnly< guint32 > property_scope_id() const;
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
public:
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
public:
|
|
Packit |
306c40 |
//C++ methods used to invoke GTK+ virtual functions:
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
protected:
|
|
Packit |
306c40 |
//GTK+ Virtual Functions (override these to change behaviour):
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
//Default Signal Handlers::
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
};
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
} // namespace Gio
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
namespace Glib
|
|
Packit |
306c40 |
{
|
|
Packit |
306c40 |
/** A Glib::wrap() method for this object.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @param object The C instance.
|
|
Packit |
306c40 |
* @param take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref.
|
|
Packit |
306c40 |
* @result A C++ instance that wraps this C instance.
|
|
Packit |
306c40 |
*
|
|
Packit |
306c40 |
* @relates Gio::InetSocketAddress
|
|
Packit |
306c40 |
*/
|
|
Packit |
306c40 |
Glib::RefPtr<Gio::InetSocketAddress> wrap(GInetSocketAddress* object, bool take_copy = false);
|
|
Packit |
306c40 |
}
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
|
|
Packit |
306c40 |
#endif /* _GIOMM_INETSOCKETADDRESS_H */
|
|
Packit |
306c40 |
|