NOVA
Stripped down NOVA kernel for the OSY course
Loading...
Searching...
No Matches
include
console.h
1
/*
2
* Generic Console
3
*
4
* Copyright (C) 2009-2011 Udo Steinberg <udo@hypervisor.org>
5
* Economic rights: Technische Universitaet Dresden (Germany)
6
*
7
* This file is part of the NOVA microhypervisor.
8
*
9
* NOVA is free software: you can redistribute it and/or modify it
10
* under the terms of the GNU General Public License version 2 as
11
* published by the Free Software Foundation.
12
*
13
* NOVA is distributed in the hope that it will be useful,
14
* but WITHOUT ANY WARRANTY; without even the implied warranty of
15
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
* GNU General Public License version 2 for more details.
17
*/
18
19
#pragma once
20
21
#include <stdarg.h>
22
#include "compiler.h"
23
#include "types.h"
24
25
class
Console
26
{
27
private
:
28
virtual
void
putc (
int
c) = 0;
29
30
void
print_number (uint64 val,
unsigned
base,
unsigned
width,
unsigned
flags);
31
32
inline
void
print_str (
char
const
*str,
unsigned
width,
unsigned
precs);
33
34
protected
:
35
bool
initialized;
36
37
public
:
38
Console() : initialized (
false
) {}
39
40
FORMAT (2,0)
41
void
vprintf (
char
const
*format, va_list args);
42
};
Generated by
1.14.0