1/* SPDX-License-Identifier: LGPL-2.1-or-later */
2/*
3 * Copyright (C) 2015 Red Hat, Inc.
4 */
5
6#ifndef __NM_DEVICE_IP_TUNNEL_H__
7#define __NM_DEVICE_IP_TUNNEL_H__
8
9#if !defined(__NETWORKMANAGER_H_INSIDE__) && !defined(NETWORKMANAGER_COMPILATION)
10#error "Only <NetworkManager.h> can be included directly."
11#endif
12
13#include "nm-device.h"
14#include "nm-setting-ip-tunnel.h"
15
16G_BEGIN_DECLS
17
18#define NM_TYPE_DEVICE_IP_TUNNEL (nm_device_ip_tunnel_get_type())
19#define NM_DEVICE_IP_TUNNEL(obj) \
20 (G_TYPE_CHECK_INSTANCE_CAST((obj), NM_TYPE_DEVICE_IP_TUNNEL, NMDeviceIPTunnel))
21#define NM_DEVICE_IP_TUNNEL_CLASS(klass) \
22 (G_TYPE_CHECK_CLASS_CAST((klass), NM_TYPE_DEVICE_IP_TUNNEL, NMDeviceIPTunnelClass))
23#define NM_IS_DEVICE_IP_TUNNEL(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), NM_TYPE_DEVICE_IP_TUNNEL))
24#define NM_IS_DEVICE_IP_TUNNEL_CLASS(klass) \
25 (G_TYPE_CHECK_CLASS_TYPE((klass), NM_TYPE_DEVICE_IP_TUNNEL))
26#define NM_DEVICE_IP_TUNNEL_GET_CLASS(obj) \
27 (G_TYPE_INSTANCE_GET_CLASS((obj), NM_TYPE_DEVICE_IP_TUNNEL, NMDeviceIPTunnelClass))
28
29#define NM_DEVICE_IP_TUNNEL_MODE "mode"
30#define NM_DEVICE_IP_TUNNEL_PARENT "parent"
31#define NM_DEVICE_IP_TUNNEL_LOCAL "local"
32#define NM_DEVICE_IP_TUNNEL_REMOTE "remote"
33#define NM_DEVICE_IP_TUNNEL_TTL "ttl"
34#define NM_DEVICE_IP_TUNNEL_TOS "tos"
35#define NM_DEVICE_IP_TUNNEL_PATH_MTU_DISCOVERY "path-mtu-discovery"
36#define NM_DEVICE_IP_TUNNEL_INPUT_KEY "input-key"
37#define NM_DEVICE_IP_TUNNEL_OUTPUT_KEY "output-key"
38#define NM_DEVICE_IP_TUNNEL_ENCAPSULATION_LIMIT "encapsulation-limit"
39#define NM_DEVICE_IP_TUNNEL_FLOW_LABEL "flow-label"
40#define NM_DEVICE_IP_TUNNEL_FLAGS "flags"
41
42/**
43 * NMDeviceIPTunnel:
44 */
45typedef struct _NMDeviceIPTunnelClass NMDeviceIPTunnelClass;
46
47NM_AVAILABLE_IN_1_2
48GType nm_device_ip_tunnel_get_type(void);
49
50NM_AVAILABLE_IN_1_2
51NMDevice *nm_device_ip_tunnel_get_parent(NMDeviceIPTunnel *device);
52NM_AVAILABLE_IN_1_2
53NMIPTunnelMode nm_device_ip_tunnel_get_mode(NMDeviceIPTunnel *device);
54NM_AVAILABLE_IN_1_2
55const char *nm_device_ip_tunnel_get_local(NMDeviceIPTunnel *device);
56NM_AVAILABLE_IN_1_2
57const char *nm_device_ip_tunnel_get_remote(NMDeviceIPTunnel *device);
58NM_AVAILABLE_IN_1_2
59guint8 nm_device_ip_tunnel_get_ttl(NMDeviceIPTunnel *device);
60NM_AVAILABLE_IN_1_2
61guint8 nm_device_ip_tunnel_get_tos(NMDeviceIPTunnel *device);
62NM_AVAILABLE_IN_1_2
63gboolean nm_device_ip_tunnel_get_path_mtu_discovery(NMDeviceIPTunnel *device);
64NM_AVAILABLE_IN_1_2
65const char *nm_device_ip_tunnel_get_input_key(NMDeviceIPTunnel *device);
66NM_AVAILABLE_IN_1_2
67const char *nm_device_ip_tunnel_get_output_key(NMDeviceIPTunnel *device);
68NM_AVAILABLE_IN_1_2
69guint8 nm_device_ip_tunnel_get_encapsulation_limit(NMDeviceIPTunnel *device);
70NM_AVAILABLE_IN_1_2
71guint nm_device_ip_tunnel_get_flow_label(NMDeviceIPTunnel *device);
72NM_AVAILABLE_IN_1_12
73NMIPTunnelFlags nm_device_ip_tunnel_get_flags(NMDeviceIPTunnel *device);
74
75G_END_DECLS
76
77#endif /* __NM_DEVICE_IP_TUNNEL_H__ */
78

source code of include/libnm/nm-device-ip-tunnel.h