diff options
author | Igor Pavlov <ipavlov@users.sourceforge.net> | 2007-01-20 03:00:00 +0300 |
---|---|---|
committer | Kornel LesiĆski <kornel@geekhood.net> | 2016-05-28 02:15:49 +0300 |
commit | d9666cf046a8453b33b3e2fbf4d82295a9f87df3 (patch) | |
tree | c722ed19b844b53042aec0c1d7d2f8381140a5ed /CPP/7zip/UI/Agent/AgentProxy.h | |
parent | 804edc5756fede54dbb1aefda6d39d306111938d (diff) |
4.44 beta
Diffstat (limited to 'CPP/7zip/UI/Agent/AgentProxy.h')
-rwxr-xr-x | CPP/7zip/UI/Agent/AgentProxy.h | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/CPP/7zip/UI/Agent/AgentProxy.h b/CPP/7zip/UI/Agent/AgentProxy.h new file mode 100755 index 00000000..9402cfdd --- /dev/null +++ b/CPP/7zip/UI/Agent/AgentProxy.h @@ -0,0 +1,56 @@ +// AgentProxy.h + +#ifndef __AGENT_PROXY_H +#define __AGENT_PROXY_H + +#include "Common/String.h" + +#include "../../Archive/IArchive.h" + +class CProxyFile +{ +public: + UINT32 Index; + UString Name; +}; + +class CProxyFolder: public CProxyFile +{ +public: + CProxyFolder *Parent; + CObjectVector<CProxyFolder> Folders; + CObjectVector<CProxyFile> Files; + bool IsLeaf; + + CProxyFolder(): Parent(NULL) {}; + int FindDirSubItemIndex(const UString &name, int &insertPos) const; + int FindDirSubItemIndex(const UString &name) const; + CProxyFolder* AddDirSubItem(UINT32 index, + bool leaf, const UString &name); + void AddFileSubItem(UINT32 index, const UString &name); + void Clear(); + + UString GetFullPathPrefix() const; + UString GetItemName(UINT32 index) const; + void AddRealIndices(CUIntVector &realIndices) const; + void GetRealIndices(const UINT32 *indices, UINT32 numItems, + CUIntVector &realIndices) const; +}; + +class CProxyArchive +{ + HRESULT ReadObjects(IInArchive *inArchive, IProgress *progress); +public: + UString DefaultName; + // FILETIME DefaultTime; + // UINT32 DefaultAttributes; + CProxyFolder RootFolder; + HRESULT Reload(IInArchive *archive, IProgress *progress); + HRESULT Load(IInArchive *archive, + const UString &defaultName, + // const FILETIME &defaultTime, + // UINT32 defaultAttributes, + IProgress *progress); +}; + +#endif
\ No newline at end of file |