wbemdisp.idl 32.5 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
/*
 * Copyright 2013 Hans Leidekker for CodeWeavers
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
 */

import "dispex.idl";

21 22 23 24 25 26
#ifndef __WIDL__
#define threading(model)
#define progid(str)
#define vi_progid(str)
#endif

27 28 29 30 31 32 33 34 35 36 37
[
    uuid(565783c6-cb41-11d1-8b02-00600806d9b6),
    helpstring("Microsoft WMI Scripting V1.2 Library"),
    lcid(0x0000),
    version(1.2)
]
library WbemScripting
{

importlib("stdole2.tlb");

38 39
interface ISWbemEventSource;
interface ISWbemLocator;
40
interface ISWbemMethod;
41
interface ISWbemMethodSet;
42 43
interface ISWbemNamedValue;
interface ISWbemNamedValueSet;
44 45 46
interface ISWbemObject;
interface ISWbemObjectPath;
interface ISWbemObjectSet;
47
interface ISWbemPrivilege;
48
interface ISWbemPrivilegeSet;
49
interface ISWbemProperty;
50
interface ISWbemPropertySet;
51
interface ISWbemQualifier;
52 53 54 55
interface ISWbemQualifierSet;
interface ISWbemSecurity;
interface ISWbemServices;

56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134
typedef
[
    v1_enum,
    uuid(bf078c2a-07d9-11d2-8b21-00600806d9b6)
]
enum WbemTimeout
{
    wbemTimeoutInfinite = 0xffffffff
} WbemTimeout;

typedef
[
    v1_enum,
    uuid(4a249b72-fc9a-11d1-8b1e-00600806d9b6)
]
enum WbemChangeFlagEnum
{
    wbemChangeFlagCreateOrUpdate   = 0,
    wbemChangeFlagUpdateOnly       = 0x00000001,
    wbemChangeFlagCreateOnly       = 0x00000002,
    wbemChangeFlagUpdateCompatible = 0x00000000,
    wbemChangeFlagUpdateSafeMode   = 0x00000020,
    wbemChangeFlagUpdateForceMode  = 0x00000040,
    wbemChangeFlagStrongValidation = 0x00000080,
    wbemChangeFlagAdvisory         = 0x00010000
} WbemChangeFlagEnum;

typedef
[
    v1_enum,
    uuid(4a249b73-fc9a-11d1-8b1e-00600806d9b6)
]
enum WbemFlagEnum
{
    wbemFlagReturnImmediately    = 0x00010,
    wbemFlagReturnWhenComplete   = 0,
    wbemFlagBidirectional        = 0,
    wbemFlagForwardOnly          = 0x00020,
    wbemFlagNoErrorObject        = 0x00040,
    wbemFlagReturnErrorObject    = 0,
    wbemFlagSendStatus           = 0x00080,
    wbemFlagDontSendStatus       = 0,
    wbemFlagEnsureLocatable      = 0x00100,
    wbemFlagDirectRead           = 0x00200,
    wbemFlagSendOnlySelected     = 0,
    wbemFlagUseAmendedQualifiers = 0x20000,
    wbemFlagGetDefault           = 0x0,
    wbemFlagSpawnInstance        = 0x00001,
    wbemFlagUseCurrentTime       = 0x00001
} WbemFlagEnum;

typedef
[
    v1_enum,
    uuid(4a249b76-fc9a-11d1-8b1e-00600806d9b6)
]
enum WbemQueryFlagEnum
{
    wbemQueryFlagDeep,
    wbemQueryFlagShallow,
    wbemQueryFlagPrototype
} WbemQueryFlagEnum;

typedef
[
    v1_enum,
    uuid(4A249B79-FC9A-11d1-8B1E-00600806D9B6)
]
enum WbemComparisonFlagEnum
{
    wbemComparisonFlagIncludeAll          = 0,
    wbemComparisonFlagIgnoreQualifiers    = 1,
    wbemComparisonFlagIgnoreObjectSource  = 2,
    wbemComparisonFlagIgnoreDefaultValues = 4,
    wbemComparisonFlagIgnoreClass         = 8,
    wbemComparisonFlagIgnoreCase          = 16,
    wbemComparisonFlagIgnoreFlavor        = 32
} WbemComparisonFlagEnum;

135 136 137 138 139 140 141 142 143 144 145 146 147
[
    object,
    local,
    uuid(27d54d92-0ebe-11d2-8b22-00600806d9b6),
    dual,
    hidden,
    oleautomation,
    nonextensible
]
interface ISWbemEventSource : IDispatch
{
    [ id(1) ]
    HRESULT NextEvent(
148
        [in, defaultvalue(wbemTimeoutInfinite)] long iTimeoutMs,
149 150 151 152 153
        [out, retval] ISWbemObject **objWbemObject);

    [ id(2), propget ]
    HRESULT Security_(
        [out, retval] ISWbemSecurity **objWbemSecurity);
154
}
155

156 157 158 159 160 161 162 163 164 165 166 167 168
[
    object,
    local,
    uuid(76a6415b-cb41-11d1-8b02-00600806d9b6),
    dual,
    hidden,
    oleautomation,
    pointer_default(unique)
]
interface ISWbemLocator : IDispatch
{
    [ id(1) ]
    HRESULT ConnectServer(
169 170 171 172 173 174 175 176
        [in, defaultvalue(".")] BSTR strServer,
        [in, defaultvalue("")]  BSTR strNamespace,
        [in, defaultvalue("")]  BSTR strUser,
        [in, defaultvalue("")]  BSTR strPassword,
        [in, defaultvalue("")]  BSTR strLocale,
        [in, defaultvalue("")]  BSTR strAuthority,
        [in, defaultvalue(0)]   long iSecurityFlags,
        [in, defaultvalue(0)]   IDispatch *objWbemNamedValueSet,
177 178 179
        [out, retval] ISWbemServices **objWbemServices);

    [ id(2), propget ]
180
    HRESULT Security_([out, retval] ISWbemSecurity **objWbemSecurity);
181
}
182

183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213
[
    object,
    local,
    uuid(422e8e90-d955-11d1-8b09-00600806d9b6),
    dual,
    hidden,
    oleautomation,
    pointer_default(unique),
    nonextensible
]
interface ISWbemMethod : IDispatch
{
    [ id(1), propget ]
    HRESULT Name(
        [out, retval] BSTR *strName);

    [ id(2), propget ]
    HRESULT Origin(
        [out, retval] BSTR *strOrigin);

    [ id(3), propget ]
    HRESULT InParameters(
        [out, retval] ISWbemObject **objWbemInParameters);

    [ id(4), propget ]
    HRESULT OutParameters(
        [out, retval] ISWbemObject **objWbemOutParameters);

    [ id(5), propget ]
    HRESULT Qualifiers_(
        [out, retval] ISWbemQualifierSet **objWbemQualifierSet);
214
}
215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233

[
    object,
    local,
    uuid(c93ba292-d955-11d1-8b09-00600806d9b6),
    dual,
    hidden,
    oleautomation,
    nonextensible
]
interface ISWbemMethodSet : IDispatch
{
    [ id(DISPID_NEWENUM), propget, restricted ]
    HRESULT _NewEnum(
        [out, retval] IUnknown **pUnk);

    [ id(DISPID_VALUE) ]
    HRESULT Item(
        [in] BSTR strName,
234
        [in, defaultvalue(0)] long iFlags,
235 236 237 238 239
        [out, retval] ISWbemMethod **objWbemMethod);

    [ id(1), propget ]
    HRESULT Count(
        [out, retval] long *iCount);
240
}
241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262

[
    object,
    local,
    uuid(76a64164-cb41-11d1-8b02-00600806d9b6),
    dual,
    hidden,
    oleautomation
]
interface ISWbemNamedValue : IDispatch
{
    [ id(DISPID_VALUE), propget ]
    HRESULT Value(
        [out, retval] VARIANT *varValue);

    [ id(DISPID_VALUE), propput ]
    HRESULT Value(
        [in] VARIANT *varValue);

    [ id(2), propget ]
    HRESULT Name(
        [out, retval] BSTR *strName);
263
}
264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281

[
    object,
    local,
    uuid(cf2376ea-ce8c-11d1-8b05-00600806d9b6),
    dual,
    hidden,
    oleautomation
]
interface ISWbemNamedValueSet : IDispatch
{
    [ id(DISPID_NEWENUM), propget, restricted ]
    HRESULT _NewEnum(
        [out, retval] IUnknown **pUnk);

    [ id(DISPID_VALUE) ]
    HRESULT Item(
        [in] BSTR strName,
282
        [in, defaultvalue(0)] long iFlags,
283 284 285 286 287 288 289 290 291 292
        [out, retval] ISWbemNamedValue **objWbemNamedValue);

    [ id(1), propget ]
    HRESULT Count(
        [out, retval] long *iCount);

    [ id(2) ]
    HRESULT Add(
        [in] BSTR strName,
        [in] VARIANT *varValue,
293
        [in, defaultvalue(0)] long iFlags,
294 295 296 297 298
        [out, retval] ISWbemNamedValue **objWbemNamedValue);

    [ id(3) ]
    HRESULT Remove(
        [in] BSTR strName,
299
        [in, defaultvalue(0)] long iFlags);
300 301 302 303 304 305 306

    [ id(4) ]
    HRESULT Clone(
        [out, retval] ISWbemNamedValueSet **objWbemNamedValueSet);

    [ id(5) ]
    HRESULT DeleteAll();
307
}
308

309 310 311 312 313 314 315 316 317 318 319 320
[
    object,
    local,
    uuid(76A6415A-CB41-11d1-8B02-00600806D9B6),
    dual,
    hidden,
    oleautomation
]
interface ISWbemObject : IDispatch
{
    [ id(1) ]
    HRESULT Put_(
321 322
        [in, defaultvalue(wbemChangeFlagCreateOrUpdate)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
323 324 325 326 327
        [out, retval] ISWbemObjectPath **objWbemObjectPath);

    [ id(2) ]
    HRESULT PutAsync_(
        [in] IDispatch *objWbemSink,
328 329 330
        [in, defaultvalue(wbemChangeFlagCreateOrUpdate)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
331 332 333

    [ id (3) ]
    HRESULT Delete_(
334 335
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet);
336 337 338 339

    [ id (4) ]
    HRESULT DeleteAsync_(
        [in] IDispatch *objWbemSink,
340 341 342
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
343 344 345

    [ id(5) ]
    HRESULT Instances_(
346 347
        [in, defaultvalue(wbemFlagReturnImmediately)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
348 349 350 351 352
        [out, retval] ISWbemObjectSet **objWbemObjectSet);

    [ id(6) ]
    HRESULT InstancesAsync_(
        [in] IDispatch *objWbemSink,
353 354 355
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
356 357 358

    [ id(7) ]
    HRESULT Subclasses_(
359 360
        [in, defaultvalue(wbemFlagReturnImmediately|wbemQueryFlagDeep)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
361 362 363 364 365
        [out, retval] ISWbemObjectSet **objWbemObjectSet);

    [ id(8) ]
    HRESULT SubclassesAsync_(
        [in] IDispatch *objWbemSink,
366 367 368
        [in, defaultvalue(wbemQueryFlagDeep)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
369 370 371

    [ id(9) ]
    HRESULT Associators_(
372 373 374 375 376 377 378 379 380 381
        [in, defaultvalue("")] BSTR strAssocClass,
        [in, defaultvalue("")] BSTR strResultClass,
        [in, defaultvalue("")] BSTR strResultRole,
        [in, defaultvalue("")] BSTR strRole,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bClassesOnly,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bSchemaOnly,
        [in, defaultvalue("")] BSTR strRequiredAssocQualifier,
        [in, defaultvalue("")] BSTR strRequiredQualifier,
        [in, defaultvalue(wbemFlagReturnImmediately)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
382 383 384 385 386
        [out, retval] ISWbemObjectSet **objWbemObjectSet);

    [ id(10) ]
    HRESULT AssociatorsAsync_(
        [in] IDispatch *objWbemSink,
387 388 389 390 391 392 393 394 395 396 397
        [in, defaultvalue("")] BSTR strAssocClass,
        [in, defaultvalue("")] BSTR strResultClass,
        [in, defaultvalue("")] BSTR strResultRole,
        [in, defaultvalue("")] BSTR strRole,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bClassesOnly,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bSchemaOnly,
        [in, defaultvalue("")] BSTR strRequiredAssocQualifier,
        [in, defaultvalue("")] BSTR strRequiredQualifier,
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
398 399 400

    [ id(11) ]
    HRESULT References_(
401 402 403 404 405 406 407
        [in, defaultvalue("")] BSTR strResultClass,
        [in, defaultvalue("")] BSTR strRole,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bClassesOnly,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bSchemaOnly,
        [in, defaultvalue("")] BSTR strRequiredQualifier,
        [in, defaultvalue(wbemFlagReturnImmediately)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
408 409 410 411 412
        [out, retval] ISWbemObjectSet **objWbemObjectSet);

    [ id(12) ]
    HRESULT ReferencesAsync_(
        [in] IDispatch *objWbemSink,
413 414 415 416 417 418 419 420
        [in, defaultvalue("")] BSTR strResultClass,
        [in, defaultvalue("")] BSTR strRole,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bClassesOnly,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bSchemaOnly,
        [in, defaultvalue("")] BSTR strRequiredQualifier,
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
421 422 423 424

    [ id(13) ]
    HRESULT ExecMethod_(
        [in] BSTR strMethodName,
425 426 427
        [in, defaultvalue(0)] IDispatch *objWbemInParameters,
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
428 429 430 431 432 433
        [out, retval] ISWbemObject **objWbemOutParameters);

    [ id(14) ]
    HRESULT ExecMethodAsync_(
        [in] IDispatch *objWbemSink,
        [in] BSTR strMethodName,
434 435 436 437
        [in, defaultvalue(0)] IDispatch *objWbemInParameters,
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
438 439 440 441 442 443 444

    [ id(15) ]
    HRESULT Clone_(
        [out, retval] ISWbemObject **objWbemObject);

    [ id(16) ]
    HRESULT GetObjectText_(
445
        [in, defaultvalue(0)] long iFlags,
446 447 448 449
        [out, retval] BSTR *strObjectText);

    [ id(17) ]
    HRESULT SpawnDerivedClass_(
450
        [in, defaultvalue(0)] long iFlags,
451 452 453 454
        [out, retval] ISWbemObject **objWbemObject);

    [ id(18) ]
    HRESULT SpawnInstance_(
455
        [in, defaultvalue(0)] long iFlags,
456 457 458 459 460
        [out, retval] ISWbemObject **objWbemObject);

    [ id(19) ]
    HRESULT CompareTo_(
        [in] IDispatch *objWbemObject,
461
        [in, defaultvalue(wbemComparisonFlagIncludeAll)] long iFlags,
462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486
        [out, retval] VARIANT_BOOL *bResult);

    [ id(20), propget ]
    HRESULT Qualifiers_(
        [out, retval] ISWbemQualifierSet **objWbemQualifierSet);

    [ id(21), propget ]
    HRESULT Properties_(
        [out, retval] ISWbemPropertySet **objWbemPropertySet);

    [ id(22), propget ]
    HRESULT Methods_(
        [out, retval] ISWbemMethodSet **objWbemMethodSet);

    [ id(23), propget ]
    HRESULT Derivation_(
        [out, retval] VARIANT *strClassNameArray);

    [ id(24), propget ]
    HRESULT Path_(
        [out, retval] ISWbemObjectPath **objWbemObjectPath);

    [ id(25), propget ]
    HRESULT Security_(
        [out, retval] ISWbemSecurity **objWbemSecurity);
487
}
488

489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588
[
    object,
    local,
    uuid(5791bc27-ce9c-11d1-97bf-0000f81e849c),
    dual,
    hidden,
    oleautomation,
    pointer_default(unique)
]
interface ISWbemObjectPath : IDispatch
{
    [ id(DISPID_VALUE), propget ]
    HRESULT Path(
        [out, retval] BSTR *strPath);

    [ id(DISPID_VALUE), propput ]
    HRESULT Path(
        [in] BSTR strPath);

    [ id(1), propget ]
    HRESULT RelPath(
        [out, retval] BSTR *strRelPath);

    [ id(1), propput ]
    HRESULT RelPath(
        [in] BSTR strRelPath);

    [ id(2), propget ]
    HRESULT Server(
        [out, retval] BSTR *strServer);

    [ id(2), propput ]
    HRESULT Server(
        [in] BSTR strServer);

    [ id(3), propget ]
    HRESULT Namespace(
        [out, retval] BSTR *strNamespace);

    [ id(3), propput ]
    HRESULT Namespace(
        [in] BSTR strNamespace);

    [ id(4), propget ]
    HRESULT ParentNamespace(
        [out, retval] BSTR *strParentNamespace);

    [ id(5), propget ]
    HRESULT DisplayName(
        [out, retval] BSTR *strDisplayName);

    [ id(5), propput ]
    HRESULT DisplayName(
        [in] BSTR strDisplayName);

    [ id(6), propget ]
    HRESULT Class(
        [out, retval] BSTR *strClass);

    [ id(6), propput ]
    HRESULT Class(
        [in] BSTR strClass);

    [ id(7), propget ]
    HRESULT IsClass(
        [out, retval] VARIANT_BOOL *bIsClass);

    [ id(8) ]
    HRESULT SetAsClass();

    [ id(9), propget ]
    HRESULT IsSingleton(
        [out, retval] VARIANT_BOOL *bIsSingleton);

    [ id(10) ]
    HRESULT SetAsSingleton();

    [ id(11), propget ]
    HRESULT Keys(
        [out, retval] ISWbemNamedValueSet **objWbemNamedValueSet);

    [ id(12), propget ]
    HRESULT Security_(
        [out, retval] ISWbemSecurity **objWbemSecurity);

    [ id(13), propget ]
    HRESULT Locale(
        [out, retval] BSTR *strLocale);

    [ id(13), propput ]
    HRESULT Locale(
        [in] BSTR strLocale);

    [ id(14), propget ]
    HRESULT Authority(
        [out, retval] BSTR *strAuthority);

    [ id(14), propput ]
    HRESULT Authority(
        [in] BSTR strAuthority);
589
}
590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608

[
    object,
    local,
    uuid(76a6415f-cb41-11d1-8b02-00600806d9b6),
    dual,
    hidden,
    oleautomation,
    nonextensible
]
interface ISWbemObjectSet : IDispatch
{
    [ id(DISPID_NEWENUM), propget, restricted ]
    HRESULT _NewEnum(
        [out, retval] IUnknown **pUnk);

    [ id(DISPID_VALUE) ]
    HRESULT Item(
        [in] BSTR strObjectPath,
609
        [in, defaultvalue(0)] long iFlags,
610 611 612 613 614 615 616 617 618 619 620 621 622 623
        [out, retval] ISWbemObject **objWbemObject);

    [ id(1), propget ]
    HRESULT Count(
        [out, retval] long *iCount);

    [ id(4), propget ]
    HRESULT Security_(
        [out, retval] ISWbemSecurity **objWbemSecurity);

    [ id(5) ]
    HRESULT ItemIndex(
        [in] long lIndex,
        [out, retval] ISWbemObject **objWbemObject);
624
}
625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691

typedef
[
    v1_enum,
    uuid(176d2f70-5af3-11d2-8b4a-00600806d9b6)
]
enum WbemPrivilegeEnum
{
    wbemPrivilegeCreateToken          = 1,
    wbemPrivilegePrimaryToken         = 2,
    wbemPrivilegeLockMemory           = 3,
    wbemPrivilegeIncreaseQuota        = 4,
    wbemPrivilegeMachineAccount       = 5,
    wbemPrivilegeTcb                  = 6,
    wbemPrivilegeSecurity             = 7,
    wbemPrivilegeTakeOwnership        = 8,
    wbemPrivilegeLoadDriver           = 9,
    wbemPrivilegeSystemProfile        = 10,
    wbemPrivilegeSystemtime           = 11,
    wbemPrivilegeProfileSingleProcess = 12,
    wbemPrivilegeIncreaseBasePriority = 13,
    wbemPrivilegeCreatePagefile       = 14,
    wbemPrivilegeCreatePermanent      = 15,
    wbemPrivilegeBackup               = 16,
    wbemPrivilegeRestore              = 17,
    wbemPrivilegeShutdown             = 18,
    wbemPrivilegeDebug                = 19,
    wbemPrivilegeAudit                = 20,
    wbemPrivilegeSystemEnvironment    = 21,
    wbemPrivilegeChangeNotify         = 22,
    wbemPrivilegeRemoteShutdown       = 23,
    wbemPrivilegeUndock               = 24,
    wbemPrivilegeSyncAgent            = 25,
    wbemPrivilegeEnableDelegation     = 26,
    wbemPrivilegeManageVolume         = 27
} WbemPrivilegeEnum;

[
    object,
    local,
    uuid(26ee67bd-5804-11d2-8b4a-00600806d9b6),
    dual,
    hidden,
    oleautomation,
    nonextensible
]
interface ISWbemPrivilege : IDispatch
{
    [ id(DISPID_VALUE), propget ]
    HRESULT IsEnabled(
        [out, retval] VARIANT_BOOL *bIsEnabled);

    [ id(DISPID_VALUE), propput ]
    HRESULT IsEnabled(
        [in] VARIANT_BOOL bIsEnabled);

    [ id(1), propget ]
    HRESULT Name(
        [out, retval] BSTR *strDisplayName);

    [ id(2), propget ]
    HRESULT DisplayName(
        [out, retval] BSTR *strDisplayName);

    [ id(3), propget ]
    HRESULT Identifier(
        [out, retval] WbemPrivilegeEnum *iPrivilege);
692
}
693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720

[
    object,
    local,
    uuid(26ee67bf-5804-11d2-8b4a-00600806d9b6),
    dual,
    hidden,
    oleautomation,
    nonextensible
]
interface ISWbemPrivilegeSet : IDispatch
{
    [ id(DISPID_NEWENUM), propget, restricted ]
    HRESULT _NewEnum(
        [out, retval] IUnknown **pUnk);

    [ id(DISPID_VALUE) ]
    HRESULT Item(
        [in] WbemPrivilegeEnum iPrivilege,
        [out, retval] ISWbemPrivilege **objWbemPrivilege);

    [ id(1), propget ]
    HRESULT Count(
        [out, retval] long *iCount);

    [ id(2) ]
    HRESULT Add(
        [in] WbemPrivilegeEnum iPrivilege,
721
        [in, defaultvalue(TRUE)] VARIANT_BOOL bIsEnabled,
722 723 724 725 726 727 728 729 730 731 732 733
        [out, retval] ISWbemPrivilege **objWbemPrivilege);

    [ id(3) ]
    HRESULT Remove(
        [in] WbemPrivilegeEnum iPrivilege);

    [ id(4) ]
    HRESULT DeleteAll();

    [ id(5) ]
    HRESULT AddAsString(
        [in] BSTR strPrivilege,
734
        [in, defaultvalue(TRUE)] VARIANT_BOOL bIsEnabled,
735
        [out, retval] ISWbemPrivilege **objWbemPrivilege);
736
}
737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804

typedef
[
    v1_enum,
    uuid(4a249b7b-fc9a-11d1-8b1e-00600806d9b6),
]
enum WbemCimtypeEnum
{
    wbemCimtypeSint16    = 2,
    wbemCimtypeSint32    = 3,
    wbemCimtypeReal32    = 4,
    wbemCimtypeReal64    = 5,
    wbemCimtypeString    = 8,
    wbemCimtypeBoolean   = 11,
    wbemCimtypeObject    = 13,
    wbemCimtypeSint8     = 16,
    wbemCimtypeUint8     = 17,
    wbemCimtypeUint16    = 18,
    wbemCimtypeUint32    = 19,
    wbemCimtypeSint64    = 20,
    wbemCimtypeUint64    = 21,
    wbemCimtypeDatetime  = 101,
    wbemCimtypeReference = 102,
    wbemCimtypeChar16    = 103
} WbemCimtypeEnum;

[
    object,
    local,
    uuid(1a388f98-d4ba-11d1-8b09-00600806d9b6),
    dual,
    hidden,
    oleautomation,
    pointer_default(unique)
]
interface ISWbemProperty : IDispatch
{
    [ id(DISPID_VALUE), propget ]
    HRESULT Value(
        [out, retval] VARIANT *varValue);

    [ id(DISPID_VALUE), propput ]
    HRESULT Value(
        [in] VARIANT *varValue);

    [ id(1), propget ]
    HRESULT Name(
        [out, retval] BSTR *strName);

    [ id(2), propget ]
    HRESULT IsLocal(
        [out, retval] VARIANT_BOOL *bIsLocal);

    [ id(3), propget ]
    HRESULT Origin(
        [out, retval] BSTR *strOrigin);

    [ id(4), propget ]
    HRESULT CIMType(
        [out, retval] WbemCimtypeEnum *iCimType);

    [ id(5), propget ]
    HRESULT Qualifiers_(
        [out, retval] ISWbemQualifierSet **objWbemQualifierSet);

    [ id(6), propget ]
    HRESULT IsArray(
        [out, retval] VARIANT_BOOL *bIsArray);
805
}
806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823

[
    object,
    local,
    uuid(dea0a7b2-d4ba-11d1-8b09-00600806d9b6),
    dual,
    hidden,
    oleautomation
]
interface ISWbemPropertySet : IDispatch
{
    [ id(DISPID_NEWENUM), propget, restricted ]
    HRESULT _NewEnum(
        [out, retval] IUnknown **pUnk);

    [ id(DISPID_VALUE) ]
    HRESULT Item(
        [in] BSTR strName,
824
        [in, defaultvalue(0)] long iFlags,
825 826 827 828 829 830 831 832 833 834
        [out, retval] ISWbemProperty **objWbemProperty);

    [ id(1), propget ]
    HRESULT Count(
        [out, retval] long *iCount);

    [ id(2) ]
    HRESULT Add(
        [in] BSTR strName,
        [in] WbemCimtypeEnum iCIMType,
835 836
        [in, defaultvalue(FALSE)] VARIANT_BOOL bIsArray,
        [in, defaultvalue(0)] long iFlags,
837 838 839 840 841
        [out, retval] ISWbemProperty **objWbemProperty);

    [ id(3) ]
    HRESULT Remove(
        [in] BSTR strName,
842
        [in, defaultvalue(0)] long iFlags);
843
}
844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899

[
    object,
    local,
    uuid(79b05932-d3b7-11d1-8b06-00600806d9b6),
    dual,
    hidden,
    oleautomation,
    nonextensible,
    pointer_default(unique)
]
interface ISWbemQualifier : IDispatch
{
    [ id(DISPID_VALUE), propget ]
    HRESULT Value(
        [out, retval] VARIANT *varValue);

    [ id(DISPID_VALUE), propput ]
    HRESULT Value(
        [in] VARIANT *varValue);

    [ id(1), propget ]
    HRESULT Name(
        [out, retval] BSTR *strName);

    [ id(2), propget ]
    HRESULT IsLocal(
        [out, retval] VARIANT_BOOL *bIsLocal);

    [ id(3), propget ]
    HRESULT PropagatesToSubclass(
        [out, retval] VARIANT_BOOL *bPropagatesToSubclass);

    [ id(3), propput ]
    HRESULT PropagatesToSubclass(
        [in] VARIANT_BOOL bPropagatesToSubclass);

    [ id(4), propget ]
    HRESULT PropagatesToInstance(
        [out, retval] VARIANT_BOOL *bPropagatesToInstance);

    [ id(4), propput ]
    HRESULT PropagatesToInstance(
        [in] VARIANT_BOOL bPropagatesToInstance);

    [ id(5), propget ]
    HRESULT IsOverridable(
        [out, retval] VARIANT_BOOL *bIsOverridable);

    [ id(5), propput ]
    HRESULT IsOverridable(
        [in] VARIANT_BOOL bIsOverridable);

    [ id(6), propget ]
    HRESULT IsAmended(
        [out, retval] VARIANT_BOOL *bIsAmended);
900
}
901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919

[
    object,
    local,
    uuid(9b16ed16-d3df-11d1-8b08-00600806d9b6),
    dual,
    hidden,
    oleautomation,
    nonextensible
]
interface ISWbemQualifierSet : IDispatch
{
    [ id(DISPID_NEWENUM), propget, restricted ]
    HRESULT _NewEnum(
        [out, retval] IUnknown **pUnk);

    [ id(DISPID_VALUE) ]
    HRESULT Item(
        [in] BSTR name,
920
        [in, defaultvalue(0)] long iFlags,
921 922 923 924 925 926 927 928 929 930
        [out, retval] ISWbemQualifier **objWbemQualifier);

    [ id(1), propget ]
    HRESULT Count(
        [out, retval] long *iCount);

    [ id(2) ]
    HRESULT Add(
        [in] BSTR strName,
        [in] VARIANT *varVal,
931 932 933 934
        [in, defaultvalue(TRUE)] VARIANT_BOOL bPropagatesToSubclass,
        [in, defaultvalue(TRUE)] VARIANT_BOOL bPropagatesToInstance,
        [in, defaultvalue(TRUE)] VARIANT_BOOL bIsOverridable,
        [in, defaultvalue(0)] long iFlags,
935 936 937 938 939
        [out, retval] ISWbemQualifier **objWbemQualifier);

    [ id(3) ]
    HRESULT Remove(
        [in] BSTR strName,
940
        [in, defaultvalue(0)] long iFlags);
941
}
942

943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001
typedef
[
    v1_enum,
    uuid(b54d66e8-2287-11d2-8b33-00600806d9b6)
]
enum WbemImpersonationLevelEnum
{
    wbemImpersonationLevelAnonymous   = 1,
    wbemImpersonationLevelIdentify    = 2,
    wbemImpersonationLevelImpersonate = 3,
    wbemImpersonationLevelDelegate    = 4
} WbemImpersonationLevelEnum;

typedef
[
    v1_enum,
    uuid(b54d66e7-2287-11d2-8b33-00600806d9b6)
]
enum WbemAuthenticationLevelEnum
{
    wbemAuthenticationLevelDefault      = 0,
    wbemAuthenticationLevelNone         = 1,
    wbemAuthenticationLevelConnect      = 2,
    wbemAuthenticationLevelCall         = 3,
    wbemAuthenticationLevelPkt          = 4,
    wbemAuthenticationLevelPktIntegrity = 5,
    wbemAuthenticationLevelPktPrivacy   = 6
} WbemAuthenticationLevelEnum;

[
    object,
    local,
    uuid(b54d66e6-2287-11d2-8b33-00600806d9b6),
    dual,
    hidden,
    oleautomation,
    nonextensible
]
interface ISWbemSecurity : IDispatch
{
    [ id(1), propget ]
    HRESULT ImpersonationLevel(
        [out, retval] WbemImpersonationLevelEnum *iImpersonationLevel);

    [ id(1), propput ]
    HRESULT ImpersonationLevel(
        [in] WbemImpersonationLevelEnum iImpersonationLevel);

    [ id(2), propget ]
    HRESULT AuthenticationLevel(
        [out, retval] WbemAuthenticationLevelEnum *iAuthenticationLevel);

    [ id(2), propput ]
    HRESULT AuthenticationLevel(
        [in] WbemAuthenticationLevelEnum iAuthenticationLevel);

    [ id(3), propget ]
    HRESULT Privileges(
        [out, retval] ISWbemPrivilegeSet **objWbemPrivilegeSet);
1002
}
1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016

[
    object,
    local,
    uuid(76a6415c-cb41-11d1-8b02-00600806d9b6),
    dual,
    hidden,
    oleautomation,
    pointer_default(unique)
]
interface ISWbemServices : IDispatch
{
    [ id(1) ]
    HRESULT Get(
1017 1018 1019
        [in, defaultvalue("")] BSTR strObjectPath,
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
1020 1021 1022 1023 1024
        [out, retval] ISWbemObject **objWbemObject);

    [ id(2) ]
    HRESULT GetAsync(
        [in] IDispatch *objWbemSink,
1025 1026 1027 1028
        [in, defaultvalue("")] BSTR strObjectPath,
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
1029 1030 1031 1032

    [ id(3) ]
    HRESULT Delete(
        [in] BSTR strObjectPath,
1033 1034
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet);
1035 1036 1037 1038 1039

    [ id(4) ]
    HRESULT DeleteAsync(
        [in] IDispatch *objWbemSink,
        [in] BSTR strObjectPath,
1040 1041 1042
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
1043 1044 1045 1046

    [ id(5) ]
    HRESULT InstancesOf(
        [in] BSTR strClass,
1047 1048
        [in, defaultvalue(wbemFlagReturnImmediately)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
1049 1050 1051 1052 1053 1054
        [out, retval] ISWbemObjectSet **objWbemObjectSet);

    [ id(6) ]
    HRESULT InstancesOfAsync(
        [in] IDispatch *objWbemSink,
        [in] BSTR strClass,
1055 1056 1057
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
1058 1059 1060

    [ id(7) ]
    HRESULT SubclassesOf(
1061 1062 1063
        [in, defaultvalue("")]  BSTR strSuperclass,
        [in, defaultvalue(wbemFlagReturnImmediately|wbemQueryFlagDeep)]  long iFlags,
        [in, defaultvalue(0)]  IDispatch *objWbemNamedValueSet,
1064 1065 1066 1067 1068
        [out, retval] ISWbemObjectSet **objWbemObjectSet);

    [ id(8) ]
    HRESULT SubclassesOfAsync(
        [in] IDispatch *objWbemSink,
1069 1070 1071 1072
        [in, defaultvalue("")] BSTR strSuperclass,
        [in, defaultvalue(wbemQueryFlagDeep)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
1073 1074 1075 1076

    [ id(9) ]
    HRESULT ExecQuery(
        [in] BSTR strQuery,
1077 1078 1079
        [in, defaultvalue("WQL")] BSTR strQueryLanguage,
        [in, defaultvalue(wbemFlagReturnImmediately)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
1080 1081 1082 1083 1084 1085
        [out, retval] ISWbemObjectSet **objWbemObjectSet);

    [ id(10) ]
    HRESULT ExecQueryAsync(
        [in] IDispatch *objWbemSink,
        [in] BSTR strQuery,
1086 1087 1088 1089
        [in, defaultvalue("WQL")] BSTR strQueryLanguage,
        [in, defaultvalue(0)] long lFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
1090 1091 1092 1093

    [ id(11) ]
    HRESULT AssociatorsOf(
        [in] BSTR strObjectPath,
1094 1095 1096 1097 1098 1099 1100 1101 1102 1103
        [in, defaultvalue("")] BSTR strAssocClass,
        [in, defaultvalue("")] BSTR strResultClass,
        [in, defaultvalue("")] BSTR strResultRole,
        [in, defaultvalue("")] BSTR strRole,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bClassesOnly,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bSchemaOnly,
        [in, defaultvalue("")] BSTR strRequiredAssocQualifier,
        [in, defaultvalue("")] BSTR strRequiredQualifier,
        [in, defaultvalue(wbemFlagReturnImmediately)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
1104 1105 1106 1107 1108 1109
        [out, retval] ISWbemObjectSet **objWbemObjectSet);

    [ id(12) ]
    HRESULT AssociatorsOfAsync(
        [in] IDispatch *objWbemSink,
        [in] BSTR strObjectPath,
1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120
        [in, defaultvalue("")] BSTR strAssocClass,
        [in, defaultvalue("")] BSTR strResultClass,
        [in, defaultvalue("")] BSTR strResultRole,
        [in, defaultvalue("")] BSTR strRole,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bClassesOnly,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bSchemaOnly,
        [in, defaultvalue("")] BSTR strRequiredAssocQualifier,
        [in, defaultvalue("")] BSTR strRequiredQualifier,
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
1121 1122 1123 1124

    [ id(13) ]
    HRESULT ReferencesTo(
        [in] BSTR strObjectPath,
1125 1126 1127 1128 1129 1130 1131
        [in, defaultvalue("")] BSTR strResultClass,
        [in, defaultvalue("")] BSTR strRole,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bClassesOnly,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bSchemaOnly,
        [in, defaultvalue("")] BSTR strRequiredQualifier,
        [in, defaultvalue(wbemFlagReturnImmediately)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
1132 1133 1134 1135 1136 1137
        [out, retval] ISWbemObjectSet **objWbemObjectSet);

    [ id(14) ]
    HRESULT ReferencesToAsync(
        [in] IDispatch *objWbemSink,
        [in] BSTR strObjectPath,
1138 1139 1140 1141 1142 1143 1144 1145
        [in, defaultvalue("")] BSTR strResultClass,
        [in, defaultvalue("")] BSTR strRole,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bClassesOnly,
        [in, defaultvalue(FALSE)] VARIANT_BOOL bSchemaOnly,
        [in, defaultvalue("")] BSTR strRequiredQualifier,
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
1146 1147 1148 1149

    [ id(15) ]
    HRESULT ExecNotificationQuery(
        [in] BSTR strQuery,
1150 1151 1152
        [in, defaultvalue("WQL")] BSTR strQueryLanguage,
        [in, defaultvalue(wbemFlagReturnImmediately|wbemFlagForwardOnly)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
1153 1154 1155 1156 1157 1158
        [out, retval] ISWbemEventSource **objWbemEventSource);

    [ id(16) ]
    HRESULT ExecNotificationQueryAsync(
        [in] IDispatch *objWbemSink,
        [in] BSTR strQuery,
1159 1160 1161 1162
        [in, defaultvalue("WQL")] BSTR strQueryLanguage,
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
1163 1164 1165 1166 1167

    [ id(17) ]
    HRESULT ExecMethod(
        [in] BSTR strObjectPath,
        [in] BSTR strMethodName,
1168 1169 1170
        [in, defaultvalue(0)] IDispatch *objWbemInParameters,
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
1171 1172 1173 1174 1175 1176 1177
        [out, retval] ISWbemObject **objWbemOutParameters);

    [ id(18) ]
    HRESULT ExecMethodAsync(
        [in] IDispatch *objWbemSink,
        [in] BSTR strObjectPath,
        [in] BSTR strMethodName,
1178 1179 1180 1181
        [in, defaultvalue(0)] IDispatch *objWbemInParameters,
        [in, defaultvalue(0)] long iFlags,
        [in, defaultvalue(0)] IDispatch *objWbemNamedValueSet,
        [in, defaultvalue(0)] IDispatch *objWbemAsyncContext);
1182 1183 1184 1185

    [ id(19), propget ]
    HRESULT Security_(
        [out, retval] ISWbemSecurity **objWbemSecurity);
1186
}
1187 1188

[
1189 1190 1191 1192
    threading(apartment),
    uuid(76a64158-cb41-11d1-8b02-00600806d9b6),
    progid("WbemScripting.SWbemLocator.1"),
    vi_progid("WbemScripting.SWbemLocator")
1193 1194 1195 1196
]
coclass SWbemLocator
{
    interface ISWbemLocator;
1197
}
1198

1199
} /* WbemScripting */