mirror of
https://github.com/Xevion/easy7zip.git
synced 2025-12-12 01:09:56 -06:00
Initialer Commit
This commit is contained in:
33
CPP/Common/StdInStream.h
Normal file
33
CPP/Common/StdInStream.h
Normal file
@@ -0,0 +1,33 @@
|
||||
// Common/StdInStream.h
|
||||
|
||||
#ifndef __COMMON_STD_IN_STREAM_H
|
||||
#define __COMMON_STD_IN_STREAM_H
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#include "MyString.h"
|
||||
#include "MyTypes.h"
|
||||
|
||||
class CStdInStream
|
||||
{
|
||||
FILE *_stream;
|
||||
bool _streamIsOpen;
|
||||
public:
|
||||
CStdInStream(): _stream(0), _streamIsOpen(false) {};
|
||||
CStdInStream(FILE *stream): _stream(stream), _streamIsOpen(false) {};
|
||||
~CStdInStream() { Close(); }
|
||||
|
||||
bool Open(LPCTSTR fileName) throw();
|
||||
bool Close() throw();
|
||||
|
||||
AString ScanStringUntilNewLine(bool allowEOF = false);
|
||||
void ReadToString(AString &resultString);
|
||||
UString ScanUStringUntilNewLine();
|
||||
|
||||
bool Eof() throw();
|
||||
int GetChar();
|
||||
};
|
||||
|
||||
extern CStdInStream g_StdIn;
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user