DebugServer2
Loading...
Searching...
No Matches
Headers
DebugServer2
Host
Channel.h
1
//
2
// Copyright (c) 2014-present, Facebook, Inc.
3
// All rights reserved.
4
//
5
// This source code is licensed under the University of Illinois/NCSA Open
6
// Source License found in the LICENSE file in the root directory of this
7
// source tree. An additional grant of patent rights can be found in the
8
// PATENTS file in the same directory.
9
//
10
11
#pragma once
12
13
#include "DebugServer2/Types.h"
14
15
namespace
ds2 {
16
namespace
Host {
17
18
class
Channel
{
19
public
:
20
virtual
~Channel
() =
default
;
21
22
public
:
23
virtual
void
close() = 0;
24
25
public
:
26
virtual
bool
connected()
const
= 0;
27
28
public
:
29
virtual
bool
wait(
int
ms = -1) = 0;
30
31
public
:
32
virtual
ssize_t send(
void
const
*buffer,
size_t
length) = 0;
33
virtual
ssize_t receive(
void
*buffer,
size_t
length) = 0;
34
35
public
:
36
virtual
bool
send(std::string
const
&buffer);
37
virtual
bool
receive(std::string &buffer);
38
};
39
}
// namespace Host
40
}
// namespace ds2
ds2::Host::Channel
Definition
Channel.h:18
Generated by
1.12.0