MicrOS
|
Object containing information to control a stream. More...
#include <stdio.h>
Public Attributes | |
char | filename [FILENAME_MAX] |
Full path of the file (can be empty if stream is assigned to some hardware device). More... | |
file_mode | mode |
char * | buffer |
Stream buffer. More... | |
uint32_t | base |
Position of the buffer start in the stream. More... | |
uint32_t | pos |
Current position in the stream. More... | |
uint32_t | size |
Position of the buffer end in the stream. More... | |
uint32_t | limit |
Total size of the stream (can be 0 if it's undefined like console or keyboard). More... | |
uint32_t | error |
Error code. More... | |
file_buffering_mode | buffering_mode |
Buffering mode of the stream. More... | |
int(* | fetch )(struct file *file) |
Function which loads chunk of the data from stream and stores it to the buffer. More... | |
void(* | flush )(struct file *file) |
Function which gets data from the buffer and sends it to the output (and removes it from the buffer). More... | |
Object containing information to control a stream.
Object type that identifies a stream and contains the information needed to control it, including a pointer to its buffer, its position indicator and all its state indicators. !
uint32_t FILE::base |
Position of the buffer start in the stream.
char* FILE::buffer |
Stream buffer.
file_buffering_mode FILE::buffering_mode |
Buffering mode of the stream.
uint32_t FILE::error |
Error code.
int(* FILE::fetch) (struct file *file) |
Function which loads chunk of the data from stream and stores it to the buffer.
char FILE::filename[FILENAME_MAX] |
Full path of the file (can be empty if stream is assigned to some hardware device).
void(* FILE::flush) (struct file *file) |
Function which gets data from the buffer and sends it to the output (and removes it from the buffer).
uint32_t FILE::limit |
Total size of the stream (can be 0 if it's undefined like console or keyboard).
file_mode FILE::mode |
uint32_t FILE::pos |
Current position in the stream.
uint32_t FILE::size |
Position of the buffer end in the stream.