@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:37.680Z") @Stability(value=Stable) public interface StandardAttribute extends software.amazon.jsii.JsiiSerializable
Example:
UserPool.Builder.create(this, "myuserpool")
// ...
.standardAttributes(StandardAttributes.builder()
.fullname(StandardAttribute.builder()
.required(true)
.mutable(false)
.build())
.address(StandardAttribute.builder()
.required(false)
.mutable(true)
.build())
.build())
.customAttributes(Map.of(
"myappid", StringAttribute.Builder.create().minLen(5).maxLen(15).mutable(false).build(),
"callingcode", NumberAttribute.Builder.create().min(1).max(3).mutable(true).build(),
"isEmployee", BooleanAttribute.Builder.create().mutable(true).build(),
"joinedOn", new DateTimeAttribute()))
.build();
| Modifier and Type | Interface and Description |
|---|---|
static class |
StandardAttribute.Builder
A builder for
StandardAttribute |
static class |
StandardAttribute.Jsii$Proxy
An implementation for
StandardAttribute |
| Modifier and Type | Method and Description |
|---|---|
static StandardAttribute.Builder |
builder() |
default Boolean |
getMutable()
Specifies whether the value of the attribute can be changed.
|
default Boolean |
getRequired()
Specifies whether the attribute is required upon user registration.
|
@Stability(value=Stable) @Nullable default Boolean getMutable()
For any user pool attribute that's mapped to an identity provider attribute, this must be set to true.
Amazon Cognito updates mapped attributes when users sign in to your application through an identity provider.
If an attribute is immutable, Amazon Cognito throws an error when it attempts to update the attribute.
Default: true
@Stability(value=Stable) @Nullable default Boolean getRequired()
If the attribute is required and the user does not provide a value, registration or sign-in will fail.
Default: false
@Stability(value=Stable) static StandardAttribute.Builder builder()
StandardAttribute.Builder of StandardAttributeCopyright © 2022. All rights reserved.