Jpp 19.3.0-rc.1
the software that should make you happy
Loading...
Searching...
No Matches
JBinaryIO.hh
Go to the documentation of this file.
1#ifndef __JLANG__JBINARYIO__
2#define __JLANG__JBINARYIO__
3
4
5/**
6 * \author mdejong
7 */
8
9namespace JLANG {}
10namespace JPP { using namespace JLANG; }
11
12namespace JLANG {
13
14
15 /**
16 * Interface for binary input.
17 */
19 public:
20 /**
21 * Virtual destructor.
22 */
23 virtual ~JBinaryInput()
24 {}
25
26
27 /**
28 * Read byte array.
29 *
30 * \param buffer pointer to byte array
31 * \param length number of bytes
32 * \return number of bytes read
33 */
34 virtual int read(char* buffer, const int length) = 0;
35 };
36
37
38 /**
39 * Interface for binary output.
40 */
42 public:
43 /**
44 * Virtual destructor.
45 */
47 {}
48
49
50 /**
51 * Write byte array.
52 *
53 * \param buffer pointer to byte array
54 * \param length number of bytes
55 * \return number of bytes written
56 */
57 virtual int write(const char* buffer, const int length) = 0;
58 };
59}
60
61#endif
Interface for binary input.
Definition JBinaryIO.hh:18
virtual ~JBinaryInput()
Virtual destructor.
Definition JBinaryIO.hh:23
virtual int read(char *buffer, const int length)=0
Read byte array.
Interface for binary output.
Definition JBinaryIO.hh:41
virtual ~JBinaryOutput()
Virtual destructor.
Definition JBinaryIO.hh:46
virtual int write(const char *buffer, const int length)=0
Write byte array.
Auxiliary classes and methods for language specific functionality.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).