ihelper.h

来自「GIS地理信息系统开发。大名鼎鼎的MAPX+C++软件开发」· C头文件 代码 · 共 57 行

H
57
字号
/* This sample application and corresponding sample code is provided 
 * for example purposes only.  It has not undergone rigorous testing 
 * and as such should not be shipped as part of a final application 
 * without extensive testing on the part of the organization releasing 
 * the end-user product.
 */

#ifndef IHELPER_H
#define IHELPER_H

// Helpers for use of the IStorage and IStream interfaces.

CString ReadStream(IStorage* stg, 
				const CString streamName, 
				long size = 0) /*throw (CFileException*)*/;

CString ReadStream(IStream* stream, 
				long size = 0) /*throw (CFileException*)*/;

IStream* OpenStream(IStorage* stg, 
					const CString streamName, 
					bool write = false) /*throw (CFileException*)*/;

IStream* CreateStream(IStorage* stg, 
					  const CString name) /*throw (CFileException*)*/;

void CreateStream(IStorage* stg, 
					  const CString name, 
					  const CString value) /*throw (CFileException*)*/;

void WriteStream(IStream* outStream, 
				 const CString value) /*throw (CFileException*)*/;

void CloseStream(IStream* stream);

long GetStreamSize(IStream* stream) /*throw (CFileException*)*/;

IStorage* OpenSubstorage(IStorage* stg, 
						 const CString substgName, 
						 bool write = FALSE) /*throw (CFileException*)*/;

IStorage* CreateSubstorage(IStorage* stg, 
						   const CString substgName) /*throw (CFileException*)*/;

IStorage* CreateStorage(const CString path) /*throw (CFileException*)*/;

IStorage* OpenStorage(const CString path, 
					  bool write = FALSE) /*throw (CFileException*)*/;

void SaveStorage(IStorage* stg);

// for storage or substorage
void CloseStorage(IStorage* stg) /*throw (CFileException*)*/;

void EnumElementNames(CStringList* names, IStorage* stg) /*throw (CFileException*)*/;

#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?