![]() |
YAP 7.1.0
|
main open and close predicates over generic streams More...
#include "Yap.h"#include "YapEval.h"#include "YapHeap.h"#include "YapText.h"#include "Yatom.h"#include "yapio.h"#include "sysbits.h"#include <stdlib.h>#include "iopreds.h"#include "getw.h"Go to the source code of this file.
Macros | |
| #define | strncat(X, Y, Z) strcat(X, Y) |
| #define | strncpy(X, Y, Z) strcpy(X, Y) |
| #define | MB_LEN_MAX 6 |
| #define | OPEN_DEFS() |
| #define | PAR(x, y, z) z |
| #define | PAR(x, y, z) { x, y, z } |
| #define | CheckStream(arg, kind, msg) CheckStream__(__FILE__, __FUNCTION__, __LINE__, arg, kind, msg) |
| #define | CLOSE_DEFS() PAR("force", booleanFlag, CLOSE_FORCE), PAR(NULL, ok, CLOSE_END) |
| #define | PAR(x, y, z) z |
| #define | PAR(x, y, z) { x, y, z } |
Typedefs | |
| typedef enum open_enum_choices | open_choices_t |
| typedef enum close_enum_choices | close_choices_t |
Enumerations | |
| enum | open_enum_choices { OPEN_DEFS =() , READ_DEFS =() } |
| enum | close_enum_choices { CLOSE_DEFS =() } |
Functions | |
| char * | Yap_VF (const char *path) |
| char * | Yap_VFAlloc (const char *path) |
| int | ResetEOF (StreamDesc *s) |
| void | Yap_DefaultStreamOps (StreamDesc *st) |
| void | Yap_InitStdStream (int sno, unsigned int flags, FILE *file, VFS_t *vfsp) |
| Term | Yap_StreamUserName (int sno) |
| void | Yap_InitStdStreams (void) |
| Int | PlIOError__ (const char *file, const char *function, int lineno, yap_error_number type, Term culprit,...) |
| bool | UnixIOError__ (const char *file, const char *function, int lineno, int error, io_kind_t io_type, Term culprit,...) |
| void | Yap_DebugSetIFile (char *fname) |
| void | Yap_DebugEndline () |
| int | Yap_DebugGetc () |
| int | Yap_DebugPutc (FILE *s, wchar_t ch) |
| int | Yap_DebugPuts (FILE *s, const char *sch) |
| void | Yap_DebugErrorPuts (const char *s) |
| void | Yap_DebugPlWrite (Term t) |
| void | Yap_DebugPlWriteln (Term t) |
| void | Yap_DebugErrorPutc (int c) |
| void | Yap_DebugWriteIndicator (PredEntry *ap) |
| int | FilePutc (int sno, int ch) |
| int | console_post_process_eof (StreamDesc *s) |
| int | post_process_read_wchar (int ch, size_t n, StreamDesc *s) |
| int | post_process_weof (StreamDesc *s) |
| void * | Yap_RepStreamFromId (int sno) |
| int | EOFPeek (int sno) |
| caled after EOF found a peek, it just calls console_post_process to conclude the job More... | |
| int | EOFWPeek (int sno) |
| int | PlGetc (int sno) |
| int | put_wchar (int sno, wchar_t ch) |
| int | Yap_PlGetchar (void) |
| int | Yap_PlGetWchar (void) |
| int | Yap_PlFGetchar (void) |
| Term | Yap_MkStream (int n) |
| Int | GetStreamFd (int sno) |
| Int | Yap_GetStreamFd (int sno) |
| bool | Yap_initStream__ (const char *file, const char *f, int line, int sno, FILE *fd, Atom name, const char *io_mode, Term file_name, encoding_t encoding, stream_flags_t flags, void *vfs) |
| int | Yap_OpenStream (Term tin, const char *io_mode, Term user_name, encoding_t enc) |
| int | Yap_FileStream (FILE *fd, Atom name, Term file_name, int flags, VFS_t *vfsp) |
| int | Yap_CheckStream__ (const char *file, const char *f, int line, Term arg, int kind, const char *msg) |
| int | Yap_CheckTextStream__ (const char *file, const char *f, int line, Term arg, int kind, const char *msg) |
| int | Yap_CheckTextWriteStream__ (const char *file, const char *f, int line, Term arg, const char *msg) |
| int | Yap_CheckTextReadStream__ (const char *file, const char *f, int line, Term arg, const char *msg) |
| int | Yap_CheckBinaryStream__ (const char *file, const char *f, int line, Term arg, int kind, const char *msg) |
| int | Yap_GetFreeStreamDForReading (void) |
| Term | read_line (int sno) |
| void | Yap_InitPlIO (struct yap_boot_params *argi) |
| void | Yap_InitIOPreds (void) |
Variables | |
| FILE * | Yap_stdin |
| FILE * | Yap_stdout |
| FILE * | Yap_stderr |
| FILE * | curfile |
| FILE * | Yap_logfile |
| bool | Yap_Option [256] |
main open and close predicates over generic streams
Definition in file iopreds.c.
| #define CheckStream | ( | arg, | |
| kind, | |||
| msg | |||
| ) | CheckStream__(__FILE__, __FUNCTION__, __LINE__, arg, kind, msg) |
| #define CLOSE_DEFS | ( | ) | PAR("force", booleanFlag, CLOSE_FORCE), PAR(NULL, ok, CLOSE_END) |
| #define OPEN_DEFS | ( | ) |
| int console_post_process_eof | ( | StreamDesc * | s | ) |
| int EOFPeek | ( | int | sno | ) |
| Int PlIOError__ | ( | const char * | file, |
| const char * | function, | ||
| int | lineno, | ||
| yap_error_number | type, | ||
| Term | culprit, | ||
| ... | |||
| ) |
| int post_process_read_wchar | ( | int | ch, |
| size_t | n, | ||
| StreamDesc * | s | ||
| ) |
| int post_process_weof | ( | StreamDesc * | s | ) |
| int ResetEOF | ( | StreamDesc * | s | ) |
| bool UnixIOError__ | ( | const char * | file, |
| const char * | function, | ||
| int | lineno, | ||
| int | error, | ||
| io_kind_t | io_type, | ||
| Term | culprit, | ||
| ... | |||
| ) |
| int Yap_CheckBinaryStream__ | ( | const char * | file, |
| const char * | f, | ||
| int | line, | ||
| Term | arg, | ||
| int | kind, | ||
| const char * | msg | ||
| ) |
| int Yap_CheckStream__ | ( | const char * | file, |
| const char * | f, | ||
| int | line, | ||
| Term | arg, | ||
| int | kind, | ||
| const char * | msg | ||
| ) |
| int Yap_CheckTextReadStream__ | ( | const char * | file, |
| const char * | f, | ||
| int | line, | ||
| Term | arg, | ||
| const char * | msg | ||
| ) |
| int Yap_CheckTextStream__ | ( | const char * | file, |
| const char * | f, | ||
| int | line, | ||
| Term | arg, | ||
| int | kind, | ||
| const char * | msg | ||
| ) |
| int Yap_CheckTextWriteStream__ | ( | const char * | file, |
| const char * | f, | ||
| int | line, | ||
| Term | arg, | ||
| const char * | msg | ||
| ) |
| void Yap_DefaultStreamOps | ( | StreamDesc * | st | ) |
| void Yap_InitPlIO | ( | struct yap_boot_params * | argi | ) |
| void Yap_InitStdStream | ( | int | sno, |
| unsigned int | flags, | ||
| FILE * | file, | ||
| VFS_t * | vfsp | ||
| ) |
| bool Yap_initStream__ | ( | const char * | file, |
| const char * | f, | ||
| int | line, | ||
| int | sno, | ||
| FILE * | fd, | ||
| Atom | name, | ||
| const char * | io_mode, | ||
| Term | file_name, | ||
| encoding_t | encoding, | ||
| stream_flags_t | flags, | ||
| void * | vfs | ||
| ) |
| int Yap_OpenStream | ( | Term | tin, |
| const char * | io_mode, | ||
| Term | user_name, | ||
| encoding_t | enc | ||
| ) |