brfile_open_read_cbfn
open_read
member of the br_filesystem
125
structure.
typedef
brfile.h
for a precise declaration)
void* brfile_open_read_cbfn(const char*, br_size_t, br_mode_test_cbfn*, int*)
Name of file.
Number of characters required for
Call-back function that can be used to determine file type given the first
If this argument is non-
Return a file handle or
Specification
Description:
An application defined call-back function to open a file for read access.CBFnFileOpenRead()
void* BR_CALLBACK CBFnFileOpenRead(const char* name, br_size_t n_magics, br_mode_test_cbfn* mode_test, int* mode_result)
const char * name
br_size_t n_magics
mode_test
to determine file type (less than or equal to BR_MAX_FILE_MAGICS
).br_mode_test_cbfn mode_test
n_magics
characters of a file. Will not be used if Null
.int * mode_result
Null
, the file type (if it could be determined) will be stored at the address pointed to.name
, if no path is specified with the file, looks in the current directory, if not found tries, in order, the directories listed in BRENDER_PATH (if defined). Having found the file, use mode_test
(if supplied) to find out if the file is text, binary or unknown. Store the result through mode_result
(if non-Null
). Obtain a handle to the file.void *
Null
if the file could not be opened.stdfile.c
for examples of filing system functions.
Generated with CERN WebMaker