aboutsummaryrefslogtreecommitdiff
path: root/src/engine/catalog.h
blob: 3a87d0d21757fbae94a10fe64c800ae24bad87fc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#pragma once
// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.


#if defined(__cplusplus)
extern "C" {
#endif

// structs

typedef struct _BURN_CATALOG
{
    LPWSTR sczKey;
    LPWSTR sczPayload;

    // mutable members
    LPWSTR sczLocalFilePath; // location of extracted or downloaded copy
    HANDLE hFile;
} BURN_CATALOG;

typedef struct _BURN_CATALOGS
{
    BURN_CATALOG* rgCatalogs;
    DWORD cCatalogs;
} BURN_CATALOGS;

typedef struct _BURN_PAYLOADS BURN_PAYLOADS;


// functions

HRESULT CatalogsParseFromXml(
    __in BURN_CATALOGS* pCatalogs,
    __in IXMLDOMNode* pixnBundle
    );
HRESULT CatalogFindById(
    __in BURN_CATALOGS* pCatalogs,
    __in_z LPCWSTR wzId,
    __out BURN_CATALOG** ppCatalog
    );
HRESULT CatalogLoadFromPayload(
    __in BURN_CATALOGS* pCatalogs,
    __in BURN_PAYLOADS* pPayloads
    );
HRESULT CatalogElevatedUpdateCatalogFile(
    __in BURN_CATALOGS* pCatalogs,
    __in_z LPCWSTR wzId,
    __in_z LPCWSTR wzPath
    );
void CatalogUninitialize(
    __in BURN_CATALOGS* pCatalogs
    );

#if defined(__cplusplus)
}
#endif