The Pedigree Project  0.1
Malta.h
1 /*
2  * Copyright (c) 2008-2014, Pedigree Developers
3  *
4  * Please see the CONTRIB file in the root of the source tree for a full
5  * list of contributors.
6  *
7  * Permission to use, copy, modify, and distribute this software for any
8  * purpose with or without fee is hereby granted, provided that the above
9  * copyright notice and this permission notice appear in all copies.
10  *
11  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
12  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
13  * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
14  * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
15  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
16  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
17  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
18  */
19 
20 #ifndef MACHINE_MALTA_MALTA_H
21 #define MACHINE_MALTA_MALTA_H
22 
23 #include "Keyboard.h"
24 #include "Serial.h"
25 #include "Vga.h"
26 #include "pedigree/kernel/machine/Machine.h"
27 
31 class Malta : public Machine
32 {
33  public:
34  inline static Machine &instance()
35  {
36  return m_Instance;
37  }
38 
39  virtual void initialise();
40  virtual Serial *getSerial(size_t n);
41  virtual size_t getNumSerial();
42  virtual Vga *getVga(size_t n);
43  virtual size_t getNumVga();
44  virtual IrqManager *getIrqManager();
46  virtual Timer *getTimer();
47  virtual Keyboard *getKeyboard();
48 
49  private:
53  Malta();
54  Malta(const Malta &);
55  Malta &operator=(const Malta &);
59  virtual ~Malta();
60 
61  MaltaSerial m_Serial[2];
62  // SchedulerTimer m_SchedulerTimer;
63  // Timer m_Timers;
64  MaltaVga m_Vga;
65  MaltaKeyboard m_Keyboard;
66 
67  static Malta m_Instance;
68 };
69 
70 #endif
virtual size_t getNumVga()
Definition: Malta.cc:50
virtual ~Malta()
Definition: Malta.cc:77
virtual Vga * getVga(size_t n)
Definition: Malta.cc:46
Malta()
Definition: Malta.cc:74
virtual Keyboard * getKeyboard()
Definition: Malta.cc:69
virtual void initialise()
Definition: Malta.cc:30
Definition: Malta.h:31
virtual size_t getNumSerial()
Definition: Malta.cc:42
virtual Serial * getSerial(size_t n)
Definition: Malta.cc:38
virtual SchedulerTimer * getSchedulerTimer()
Definition: Malta.cc:59
virtual Timer * getTimer()
Definition: Malta.cc:64