1 #ifndef SZA_UTIL_PORT_H
2 #define SZA_UTIL_PORT_H
13 #include "carma/szautil/Vector.h"
21 static const unsigned int MAX_RCV_BUFFER = 300;
25 static const unsigned TELNET_PORT_NO = 23;
59 void writeString(std::string& message,
int fd=-1);
60 void writeBytes(Vector<unsigned char>& buffer);
61 static void writeBytes(Vector<unsigned char>& buffer,
int fd);
66 unsigned int readBytes(
unsigned char *message,
int fd=-1);
67 unsigned int readBytes(Vector<unsigned char>& buffer);
71 unsigned char getNextByte();
76 std::string readString(
int fd=-1);
78 bool concatenateString(std::ostringstream& os,
int fd=-1,
bool cont=
true);
79 void concatenateChar(std::ostringstream& os,
int fd=-1);
80 int getNbyte(
int fd=-1);
86 void terminateAt(std::string strip);
92 void strip(std::string strip);
98 void dontStrip(std::string strip);
103 void stripUnprintable(
bool strip);
108 void append(std::string append);
110 void appendNewline();
111 void appendLinefeed();
113 void appendNothing();
125 void print(
unsigned char);
133 std::vector<unsigned char> appendVec_;
137 String dontStripStr_;
139 bool stripUnprintable_;
146 #endif // End #ifndef SZA_UTIL_PORT_H
Tagged: Wed May 12 09:30:13 PDT 2004.