00001 /* 00002 FALCON - The Falcon Programming Language. 00003 FILE: rosstream.h 00004 00005 Definition of read only string stream. 00006 ------------------------------------------------------------------- 00007 Author: Giancarlo Niccolai 00008 Begin: sab ago 19 2006 00009 00010 ------------------------------------------------------------------- 00011 (C) Copyright 2004: the FALCON developers (see list in AUTHORS file) 00012 00013 See LICENSE file for licensing details. 00014 */ 00015 00020 #ifndef flc_rosstream_H 00021 #define flc_rosstream_H 00022 00023 #include <falcon/stringstream.h> 00024 00025 namespace Falcon { 00026 00044 class FALCON_DYN_CLASS ROStringStream: public StringStream 00045 { 00046 public: 00047 ROStringStream( const String &source ); 00048 ROStringStream( const char *source, int size = -1 ); 00049 ROStringStream( const ROStringStream &other ); 00050 00051 virtual ~ROStringStream() { close(); } 00052 00053 virtual bool close(); 00054 virtual int32 write( const void *buffer, int32 size ); 00055 virtual int32 write( const String &source ); 00056 virtual int32 writeAvailable( int32 msecs, const Falcon::Sys::SystemData* ); 00057 virtual bool truncate( int64 pos=-1 ); 00058 virtual FalconData *clone() const; 00059 }; 00060 00061 } 00062 00063 #endif 00064 00065 /* end of rosstream.h */