FreeNOS
lib
libfs
DeviceLog.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2019 Niek Linnenbank
3
*
4
* This program is free software: you can redistribute it and/or modify
5
* it under the terms of the GNU General Public License as published by
6
* the Free Software Foundation, either version 3 of the License, or
7
* (at your option) any later version.
8
*
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
13
*
14
* You should have received a copy of the GNU General Public License
15
* along with this program. If not, see <http://www.gnu.org/licenses/>.
16
*/
17
18
#ifndef __LIB_LIBFS_DEVICELOG_H
19
#define __LIB_LIBFS_DEVICELOG_H
20
21
#include <
Log.h
>
22
#include <
Types.h
>
23
#include "
Device.h
"
24
38
class
DeviceLog
:
public
Log
39
{
40
public
:
41
47
DeviceLog
(
Device
& device);
48
49
protected
:
50
56
virtual
void
write
(
const
char
*str);
57
58
private
:
59
61
Device
&
m_device
;
62
};
63
69
#endif
/* __LIB_LIBFS_DEVICELOG_H */
DeviceLog
Generic logger that writes to a Device object.
Definition:
DeviceLog.h:38
Device.h
Types.h
Device
Abstract device class interface.
Definition:
Device.h:35
Log.h
Log
Logging class.
Definition:
Log.h:96
DeviceLog::m_device
Device & m_device
Device instance.
Definition:
DeviceLog.h:61
DeviceLog::DeviceLog
DeviceLog(Device &device)
Constructor.
Definition:
DeviceLog.cpp:23
DeviceLog::write
virtual void write(const char *str)
Write a string to the Device one character at a time.
Definition:
DeviceLog.cpp:28
Generated by
1.8.17