Introduction to store streams

Store streams provide concrete stream types suitable for use in stores. The API is based on the stream interfaces defined by the Streaming API.

Streams are usually created in the context of a store . Objects can be externalised to any store type, and then later re-internalised.

Various types of stream are possible, such as streams which do encryption/decryption, or streams which convey data over a communications channel. Because the stream interface is polymorphic, ExternalizeL() and InternalizeL() functions work with any stream type.

Streams within stores are encapsulated by one of two concrete classes:

  • RStoreWriteStream represents a stream which is being written. The class supports the creation and manipulation of a stream in a store.

  • RStoreReadStream represents a stream which is being read. The class supports the opening and manipulation of an existing stream in a store.

Both concrete classes are derived from their respective abstract base classes, the write stream interface RWriteStream , and the read stream interface RReadStream .

A stream which is being written is referred to as a write stream while a stream which is being read is referred to as a read stream .

Applications must construct and open an RStoreReadStream object before they can read from a store stream and they must must construct an RStoreWriteStream object before they can write to a store stream.

Although an application constructs RStoreWriteStream and RStoreReadStream objects to represent streams in a store, application objects only need to refer to the RWriteStream and RReadStream base classes, when externalising or internalising themselves to the stream.