OpenVPN 3 Core Library
Loading...
Searching...
No Matches
bufstatic.hpp
Go to the documentation of this file.
1
// OpenVPN -- An application to securely tunnel IP networks
2
// over a single port, with support for SSL/TLS-based
3
// session authentication and key exchange,
4
// packet encryption, packet authentication, and
5
// packet compression.
6
//
7
// Copyright (C) 2012- OpenVPN Inc.
8
//
9
// SPDX-License-Identifier: MPL-2.0 OR AGPL-3.0-only WITH openvpn3-openssl-exception
10
//
11
12
#pragma once
13
14
#include <
openvpn/buffer/buffer.hpp
>
15
16
namespace
openvpn
{
17
18
// constant-length Buffer for writing that cannot be extended
19
template
<std::
size_t
N>
20
class
StaticBuffer
:
public
Buffer
21
{
22
public
:
23
StaticBuffer
()
24
:
Buffer
(
data
, N, false)
25
{
26
}
27
28
StaticBuffer
(
const
StaticBuffer
&) =
delete
;
29
StaticBuffer
&
operator=
(
const
StaticBuffer
&) =
delete
;
30
31
private
:
32
unsigned
char
data
[N];
33
};
34
35
}
// namespace openvpn
buffer.hpp
openvpn::BufferType< unsigned char >
openvpn::StaticBuffer
Definition
bufstatic.hpp:21
openvpn::StaticBuffer::StaticBuffer
StaticBuffer(const StaticBuffer &)=delete
openvpn::StaticBuffer::data
unsigned char data[N]
Definition
bufstatic.hpp:32
openvpn::StaticBuffer::operator=
StaticBuffer & operator=(const StaticBuffer &)=delete
openvpn::StaticBuffer::StaticBuffer
StaticBuffer()
Definition
bufstatic.hpp:23
openvpn
Definition
ovpncli.cpp:97
openvpn
buffer
bufstatic.hpp
Generated by
1.9.8