zigwin32/win32/security/license_protection.zig

71 lines
2.7 KiB
Zig

//! NOTE: this file is autogenerated, DO NOT MODIFY
//--------------------------------------------------------------------------------
// Section: Constants (0)
//--------------------------------------------------------------------------------
//--------------------------------------------------------------------------------
// Section: Types (1)
//--------------------------------------------------------------------------------
pub const LicenseProtectionStatus = enum(i32) {
Success = 0,
LicenseKeyNotFound = 1,
LicenseKeyUnprotected = 2,
LicenseKeyCorrupted = 3,
LicenseKeyAlreadyExists = 4,
};
pub const Success = LicenseProtectionStatus.Success;
pub const LicenseKeyNotFound = LicenseProtectionStatus.LicenseKeyNotFound;
pub const LicenseKeyUnprotected = LicenseProtectionStatus.LicenseKeyUnprotected;
pub const LicenseKeyCorrupted = LicenseProtectionStatus.LicenseKeyCorrupted;
pub const LicenseKeyAlreadyExists = LicenseProtectionStatus.LicenseKeyAlreadyExists;
//--------------------------------------------------------------------------------
// Section: Functions (2)
//--------------------------------------------------------------------------------
pub extern "licenseprotection" fn RegisterLicenseKeyWithExpiration(
licenseKey: ?[*:0]const u16,
validityInDays: u32,
status: ?*LicenseProtectionStatus,
) callconv(@import("std").os.windows.WINAPI) HRESULT;
pub extern "licenseprotection" fn ValidateLicenseKeyProtection(
licenseKey: ?[*:0]const u16,
notValidBefore: ?*FILETIME,
notValidAfter: ?*FILETIME,
status: ?*LicenseProtectionStatus,
) callconv(@import("std").os.windows.WINAPI) HRESULT;
//--------------------------------------------------------------------------------
// Section: Unicode Aliases (0)
//--------------------------------------------------------------------------------
const thismodule = @This();
pub usingnamespace switch (@import("../zig.zig").unicode_mode) {
.ansi => struct {
},
.wide => struct {
},
.unspecified => if (@import("builtin").is_test) struct {
} else struct {
},
};
//--------------------------------------------------------------------------------
// Section: Imports (3)
//--------------------------------------------------------------------------------
const FILETIME = @import("../foundation.zig").FILETIME;
const HRESULT = @import("../foundation.zig").HRESULT;
const PWSTR = @import("../foundation.zig").PWSTR;
test {
@setEvalBranchQuota(
comptime @import("std").meta.declarations(@This()).len * 3
);
// reference all the pub declarations
if (!@import("builtin").is_test) return;
inline for (comptime @import("std").meta.declarations(@This())) |decl| {
_ = @field(@This(), decl.name);
}
}