PrevNextUpHome SophiaFramework UNIVERSE 5.3

18.1. Overview of the Storage

The Storage classes is for reading / writing data from / into file, network, memory and so on using the stream. In SophiaFramework UNIVERSE, 6 kinds of storage classes are available as follows:

Table 18.1. Storage Classes

Class Name Description
SFXFile Class for operating a file.
SFXHTTPConnection Class for the HTTP communication.
SFXTCPSocket Class for the TCP socket communication.
SFXSSLSocket Class for the SSL socket communication.
SFXMemory Storage class for the memory stream.
SFXSource Storage class for reading data from the ISource interface.
SFXZIPDecoder Storage class for decompressing the DEFLATE compressed data by gzip.
[Note] Note

All storage classes above inherit from the SFXStorage class.

Since the input/output method using the stream is almost same with all storages except the following differences, generic programming independent of storage devices can be implemented in SophiaFramework UNIVERSE.

Table 18.2. Table for Read/Write Function with or without Callback Function on Storage Classes

  read without callback function read with callback function write without callback function write with callback function
SFXFile O O O X
SFXHTTPConnection X O X O
SFXTCPSocket X O X O
SFXSSLSocket X O X O
SFXMemory O X O X
SFXSource Depend on the BREW ISource O X X
SFXZIPDecoder Depend on the registered storage O X X
[Note] Note

In the SFXSource / SFXZIPDecoder class, read function without callback function is not available for some kinds of source and registered storage.

For instance, since read function without callback function on SFXTCPSocket is not available, gzipped data from SFXTCPSocket cannot be decompressed by registering it in SFXZIPDecoder without callback function.