Public Member Functions
|virtual void||opened (FILE *pFileHandle, WinFileSys *pFileSys)|
|virtual int32||close ()|
|virtual int32||getVersion ()|
|virtual int32||read (uint8 *buffer, const int32 count)|
|virtual int32||write (uint8 *buffer, const int32 count)|
|virtual int32||ioCtl (uint32 cmd, void *arg)|
|virtual int32||seek (uint32 offset, SeekWhenceEnum whence)|
|virtual void||flush ()|
Interface to a file as used in the apparatus services framework.
Construction, destruction Constructs a new file. Nothing more (no opening, configuring etc.)
Destructs a file. Closes it if needed.
|virtual int32 ApparatusFramework::WinFile::close||(||)||
interface methods Closes the file, releases resources used for the operation. After another open, the file is ready for access again.
|virtual void ApparatusFramework::WinFile::flush||(||)||
Writes all internally buffered data onto the file and clears the write and read buffers.
|virtual int32 ApparatusFramework::WinFile::getVersion||(||)||
This method is not supported by the windows file system and will always return 0.
Universal method that may be used to configure the device and implement functionality not provided by the interface. The meaning of the different commands executed by this function is entirely device dependent (cmd 1 on device A may be something completely different on device B).
|cmd||A command that specifies the function to be executed by the method|
|arg||A pointer to an argument passed to the function to be executed|
|virtual void ApparatusFramework::WinFile::opened||(||FILE *||pFileHandle,|
Tells the file that is has been opened, used by the corresponding file system.
|pFileHandle||The handle as provided by the windows file system|
|pFileSys||Pointer to the windows file system. Used to notify close.|
Reads a specified number of characters from the file into a provided buffer. This read method for a file is usually implemented blocking (blocks the calling client).
|buffer||Pointer to a character buffer. Its the buffer that read will use to fill in the fetched data.|
|count||Number of characters to be read (does not necessarily correspond with the return value).|
Allows to jump to a certain position. Seek uses an offset that specifies the location from a certain starting point. (e.g. used in files to write onto a specified position). Seek may also be used to find the size of a file (return value of seek(0, SEEK_END)).
|offset||A number that specifies the amount of chars the wanted position is away from a given starting position (whence defines that).|
|whence||Defines the starting position or how the given index should be interpreted. See SeekWhenceEnum|
Writes a specified number of characters from a buffer onto the file.
|buffer||Pointer to a character buffer. Its the buffer that write takes as data source.|
|count||Number of characters to be taken out of the buffer onto the file.|
© 2004-2010 bbv Software Services AG / Apparatus Services