00001 /**************************************************************************\ 00002 * 00003 * FILE: StringRecord.h 00004 * 00005 * This source file is part of DIME. 00006 * Copyright (C) 1998-1999 by Systems In Motion. All rights reserved. 00007 * 00008 * This library is free software; you can redistribute it and/or modify it 00009 * under the terms of the GNU General Public License, version 2, as 00010 * published by the Free Software Foundation. 00011 * 00012 * This library is distributed in the hope that it will be useful, but 00013 * WITHOUT ANY WARRANTY; without even the implied warranty of 00014 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00015 * General Public License (the accompanying file named COPYING) for more 00016 * details. 00017 * 00018 ************************************************************************** 00019 * 00020 * If you need DIME for a non-GPL project, contact Systems In Motion 00021 * to acquire a Professional Edition License: 00022 * 00023 * Systems In Motion http://www.sim.no/ 00024 * Prof. Brochs gate 6 sales@sim.no 00025 * N-7030 Trondheim Voice: +47 22114160 00026 * NORWAY Fax: +47 67172912 00027 * 00028 \**************************************************************************/ 00029 00030 #ifndef DIME_STRINGRECORD_H 00031 #define DIME_STRINGRECORD_H 00032 00033 #include <dime/records/Record.h> 00034 00035 class dimeStringRecord : public dimeRecord 00036 { 00037 public: 00038 dimeStringRecord(const int group_code = 0); 00039 virtual ~dimeStringRecord(); 00040 00041 virtual dimeRecord *copy(dimeMemHandler * const mh) const; 00042 virtual void setValue(const dimeParam ¶m, dimeMemHandler * const memhandler = NULL); 00043 virtual void getValue(dimeParam ¶m) const; 00044 00045 void setStringPointer(char * const s); 00046 bool setString(const char * const s, 00047 dimeMemHandler * const memhandler = NULL); 00048 char *getString(); 00049 00050 public: 00051 bool isEndOfSectionRecord() const; 00052 bool isEndOfFileRecord() const; 00053 int typeId() const; 00054 bool read(dimeInput * const in); 00055 bool write(dimeOutput * const out); 00056 00057 protected: 00058 char *string; 00059 00060 }; // class dimeStringRecord 00061 00062 #endif // ! DIME_STRINGRECORD_H 00063