rllib  1
rlcommandlineinterface.h
Go to the documentation of this file.
1 /***************************************************************************
2  rlcommandlineinterface.h - description
3  -------------------
4  begin : Sat Mar 27 2010
5  copyright : (C) 2010 by R. Lehrig
6  email : lehrig@t-online.de
7  ***************************************************************************/
8 
9 /***************************************************************************
10  * *
11  * This library is free software; you can redistribute it and/or modify *
12  * it under the terms of the GNU LESSER GENERAL PUBLIC LICENSE as *
13  * published by the Free Software Foundation *
14  * *
15  ***************************************************************************/
16 #ifndef _RL_COMMANDLINE_INTERFACE_H_
17 #define _RL_COMMANDLINE_INTERFACE_H_
18 
19 #include "rldefine.h"
20 #include "rlsocket.h"
21 #include "rlserial.h"
22 #include "rlspawn.h"
23 
43 {
44 public:
46  virtual ~rlCommandlineInterface();
47  int start(const char *how, const char *command=NULL);
48  int start(rlSerial *tty);
49  const char *readLine(int timeout=0);
50  int readBlock(void *buf, int len, int timeout=0);
51  int printf(const char *format, ...);
52  int writeBlock(void *buf, int len);
53 private:
58 };
59 #endif
60 
int printf(const char *format,...)
const char * readLine(int timeout=0)
int start(const char *how, const char *command=NULL)
int writeBlock(void *buf, int len)
#define rl_PRINTF_LENGTH
Definition: rldefine.h:71
int readBlock(void *buf, int len, int timeout=0)
char line[rl_PRINTF_LENGTH]