33 #ifndef _HUGE_FILE_HPP_INCLUDED_
34 #define _HUGE_FILE_HPP_INCLUDED_
66 const char* m_memory =
nullptr;
67 std::streampos m_filesize = 0;
76 bool IsOpen()
const {
return m_filesize != 0; }
77 TTypeInfo RecognizeContent(std::streampos pos);
78 TTypeInfo RecognizeContent(std::istream& istr);
79 unique_ptr<CObjectIStream> MakeObjStream(std::streampos pos = 0)
const;
82 bool x_TryOpenStreamFile(
const string& filename, std::streampos filesize);
83 bool x_TryOpenMemoryFile(
const string& filename);
NCBI_EXCEPTION_DEFAULT(CHugeFileException, CException)
std::unique_ptr< CMemoryFile > m_memfile
std::unique_ptr< std::istream > m_stream
std::unique_ptr< std::streambuf > m_streambuf
CTypeInfo class contains all information about C++ types (both basic and classes): members and layout...
virtual void Open(CHugeFile *file, ILineErrorListener *pMessageListener)=0
virtual CRef< CSeq_entry > GetNextSeqEntry()=0
virtual bool GetNextBlob()=0
virtual CConstRef< CSubmit_block > GetSubmitBlock() const =0
virtual bool IsMultiSequence() const =0
virtual ~IHugeAsnSource()
Include a standard set of the NCBI C++ Toolkit most basic headers.
EErrCode
Error types that an application can generate.
ESerialDataFormat
Data file format.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define END_SCOPE(ns)
End the previously defined scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
#define BEGIN_SCOPE(ns)
Define a new scope.
#define NCBI_XHUGEASN_EXPORT
Portable reference counted smart and weak pointers using CWeakRef, CRef, CObject and CObjectEx.