You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
52 lines
1.4 KiB
52 lines
1.4 KiB
#pragma once
|
|
#include <comdef.h>
|
|
|
|
class CAssemblyManifestEmit : public IAssemblyManifestEmit
|
|
{
|
|
public:
|
|
// IUnknown methods
|
|
STDMETHODIMP QueryInterface(REFIID riid,void ** ppv);
|
|
STDMETHODIMP_(ULONG) AddRef();
|
|
STDMETHODIMP_(ULONG) Release();
|
|
|
|
STDMETHOD(ImportManifestInfo)(
|
|
/* in */ LPASSEMBLY_MANIFEST_IMPORT pManImport);
|
|
|
|
STDMETHOD(SetDependencySubscription)(
|
|
/* in */ LPASSEMBLY_MANIFEST_IMPORT pManImport,
|
|
/* in */ LPWSTR pwzManifestUrl);
|
|
|
|
STDMETHOD(Commit)();
|
|
|
|
~CAssemblyManifestEmit();
|
|
|
|
HRESULT static InitGlobalCritSect();
|
|
void static DelGlobalCritSect();
|
|
|
|
private:
|
|
|
|
// Instance specific data
|
|
DWORD _dwSig;
|
|
HRESULT _hr;
|
|
LONG _cRef;
|
|
IXMLDOMDocument2 *_pXMLDoc;
|
|
IXMLDOMNode *_pAssemblyNode;
|
|
IXMLDOMNode *_pDependencyNode;
|
|
IXMLDOMNode *_pApplicationNode;
|
|
BSTR _bstrManifestFilePath;
|
|
|
|
// Globals
|
|
static CRITICAL_SECTION g_cs;
|
|
|
|
CAssemblyManifestEmit();
|
|
|
|
HRESULT Init(LPCOLESTR wzManifestFilePath);
|
|
|
|
HRESULT ImportAssemblyNode(LPASSEMBLY_MANIFEST_IMPORT pManImport);
|
|
|
|
friend HRESULT CreateAssemblyManifestEmit(LPASSEMBLY_MANIFEST_EMIT* ppEmit,
|
|
LPCOLESTR pwzManifestFilePath, MANIFEST_TYPE eType);
|
|
|
|
};
|
|
|
|
|