From 3d2d46f62fc01e2653d0251ad9703090574e7c41 Mon Sep 17 00:00:00 2001 From: Rob Mensching Date: Wed, 6 Mar 2024 14:48:10 -0800 Subject: Better .nupkg names --- .../VerUtilVersionReleaseLabel.cs | 36 ++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 src/api/burn/WixToolset.BootstrapperApplicationApi/VerUtilVersionReleaseLabel.cs (limited to 'src/api/burn/WixToolset.BootstrapperApplicationApi/VerUtilVersionReleaseLabel.cs') diff --git a/src/api/burn/WixToolset.BootstrapperApplicationApi/VerUtilVersionReleaseLabel.cs b/src/api/burn/WixToolset.BootstrapperApplicationApi/VerUtilVersionReleaseLabel.cs new file mode 100644 index 00000000..03603714 --- /dev/null +++ b/src/api/burn/WixToolset.BootstrapperApplicationApi/VerUtilVersionReleaseLabel.cs @@ -0,0 +1,36 @@ +// 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. + +namespace WixToolset.BootstrapperApplicationApi +{ + using System; + using System.Runtime.InteropServices; + + /// + /// A release label from a . + /// + public sealed class VerUtilVersionReleaseLabel + { + internal VerUtilVersionReleaseLabel(IntPtr pReleaseLabel, IntPtr wzVersion) + { + var releaseLabel = (VerUtil.VersionReleaseLabelStruct)Marshal.PtrToStructure(pReleaseLabel, typeof(VerUtil.VersionReleaseLabelStruct)); + this.IsNumeric = releaseLabel.fNumeric; + this.Value = releaseLabel.dwValue; + this.Label = VerUtil.VersionStringFromOffset(wzVersion, releaseLabel.cchLabelOffset, releaseLabel.cchLabel); + } + + /// + /// Whether the label was parsed as a number. + /// + public bool IsNumeric { get; private set; } + + /// + /// If then the value that was parsed. + /// + public uint Value { get; private set; } + + /// + /// The string version of the label. + /// + public string Label { get; private set; } + } +} -- cgit v1.2.3-55-g6feb