diff options
Diffstat (limited to 'src/WixToolset.Core.Native/Msm/IMsmMerge2.cs')
-rw-r--r-- | src/WixToolset.Core.Native/Msm/IMsmMerge2.cs | 174 |
1 files changed, 174 insertions, 0 deletions
diff --git a/src/WixToolset.Core.Native/Msm/IMsmMerge2.cs b/src/WixToolset.Core.Native/Msm/IMsmMerge2.cs new file mode 100644 index 00000000..400249e7 --- /dev/null +++ b/src/WixToolset.Core.Native/Msm/IMsmMerge2.cs | |||
@@ -0,0 +1,174 @@ | |||
1 | // 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. | ||
2 | |||
3 | namespace WixToolset.Core.Native.Msm | ||
4 | { | ||
5 | using System; | ||
6 | using System.Runtime.InteropServices; | ||
7 | |||
8 | /// <summary> | ||
9 | /// IMsmMerge2 interface. | ||
10 | /// </summary> | ||
11 | [ComImport, Guid("351A72AB-21CB-47ab-B7AA-C4D7B02EA305")] | ||
12 | public interface IMsmMerge2 | ||
13 | { | ||
14 | /// <summary> | ||
15 | /// The OpenDatabase method of the Merge object opens a Windows Installer installation | ||
16 | /// database, located at a specified path, that is to be merged with a module. | ||
17 | /// </summary> | ||
18 | /// <param name="path">Path to the database being opened.</param> | ||
19 | void OpenDatabase(string path); | ||
20 | |||
21 | /// <summary> | ||
22 | /// The OpenModule method of the Merge object opens a Windows Installer merge module | ||
23 | /// in read-only mode. A module must be opened before it can be merged with an installation database. | ||
24 | /// </summary> | ||
25 | /// <param name="fileName">Fully qualified file name pointing to a merge module.</param> | ||
26 | /// <param name="language">A valid language identifier (LANGID).</param> | ||
27 | void OpenModule(string fileName, short language); | ||
28 | |||
29 | /// <summary> | ||
30 | /// The CloseDatabase method of the Merge object closes the currently open Windows Installer database. | ||
31 | /// </summary> | ||
32 | /// <param name="commit">true if changes should be saved, false otherwise.</param> | ||
33 | void CloseDatabase(bool commit); | ||
34 | |||
35 | /// <summary> | ||
36 | /// The CloseModule method of the Merge object closes the currently open Windows Installer merge module. | ||
37 | /// </summary> | ||
38 | void CloseModule(); | ||
39 | |||
40 | /// <summary> | ||
41 | /// The OpenLog method of the Merge object opens a log file that receives progress and error messages. | ||
42 | /// If the log file already exists, the installer appends new messages. If the log file does not exist, | ||
43 | /// the installer creates a log file. | ||
44 | /// </summary> | ||
45 | /// <param name="fileName">Fully qualified filename pointing to a file to open or create.</param> | ||
46 | void OpenLog(string fileName); | ||
47 | |||
48 | /// <summary> | ||
49 | /// The CloseLog method of the Merge object closes the current log file. | ||
50 | /// </summary> | ||
51 | void CloseLog(); | ||
52 | |||
53 | /// <summary> | ||
54 | /// The Log method of the Merge object writes a text string to the currently open log file. | ||
55 | /// </summary> | ||
56 | /// <param name="message">The text string to display.</param> | ||
57 | void Log(string message); | ||
58 | |||
59 | /// <summary> | ||
60 | /// Gets the errors from the last merge operation. | ||
61 | /// </summary> | ||
62 | /// <value>The errors from the last merge operation.</value> | ||
63 | IMsmErrors Errors | ||
64 | { | ||
65 | get; | ||
66 | } | ||
67 | |||
68 | /// <summary> | ||
69 | /// Gets a collection of Dependency objects that enumerates a set of unsatisfied dependencies for the current database. | ||
70 | /// </summary> | ||
71 | /// <value>A collection of Dependency objects that enumerates a set of unsatisfied dependencies for the current database.</value> | ||
72 | object Dependencies | ||
73 | { | ||
74 | get; | ||
75 | } | ||
76 | |||
77 | /// <summary> | ||
78 | /// The Merge method of the Merge object executes a merge of the current database and current | ||
79 | /// module. The merge attaches the components in the module to the feature identified by Feature. | ||
80 | /// The root of the module's directory tree is redirected to the location given by RedirectDir. | ||
81 | /// </summary> | ||
82 | /// <param name="feature">The name of a feature in the database.</param> | ||
83 | /// <param name="redirectDir">The key of an entry in the Directory table of the database. | ||
84 | /// This parameter may be NULL or an empty string.</param> | ||
85 | void Merge(string feature, string redirectDir); | ||
86 | |||
87 | /// <summary> | ||
88 | /// The Connect method of the Merge object connects a module to an additional feature. | ||
89 | /// The module must have already been merged into the database or will be merged into the database. | ||
90 | /// The feature must exist before calling this function. | ||
91 | /// </summary> | ||
92 | /// <param name="feature">The name of a feature already existing in the database.</param> | ||
93 | void Connect(string feature); | ||
94 | |||
95 | /// <summary> | ||
96 | /// The ExtractCAB method of the Merge object extracts the embedded .cab file from a module and | ||
97 | /// saves it as the specified file. The installer creates this file if it does not already exist | ||
98 | /// and overwritten if it does exist. | ||
99 | /// </summary> | ||
100 | /// <param name="fileName">The fully qualified destination file.</param> | ||
101 | void ExtractCAB(string fileName); | ||
102 | |||
103 | /// <summary> | ||
104 | /// The ExtractFiles method of the Merge object extracts the embedded .cab file from a module | ||
105 | /// and then writes those files to the destination directory. | ||
106 | /// </summary> | ||
107 | /// <param name="path">The fully qualified destination directory.</param> | ||
108 | void ExtractFiles(string path); | ||
109 | |||
110 | /// <summary> | ||
111 | /// The MergeEx method of the Merge object is equivalent to the Merge function, except that it | ||
112 | /// takes an extra argument. The Merge method executes a merge of the current database and | ||
113 | /// current module. The merge attaches the components in the module to the feature identified | ||
114 | /// by Feature. The root of the module's directory tree is redirected to the location given by RedirectDir. | ||
115 | /// </summary> | ||
116 | /// <param name="feature">The name of a feature in the database.</param> | ||
117 | /// <param name="redirectDir">The key of an entry in the Directory table of the database. This parameter may | ||
118 | /// be NULL or an empty string.</param> | ||
119 | /// <param name="configuration">The pConfiguration argument is an interface implemented by the client. The argument may | ||
120 | /// be NULL. The presence of this argument indicates that the client is capable of supporting the configuration | ||
121 | /// functionality, but does not obligate the client to provide configuration data for any specific configurable item.</param> | ||
122 | void MergeEx(string feature, string redirectDir, IMsmConfigureModule configuration); | ||
123 | |||
124 | /// <summary> | ||
125 | /// The ExtractFilesEx method of the Merge object extracts the embedded .cab file from a module and | ||
126 | /// then writes those files to the destination directory. | ||
127 | /// </summary> | ||
128 | /// <param name="path">The fully qualified destination directory.</param> | ||
129 | /// <param name="longFileNames">Set to specify using long file names for path segments and final file names.</param> | ||
130 | /// <param name="filePaths">This is a list of fully-qualified paths for the files that were successfully extracted. | ||
131 | /// The list is empty if no files can be extracted. This argument may be null. No list is provided if pFilePaths is null.</param> | ||
132 | void ExtractFilesEx(string path, bool longFileNames, ref IntPtr filePaths); | ||
133 | |||
134 | /// <summary> | ||
135 | /// Gets a collection ConfigurableItem objects, each of which represents a single row from the ModuleConfiguration table. | ||
136 | /// </summary> | ||
137 | /// <value>A collection ConfigurableItem objects, each of which represents a single row from the ModuleConfiguration table.</value> | ||
138 | /// <remarks>Semantically, each interface in the enumerator represents an item that can be configured by the module consumer. | ||
139 | /// The collection is a read-only collection and implements the standard read-only collection interfaces of Item(), Count() and _NewEnum(). | ||
140 | /// The IEnumMsmConfigItems enumerator implements Next(), Skip(), Reset(), and Clone() with the standard semantics.</remarks> | ||
141 | object ConfigurableItems | ||
142 | { | ||
143 | get; | ||
144 | } | ||
145 | |||
146 | /// <summary> | ||
147 | /// The CreateSourceImage method of the Merge object allows the client to extract the files from a module to | ||
148 | /// a source image on disk after a merge, taking into account changes to the module that might have been made | ||
149 | /// during module configuration. The list of files to be extracted is taken from the file table of the module | ||
150 | /// during the merge process. The list of files consists of every file successfully copied from the file table | ||
151 | /// of the module to the target database. File table entries that were not copied due to primary key conflicts | ||
152 | /// with existing rows in the database are not a part of this list. At image creation time, the directory for | ||
153 | /// each of these files comes from the open (post-merge) database. The path specified in the Path parameter is | ||
154 | /// the root of the source image for the install. fLongFileNames determines whether or not long file names are | ||
155 | /// used for both path segments and final file names. The function fails if no database is open, no module is | ||
156 | /// open, or no merge has been performed. | ||
157 | /// </summary> | ||
158 | /// <param name="path">The path of the root of the source image for the install.</param> | ||
159 | /// <param name="longFileNames">Determines whether or not long file names are used for both path segments and final file names. </param> | ||
160 | /// <param name="filePaths">This is a list of fully-qualified paths for the files that were successfully extracted. | ||
161 | /// The list is empty if no files can be extracted. This argument may be null. No list is provided if pFilePaths is null.</param> | ||
162 | void CreateSourceImage(string path, bool longFileNames, ref IntPtr filePaths); | ||
163 | |||
164 | /// <summary> | ||
165 | /// The get_ModuleFiles function implements the ModuleFiles property of the GetFiles object. This function | ||
166 | /// returns the primary keys in the File table of the currently open module. The primary keys are returned | ||
167 | /// as a collection of strings. The module must be opened by a call to the OpenModule function before calling get_ModuleFiles. | ||
168 | /// </summary> | ||
169 | IMsmStrings ModuleFiles | ||
170 | { | ||
171 | get; | ||
172 | } | ||
173 | } | ||
174 | } | ||