| | 1 | | // Copyright (c) Microsoft Corporation. All rights reserved. |
| | 2 | | // Licensed under the MIT License. |
| | 3 | |
|
| | 4 | | // <auto-generated/> |
| | 5 | |
|
| | 6 | | #nullable disable |
| | 7 | |
|
| | 8 | | using System; |
| | 9 | | using System.ComponentModel; |
| | 10 | |
|
| | 11 | | namespace Azure.Iot.Hub.Service.Models |
| | 12 | | { |
| | 13 | | /// <summary> The job type. </summary> |
| | 14 | | public readonly partial struct JobRequestType : IEquatable<JobRequestType> |
| | 15 | | { |
| | 16 | | private readonly string _value; |
| | 17 | |
|
| | 18 | | /// <summary> Determines if two <see cref="JobRequestType"/> values are the same. </summary> |
| | 19 | | /// <exception cref="ArgumentNullException"> <paramref name="value"/> is null. </exception> |
| | 20 | | public JobRequestType(string value) |
| | 21 | | { |
| 0 | 22 | | _value = value ?? throw new ArgumentNullException(nameof(value)); |
| 0 | 23 | | } |
| | 24 | |
|
| | 25 | | private const string UnknownValue = "unknown"; |
| | 26 | | private const string ExportValue = "export"; |
| | 27 | | private const string ImportValue = "import"; |
| | 28 | | private const string BackupValue = "backup"; |
| | 29 | | private const string ReadDevicePropertiesValue = "readDeviceProperties"; |
| | 30 | | private const string WriteDevicePropertiesValue = "writeDeviceProperties"; |
| | 31 | | private const string UpdateDeviceConfigurationValue = "updateDeviceConfiguration"; |
| | 32 | | private const string RebootDeviceValue = "rebootDevice"; |
| | 33 | | private const string FactoryResetDeviceValue = "factoryResetDevice"; |
| | 34 | | private const string FirmwareUpdateValue = "firmwareUpdate"; |
| | 35 | | private const string ScheduleDeviceMethodValue = "scheduleDeviceMethod"; |
| | 36 | | private const string ScheduleUpdateTwinValue = "scheduleUpdateTwin"; |
| | 37 | | private const string RestoreFromBackupValue = "restoreFromBackup"; |
| | 38 | | private const string FailoverDataCopyValue = "failoverDataCopy"; |
| | 39 | |
|
| | 40 | | /// <summary> unknown. </summary> |
| 0 | 41 | | public static JobRequestType Unknown { get; } = new JobRequestType(UnknownValue); |
| | 42 | | /// <summary> export. </summary> |
| 0 | 43 | | public static JobRequestType Export { get; } = new JobRequestType(ExportValue); |
| | 44 | | /// <summary> import. </summary> |
| 0 | 45 | | public static JobRequestType Import { get; } = new JobRequestType(ImportValue); |
| | 46 | | /// <summary> backup. </summary> |
| 0 | 47 | | public static JobRequestType Backup { get; } = new JobRequestType(BackupValue); |
| | 48 | | /// <summary> readDeviceProperties. </summary> |
| 0 | 49 | | public static JobRequestType ReadDeviceProperties { get; } = new JobRequestType(ReadDevicePropertiesValue); |
| | 50 | | /// <summary> writeDeviceProperties. </summary> |
| 0 | 51 | | public static JobRequestType WriteDeviceProperties { get; } = new JobRequestType(WriteDevicePropertiesValue); |
| | 52 | | /// <summary> updateDeviceConfiguration. </summary> |
| 0 | 53 | | public static JobRequestType UpdateDeviceConfiguration { get; } = new JobRequestType(UpdateDeviceConfigurationVa |
| | 54 | | /// <summary> rebootDevice. </summary> |
| 0 | 55 | | public static JobRequestType RebootDevice { get; } = new JobRequestType(RebootDeviceValue); |
| | 56 | | /// <summary> factoryResetDevice. </summary> |
| 0 | 57 | | public static JobRequestType FactoryResetDevice { get; } = new JobRequestType(FactoryResetDeviceValue); |
| | 58 | | /// <summary> firmwareUpdate. </summary> |
| 0 | 59 | | public static JobRequestType FirmwareUpdate { get; } = new JobRequestType(FirmwareUpdateValue); |
| | 60 | | /// <summary> scheduleDeviceMethod. </summary> |
| 0 | 61 | | public static JobRequestType ScheduleDeviceMethod { get; } = new JobRequestType(ScheduleDeviceMethodValue); |
| | 62 | | /// <summary> scheduleUpdateTwin. </summary> |
| 0 | 63 | | public static JobRequestType ScheduleUpdateTwin { get; } = new JobRequestType(ScheduleUpdateTwinValue); |
| | 64 | | /// <summary> restoreFromBackup. </summary> |
| 0 | 65 | | public static JobRequestType RestoreFromBackup { get; } = new JobRequestType(RestoreFromBackupValue); |
| | 66 | | /// <summary> failoverDataCopy. </summary> |
| 0 | 67 | | public static JobRequestType FailoverDataCopy { get; } = new JobRequestType(FailoverDataCopyValue); |
| | 68 | | /// <summary> Determines if two <see cref="JobRequestType"/> values are the same. </summary> |
| 0 | 69 | | public static bool operator ==(JobRequestType left, JobRequestType right) => left.Equals(right); |
| | 70 | | /// <summary> Determines if two <see cref="JobRequestType"/> values are not the same. </summary> |
| 0 | 71 | | public static bool operator !=(JobRequestType left, JobRequestType right) => !left.Equals(right); |
| | 72 | | /// <summary> Converts a string to a <see cref="JobRequestType"/>. </summary> |
| 0 | 73 | | public static implicit operator JobRequestType(string value) => new JobRequestType(value); |
| | 74 | |
|
| | 75 | | /// <inheritdoc /> |
| | 76 | | [EditorBrowsable(EditorBrowsableState.Never)] |
| 0 | 77 | | public override bool Equals(object obj) => obj is JobRequestType other && Equals(other); |
| | 78 | | /// <inheritdoc /> |
| 0 | 79 | | public bool Equals(JobRequestType other) => string.Equals(_value, other._value, StringComparison.InvariantCultur |
| | 80 | |
|
| | 81 | | /// <inheritdoc /> |
| | 82 | | [EditorBrowsable(EditorBrowsableState.Never)] |
| 0 | 83 | | public override int GetHashCode() => _value?.GetHashCode() ?? 0; |
| | 84 | | /// <inheritdoc /> |
| 0 | 85 | | public override string ToString() => _value; |
| | 86 | | } |
| | 87 | | } |