#include <Interfaces.h>
Inherits DigitalSpaces::DIObjectBase.
Public Member Functions | |
| unsigned int | GetCharacters (char *buffer, unsigned int buffersize) |
| Retreive up to buffersize of characters into the target buffer. | |
| unsigned long | GetResourceSize () |
| Returns the size (in bytes) of the data resource. | |
| unsigned long | GetPosition () |
| Returns the current position (in bytes) that GetCharacters will return data from. | |
| bool | SeekResource (unsigned long position) |
| Alters the current position (in bytes) that GetCharacters will return data from. | |
| unsigned int DigitalSpaces::DIDataResource::GetCharacters | ( | char * | buffer, | |
| unsigned int | buffersize | |||
| ) |
Retreive up to buffersize of characters into the target buffer.
Depending on the implementation and the state of the current resource, the number returned from GetCharacters may not be the full size of the buffer. However it will return at least 1 character. If 0 is returned, there is no longer any data available at all. Implementations of this interface that are streaming the data resource should halt until at least one character is available, as returning 0 will indicate no more data is available.
| [out] | buffer | A contiguous buffer of memory |
| buffersize | The size of the buffer available at buffer. |
| unsigned long DigitalSpaces::DIDataResource::GetResourceSize | ( | ) |
Returns the size (in bytes) of the data resource.
| unsigned long DigitalSpaces::DIDataResource::GetPosition | ( | ) |
Returns the current position (in bytes) that GetCharacters will return data from.
This will be between 0 and the resource size, as returned by GetResourceSize.
| bool DigitalSpaces::DIDataResource::SeekResource | ( | unsigned long | position | ) |
Alters the current position (in bytes) that GetCharacters will return data from.
| position | The position in the resource to return data from. This is an absolute address, specifically, is is the 0 based index, and not relative to the current position at all. |
1.5.6