#ifndef CFILESTREAM_H__
#define CFILESTREAM_H__ 1
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <memory>
#include "p6xjr.h"
{
public:
{
return m_cRef++;
}
{
if(0 == (tmp = (--m_cRef))) { delete this; }
return tmp;
}
{
CFileStream *pObj = NULL;
if (NULL != (pObj = new (std::nothrow) CFileStream() ))
{
if (
P6FAILED( err = pObj->queryInterface( iid, ppIface )))
delete pObj;
}
return err;
}
CFileStream() : m_cRef( 0 ),
m_bInitialized( false ),
m_pFile( NULL ),
m_pFilePath( NULL ) {}
virtual ~CFileStream();
protected:
FILE* m_pFile;
};
#endif