Update of /cvsroot/rtk/rtk/rtk
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16186/rtk
Modified Files:
Buffer.h
Log Message:
Few new methods added.
Index: Buffer.h
===================================================================
RCS file: /cvsroot/rtk/rtk/rtk/Buffer.h,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** Buffer.h 11 Jun 2004 15:35:53 -0000 1.5
--- Buffer.h 11 Jun 2004 16:50:58 -0000 1.6
***************
*** 51,54 ****
--- 51,58 ----
#include <rtk/rtkdef.h>
+ #if _DEBUG
+ #include <rtk/String.h>
+ #endif
+
namespace Rtk
{
***************
*** 58,64 ****
class RTK_API Buffer
{
! uchar* _data;
! uint _allocated;
! uint _size;
/**
--- 62,68 ----
class RTK_API Buffer
{
! uchar* _data; /// Internal pointer to Buffer memory-block.
! uint _allocated; /// Size of Buffer object in bytes.
! uint _size; /// Number of data-bytes in Buffer object.
/**
***************
*** 74,78 ****
Buffer():_size(0)
{
! _data = new uchar[_allocated = RTK_BUFFER_SIZE];
}
--- 78,83 ----
Buffer():_size(0)
{
! _data = (uchar*) malloc(_allocated = RTK_BUFFER_SIZE);
! Fill('\0');
}
***************
*** 105,108 ****
--- 110,120 ----
*/
void Write(const uchar* arg_byte_array, uint arg_num);
+
+ void Buffer::Fill(uchar arg_char);
+
+ #if _DEBUG
+ void FromFile(const String& arg_fname);
+ void ToFile(const String& arg_fname) const;
+ #endif
}; // Buffer
}; // Rtk namespace
|