Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/libcfa/fstream

    r6ba0659 r53ba273  
    77// fstream --
    88//
    9 // Author           : Richard C. Bilson
     9// Author           : Peter A. Buhr
    1010// Created On       : Wed May 27 17:56:53 2015
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Wed Feb 17 14:02:01 2016
    13 // Update Count     : 22
     12// Last Modified On : Tue Apr  5 22:37:12 2016
     13// Update Count     : 82
    1414//
    1515
     
    1919#include "iostream"
    2020
    21 // implement context ostream
    22 struct ofstream;
     21enum { separateSize = 16 };
     22struct ofstream {
     23        void *file;
     24        _Bool sepDefault;
     25        _Bool sepOnOff;
     26        char separator[separateSize];
     27}; // ofstream
    2328
    24 int fail( ofstream * os );
    25 int flush( ofstream * os );
    26 void open( ofstream ** os, const char * name, const char * mode );
    27 void close( ofstream * os );
    28 ofstream * write( ofstream * os, const char * data, streamsize_type size );
     29_Bool sepPrt( ofstream * );
     30void sepOn( ofstream * );
     31void sepOff( ofstream * );
     32void sepReset( ofstream * );
     33void sepReset( ofstream *, _Bool );
     34void sepSet( ofstream *, const char * );
     35const char * sepGet( ofstream * );
     36_Bool sepDisable( ofstream * );
     37_Bool sepEnable( ofstream * );
     38int fail( ofstream * );
     39int flush( ofstream * );
     40void open( ofstream *, const char * name, const char * mode );
     41void close( ofstream * );
     42ofstream * write( ofstream *, const char * data, unsigned long int size );
     43int prtfmt( ofstream *, const char fmt[], ... );
    2944
    3045extern ofstream * sout, * serr;
    3146
    3247// implement context istream
    33 struct ifstream;
     48struct ifstream {
     49        void *file;
     50}; // ifstream
    3451
    3552int fail( ifstream * is );
    3653int eof( ifstream * is );
    37 void open( ifstream ** is, const char * name, const char * mode );
     54void open( ifstream * is, const char * name, const char * mode );
    3855void close( ifstream * is );
    39 ifstream * get( ifstream * is, int * data );
    40 ifstream * read( ifstream * is, char * data, streamsize_type size );
     56ifstream * read( ifstream * is, char * data, unsigned long int size );
    4157ifstream * ungetc( ifstream * is, char c );
     58int scanfmt( ifstream *, const char fmt[], ... );
    4259
    4360extern ifstream *sin;
     
    4966// tab-width: 4 //
    5067// End: //
     68
Note: See TracChangeset for help on using the changeset viewer.