ROLAND  0.70
Amstrad Emulator based on Caprice Source rewritten in C++.
cmdtabledef.h
Go to the documentation of this file.
1 /***************************************************************************
2  * Copyright (C) 2005 by Fred Klaus *
3  * frednet@web.de *
4  * *
5  * This program is free software; you can redistribute it and/or modify *
6  * it under the terms of the GNU General Public License as published by *
7  * the Free Software Foundation; either version 2 of the License, or *
8  * (at your option) any later version. *
9  * *
10  * This program is distributed in the hope that it will be useful, *
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13  * GNU General Public License for more details. *
14  * *
15  * You should have received a copy of the GNU General Public License *
16  * along with this program; if not, write to the *
17  * Free Software Foundation, Inc., *
18  * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
19  ***************************************************************************/
20 #ifndef CPC_CMDTABLEDEF_H
21 #define CPC_CMDTABLEDEF_H
22 
23 #include "compspec.h"
24 
25 namespace cpcx
26 {
27  class Fdc;
28 
30  class CmdTableDef final
31  {
32  public:
35 
36  typedef void (Fdc::*CmdHandler)(void);
37 
38  void set(int cmd, int cmdlen, int reslen, int cmddir, CmdHandler cmdhandler)
39  {mCmd=cmd; mCmdLength=cmdlen; mResLength=reslen; mCmdDirection=cmddir; mCmdHandler=cmdhandler;}
40 
41  int cmd() const {return mCmd;}
42  int cmdLength() const {return mCmdLength;}
43  int resLength() const {return mResLength;}
44  int cmdDirection() const {return mCmdDirection;}
45  CmdHandler cmdHandler() const {return mCmdHandler;}
46 
47  private:
48  int mCmd;
52  CmdHandler mCmdHandler;
53  };
54 } // namespace cpcx
55 
56 #endif //CPC_CMDTABLEDEF_H
int mResLength
Definition: cmdtabledef.h:50
int resLength() const
Definition: cmdtabledef.h:43
int mCmdDirection
Definition: cmdtabledef.h:51
Comand table definitions.
Definition: cmdtabledef.h:30
Namespace for all CPC components.
Definition: colours.cpp:22
int cmd() const
Definition: cmdtabledef.h:41
CmdHandler cmdHandler() const
Definition: cmdtabledef.h:45
The floppy drive controller.
Definition: fdc.h:34
int cmdLength() const
Definition: cmdtabledef.h:42
CmdHandler mCmdHandler
Definition: cmdtabledef.h:52
int mCmd
Definition: cmdtabledef.h:48
#define ROLAND_DEFAULT
Definition: compspec.h:46
int cmdDirection() const
Definition: cmdtabledef.h:44
int mCmdLength
Definition: cmdtabledef.h:49