19 #ifndef JAMBA_READONLYMEMORYSTREAM_H 20 #define JAMBA_READONLYMEMORYSTREAM_H 22 #include <pluginterfaces/base/ibstream.h> 26 using namespace Steinberg;
37 virtual tresult PLUGIN_API read(
void *buffer, int32 numBytes, int32 *numBytesRead) SMTG_OVERRIDE;
38 virtual tresult PLUGIN_API write(
void *buffer, int32 numBytes, int32 *numBytesWritten) SMTG_OVERRIDE;
39 virtual tresult PLUGIN_API seek(int64 pos, int32 mode, int64 *result) SMTG_OVERRIDE;
40 virtual tresult PLUGIN_API tell(int64 *pos) SMTG_OVERRIDE;
42 TSize
getSize()
const {
return fMemorySize - fPos; };
43 inline char const*
getData()
const {
return fMemory; }
45 inline int64
pos()
const {
return fPos; }
48 DECLARE_FUNKNOWN_METHODS
58 #endif //JAMBA_READONLYMEMORYSTREAM_H Definition: ExpiringDataCache.h:27
TSize fMemorySize
Definition: ReadOnlyMemoryStream.h:52
TSize getMemorySize() const
Definition: ReadOnlyMemoryStream.h:44
TSize getSize() const
Definition: ReadOnlyMemoryStream.h:42
char const * fMemory
Definition: ReadOnlyMemoryStream.h:51
int64 pos() const
returns the total size of the memory
Definition: ReadOnlyMemoryStream.h:45
Definition: ReadOnlyMemoryStream.h:28
int64 fPos
Definition: ReadOnlyMemoryStream.h:53
char const * getData() const
returns the current memory size (how many chars can be read until the end)
Definition: ReadOnlyMemoryStream.h:43