20#ifndef koStoreDevice_h
21#define koStoreDevice_h
40 if ( m & IO_ReadOnly )
41 return ( m_store->mode() == KoStore::Read );
42 if ( m & IO_WriteOnly )
43 return ( m_store->mode() == KoStore::Write );
50 if ( m_store->mode() == KoStore::Read )
51 return m_store->size();
56 virtual TQ_LONG readBlock( char *data, TQ_ULONG maxlen ) { return m_store->read(data, maxlen); }
57 virtual TQ_LONG writeBlock( const char *data, TQ_ULONG len ) { return m_store->write( data, len ); }
59 TQ_LONG writeBlock( const TQByteArray& data ) { return TQIODevice::writeBlock( data ); }
63 if ( m_store->read(c, 1) == -1)
72 if (m_store->write( c, 1 ) == 1)
77 int ungetch( int ) { return -1; }
80 virtual bool at( Offset pos ) { return m_store->at(pos); }
81 virtual Offset at() const { return m_store->at(); }
82 virtual bool atEnd() const { return m_store->atEnd(); }
This class implements a TQIODevice around KoStore, so that it can be used to create a TQDomDocument f...
KoStoreDevice(KoStore *store) Note: KoStore::open() should be called before calling this.
Saves and loads KOffice documents using various backends.
|