Rogus_McBogus
A Rogus_McBogus object handles initialization and clean-up of the Rogus
Library.
class Rogus_McBogus {
public:
class exception { };
user_prefs up;
text_win tw;
err_and_warn ew;
scheduler s;
MIDIsvc o;
Rogus_McBogus(user_prefs);
~Rogus_McBogus();
void setParser(parserPtr, const char*);
const char* version();
};
- Rogus_McBogus(user_prefs)
- This creates a new Rogus_McBogus object, initializing the Rogus Library.
Only one Rogus_McBogus object may exist at one time.
- void setParser(parserPtr p, const char* n)
- This allows the current parser to be set. p is the new parser,
and n is the name of the new parser. The current parser is the
object to which Rogus passes MIDI input.
- const char* version()
- Returns a pointer to a string containing the version number of the
library, with "DEBUG" appended if it is the debug configuration
- user_prefs up
- The user preferences object
- text_win tw
- The text window object
- err_and_warn ew
- The text messaging object, for error, warning, and informative messages.
Relies upon the text window object for output.
- scheduler s
- The scheduler object
- MIDIsvc o
- The MIDI services object
user_prefs
class user_prefs {
public:
Bool statistics_on;
Bool running_status_on;
char default_input[default_input_max_len];
char default_output[default_output_max_len];
char midiators[midiators_max_len];
text_win::outfn *rmfp;
user_prefs();
};
- user_prefs()
- This creates a new user_prefs object using system defaults as defined
below.
statistics_on = True;
running_status_on = False;
strcpy(default_input,"sound blaster");
strcpy(default_output,"sound blaster");
strcpy(midiators,"");
rmfp = NULL;
- Bool statistics_on
- Determines whether Rogus gathers statistics on each parser used and
writes them to the file "Rogus.log".
- Bool running_status_on
- Determines whether Rogus attempts to use running status. It is still
up to the driver to implement its own running status policy.
- char default_input[default_input_max_len]
- Specifies a substring of the name of the node to be used as the default
input.
- char default_output[default_output_max_len]
- Specifies a substring of the name of the node to be used as the default
output.
- char midiators[midiators_max_len]
- A string containing COM port numbers of any MIDIators present, for
instance "13" for Midiators on COM1 & COM3.
- text_win::outfn *rmfp
- A function to be used as the default text output function. Its first
argument is the message to print, and the second argument is one of text_win::info,
text_win::warn, or text_win::err, to indicate the type of message. If func
is NULL, then a default output routine is used. Under Windows NT, this
default output routine sends the output to the console associated with
the process. If no console is associated with the process, one is created.