Tweaking api.

This commit is contained in:
curt
2000-07-14 19:15:41 +00:00
parent af383e6c39
commit 9325ec681e
4 changed files with 7 additions and 7 deletions

View File

@@ -36,8 +36,9 @@
FG_USING_STD(string);
SGFile::SGFile() {
SGFile::SGFile( const string &file) {
set_type( sgFileType );
file_name = file;
}

View File

@@ -52,7 +52,7 @@ class SGFile : public SGIOChannel {
public:
SGFile();
SGFile( const string& file );
~SGFile();
// open the file based on specified direction
@@ -74,7 +74,6 @@ public:
bool close();
inline string get_file_name() const { return file_name; }
inline void set_file_name( const string& fn ) { file_name = fn; }
};

View File

@@ -33,10 +33,12 @@
FG_USING_STD(string);
SGSerial::SGSerial() :
SGSerial::SGSerial( const string& device_name, const string& baud_rate ) :
save_len(0)
{
set_type( sgSerialType );
device = device_name;
baud = baud_rate;
}

View File

@@ -57,7 +57,7 @@ class SGSerial : public SGIOChannel {
public:
SGSerial();
SGSerial( const string& device_name, const string& baud_rate );
~SGSerial();
// open the serial port based on specified direction
@@ -79,9 +79,7 @@ public:
bool close();
inline string get_device() const { return device; }
inline void set_device( const string& d ) { device = d; }
inline string get_baud() const { return baud; }
inline void set_baud( const string& b ) { baud = b; }
};