Mercurial > vba-linux
diff src/win32/7zip/7z/CPP/7zip/Common/RegisterArc.h @ 1:f9f4f1b99eed
importing src directory
author | Robert McIntyre <rlm@mit.edu> |
---|---|
date | Sat, 03 Mar 2012 10:31:27 -0600 |
parents | |
children |
line wrap: on
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/src/win32/7zip/7z/CPP/7zip/Common/RegisterArc.h Sat Mar 03 10:31:27 2012 -0600 1.3 @@ -0,0 +1,33 @@ 1.4 +// RegisterArc.h 1.5 + 1.6 +#ifndef __REGISTERARC_H 1.7 +#define __REGISTERARC_H 1.8 + 1.9 +#include "../Archive/IArchive.h" 1.10 +#include "DeclareArcs.h" 1.11 + 1.12 +typedef IInArchive * (*CreateInArchiveP)(); 1.13 +typedef IOutArchive * (*CreateOutArchiveP)(); 1.14 + 1.15 +struct CArcInfo 1.16 +{ 1.17 + const wchar_t *Name; 1.18 + const wchar_t *Ext; 1.19 + const wchar_t *AddExt; 1.20 + Byte ClassId; 1.21 + Byte Signature[16]; 1.22 + int SignatureSize; 1.23 + bool KeepName; 1.24 + CreateInArchiveP CreateInArchive; 1.25 + CreateOutArchiveP CreateOutArchive; 1.26 +}; 1.27 + 1.28 +void RegisterArc(const CArcInfo *arcInfo); 1.29 + 1.30 +#define REGISTER_ARC(x) CRegister##x::CRegister##x() { RegisterArc(&g_ArcInfo); } \ 1.31 + CRegister##x g_RegisterArc##x; 1.32 + 1.33 +#define REGISTER_ARCN(x,n) CRegister##x##n::CRegister##x##n() { RegisterArc(&g_ArcInfo##n); } \ 1.34 + CRegister##x##n g_RegisterArc##n##x; 1.35 + 1.36 +#endif