
commonMain.aws.sdk.kotlin.services.iam.model.ChangePasswordRequest.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.iam.model
public class ChangePasswordRequest private constructor(builder: Builder) {
/**
* The new password. The new password must conform to the Amazon Web Services account's password policy, if one exists.
*
* The [regex pattern](http://wikipedia.org/wiki/regex) that is used to validate this parameter is a string of characters. That string can include almost any printable ASCII character from the space (`\u0020`) through the end of the ASCII character range (`\u00FF`). You can also include the tab (`\u0009`), line feed (`\u000A`), and carriage return (`\u000D`) characters. Any of these characters are valid in a password. However, many tools, such as the Amazon Web Services Management Console, might restrict the ability to type certain characters because they have special meaning within that tool.
*/
public val newPassword: kotlin.String? = builder.newPassword
/**
* The IAM user's current password.
*/
public val oldPassword: kotlin.String? = builder.oldPassword
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.iam.model.ChangePasswordRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("ChangePasswordRequest(")
append("newPassword=*** Sensitive Data Redacted ***,")
append("oldPassword=*** Sensitive Data Redacted ***")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = newPassword?.hashCode() ?: 0
result = 31 * result + (oldPassword?.hashCode() ?: 0)
return result
}
override fun equals(other: kotlin.Any?): kotlin.Boolean {
if (this === other) return true
if (other == null || this::class != other::class) return false
other as ChangePasswordRequest
if (newPassword != other.newPassword) return false
if (oldPassword != other.oldPassword) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.iam.model.ChangePasswordRequest = Builder(this).apply(block).build()
public class Builder {
/**
* The new password. The new password must conform to the Amazon Web Services account's password policy, if one exists.
*
* The [regex pattern](http://wikipedia.org/wiki/regex) that is used to validate this parameter is a string of characters. That string can include almost any printable ASCII character from the space (`\u0020`) through the end of the ASCII character range (`\u00FF`). You can also include the tab (`\u0009`), line feed (`\u000A`), and carriage return (`\u000D`) characters. Any of these characters are valid in a password. However, many tools, such as the Amazon Web Services Management Console, might restrict the ability to type certain characters because they have special meaning within that tool.
*/
public var newPassword: kotlin.String? = null
/**
* The IAM user's current password.
*/
public var oldPassword: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.iam.model.ChangePasswordRequest) : this() {
this.newPassword = x.newPassword
this.oldPassword = x.oldPassword
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.iam.model.ChangePasswordRequest = ChangePasswordRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy