32#ifndef _QORE_FILEINPUTSTREAM_H
33#define _QORE_FILEINPUTSTREAM_H
36#include "qore/InputStream.h"
52 return "FileInputStream";
57 return f.
read(ptr, limit, timeout, xsink);
63 size_t rc = f.
read(&c, 1, -1, xsink);
72 DLLLOCAL
QoreFile& getFile() {
return f; }
74 DLLLOCAL
int64 getTimeout()
const {
return timeout; }
container for holding Qore-language exception information and also for registering a "thread_exit" ca...
Definition: ExceptionSink.h:48
provides controlled access to file data through Qore data structures
Definition: QoreFile.h:66
DLLEXPORT size_t getPos()
returns the absolute byte position in the file
DLLEXPORT QoreStringNode * read(qore_offset_t size, ExceptionSink *xsink)
reads string data from the file and returns the string read (caller owns the reference count returned...
DLLEXPORT size_t setPos(size_t pos)
sets the absolute file position to "pos"
DLLEXPORT int open2(ExceptionSink *xsink, const char *fn, int flags=O_RDONLY, int mode=0777, const QoreEncoding *cs=QCS_DEFAULT)
opens the file and raises a Qore-language exception if an error occurs
DLLEXPORT const char * getBuffer() const
returns the string's buffer; this data should not be changed
Qore's string value type, reference counted, dynamically-allocated only.
Definition: QoreStringNode.h:50
long long int64
64bit integer type, cannot use int64_t here since it breaks the API on some 64-bit systems due to equ...
Definition: common.h:260