| | 1 | | // <auto-generated> |
| | 2 | | // Copyright (c) Microsoft Corporation. All rights reserved. |
| | 3 | | // Licensed under the MIT License. See License.txt in the project root for |
| | 4 | | // license information. |
| | 5 | | // |
| | 6 | | // Code generated by Microsoft (R) AutoRest Code Generator. |
| | 7 | | // Changes may cause incorrect behavior and will be lost if the code is |
| | 8 | | // regenerated. |
| | 9 | | // </auto-generated> |
| | 10 | |
|
| | 11 | | namespace Microsoft.Azure.Graph.RBAC.Models |
| | 12 | | { |
| | 13 | | using Microsoft.Rest; |
| | 14 | | using Newtonsoft.Json; |
| | 15 | | using System.Collections; |
| | 16 | | using System.Collections.Generic; |
| | 17 | | using System.Linq; |
| | 18 | |
|
| | 19 | | /// <summary> |
| | 20 | | /// The password profile associated with a user. |
| | 21 | | /// </summary> |
| | 22 | | public partial class PasswordProfile |
| | 23 | | { |
| | 24 | | /// <summary> |
| | 25 | | /// Initializes a new instance of the PasswordProfile class. |
| | 26 | | /// </summary> |
| 4 | 27 | | public PasswordProfile() |
| | 28 | | { |
| | 29 | | CustomInit(); |
| 4 | 30 | | } |
| | 31 | |
|
| | 32 | | /// <summary> |
| | 33 | | /// Initializes a new instance of the PasswordProfile class. |
| | 34 | | /// </summary> |
| | 35 | | /// <param name="password">Password</param> |
| | 36 | | /// <param name="additionalProperties">Unmatched properties from the |
| | 37 | | /// message are deserialized this collection</param> |
| | 38 | | /// <param name="forceChangePasswordNextLogin">Whether to force a |
| | 39 | | /// password change on next login.</param> |
| 0 | 40 | | public PasswordProfile(string password, IDictionary<string, object> additionalProperties = default(IDictionary<s |
| | 41 | | { |
| 0 | 42 | | AdditionalProperties = additionalProperties; |
| 0 | 43 | | Password = password; |
| 0 | 44 | | ForceChangePasswordNextLogin = forceChangePasswordNextLogin; |
| | 45 | | CustomInit(); |
| 0 | 46 | | } |
| | 47 | |
|
| | 48 | | /// <summary> |
| | 49 | | /// An initialization method that performs custom operations like setting defaults |
| | 50 | | /// </summary> |
| | 51 | | partial void CustomInit(); |
| | 52 | |
|
| | 53 | | /// <summary> |
| | 54 | | /// Gets or sets unmatched properties from the message are deserialized |
| | 55 | | /// this collection |
| | 56 | | /// </summary> |
| | 57 | | [JsonExtensionData] |
| 0 | 58 | | public IDictionary<string, object> AdditionalProperties { get; set; } |
| | 59 | |
|
| | 60 | | /// <summary> |
| | 61 | | /// Gets or sets password |
| | 62 | | /// </summary> |
| | 63 | | [JsonProperty(PropertyName = "password")] |
| 12 | 64 | | public string Password { get; set; } |
| | 65 | |
|
| | 66 | | /// <summary> |
| | 67 | | /// Gets or sets whether to force a password change on next login. |
| | 68 | | /// </summary> |
| | 69 | | [JsonProperty(PropertyName = "forceChangePasswordNextLogin")] |
| 8 | 70 | | public bool? ForceChangePasswordNextLogin { get; set; } |
| | 71 | |
|
| | 72 | | /// <summary> |
| | 73 | | /// Validate the object. |
| | 74 | | /// </summary> |
| | 75 | | /// <exception cref="ValidationException"> |
| | 76 | | /// Thrown if validation fails |
| | 77 | | /// </exception> |
| | 78 | | public virtual void Validate() |
| | 79 | | { |
| 4 | 80 | | if (Password == null) |
| | 81 | | { |
| 0 | 82 | | throw new ValidationException(ValidationRules.CannotBeNull, "Password"); |
| | 83 | | } |
| 4 | 84 | | } |
| | 85 | | } |
| | 86 | | } |