
commonMain.aws.sdk.kotlin.services.iam.model.CreateGroupRequest.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.iam.model
public class CreateGroupRequest private constructor(builder: Builder) {
/**
* The name of the group to create. Do not include the path in this value.
*
* IAM user, group, role, and policy names must be unique within the account. Names are not distinguished by case. For example, you cannot create resources named both "MyResource" and "myresource".
*/
public val groupName: kotlin.String? = builder.groupName
/**
* The path to the group. For more information about paths, see [IAM identifiers](https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html) in the *IAM User Guide*.
*
* This parameter is optional. If it is not included, it defaults to a slash (/).
*
* This parameter allows (through its [regex pattern](http://wikipedia.org/wiki/regex)) a string of characters consisting of either a forward slash (/) by itself or a string that must begin and end with forward slashes. In addition, it can contain any ASCII character from the ! (`\u0021`) through the DEL character (`\u007F`), including most punctuation characters, digits, and upper and lowercased letters.
*/
public val path: kotlin.String? = builder.path
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.iam.model.CreateGroupRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("CreateGroupRequest(")
append("groupName=$groupName,")
append("path=$path")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = groupName?.hashCode() ?: 0
result = 31 * result + (path?.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 CreateGroupRequest
if (groupName != other.groupName) return false
if (path != other.path) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.iam.model.CreateGroupRequest = Builder(this).apply(block).build()
public class Builder {
/**
* The name of the group to create. Do not include the path in this value.
*
* IAM user, group, role, and policy names must be unique within the account. Names are not distinguished by case. For example, you cannot create resources named both "MyResource" and "myresource".
*/
public var groupName: kotlin.String? = null
/**
* The path to the group. For more information about paths, see [IAM identifiers](https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html) in the *IAM User Guide*.
*
* This parameter is optional. If it is not included, it defaults to a slash (/).
*
* This parameter allows (through its [regex pattern](http://wikipedia.org/wiki/regex)) a string of characters consisting of either a forward slash (/) by itself or a string that must begin and end with forward slashes. In addition, it can contain any ASCII character from the ! (`\u0021`) through the DEL character (`\u007F`), including most punctuation characters, digits, and upper and lowercased letters.
*/
public var path: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.iam.model.CreateGroupRequest) : this() {
this.groupName = x.groupName
this.path = x.path
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.iam.model.CreateGroupRequest = CreateGroupRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy