All Downloads are FREE. Search and download functionalities are using the official Maven repository.

software.amazon.awssdk.services.grafana.model.WorkspaceDescription Maven / Gradle / Ivy

/*
 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
 * the License. A copy of the License is located at
 * 
 * http://aws.amazon.com/apache2.0
 * 
 * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
 * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
 * and limitations under the License.
 */

package software.amazon.awssdk.services.grafana.model;

import java.beans.Transient;
import java.io.Serializable;
import java.time.Instant;
import java.util.Arrays;
import java.util.Collection;
import java.util.Collections;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import java.util.function.BiConsumer;
import java.util.function.Consumer;
import java.util.function.Function;
import software.amazon.awssdk.annotations.Generated;
import software.amazon.awssdk.core.SdkField;
import software.amazon.awssdk.core.SdkPojo;
import software.amazon.awssdk.core.protocol.MarshallLocation;
import software.amazon.awssdk.core.protocol.MarshallingType;
import software.amazon.awssdk.core.traits.ListTrait;
import software.amazon.awssdk.core.traits.LocationTrait;
import software.amazon.awssdk.core.util.DefaultSdkAutoConstructList;
import software.amazon.awssdk.core.util.SdkAutoConstructList;
import software.amazon.awssdk.utils.ToString;
import software.amazon.awssdk.utils.builder.CopyableBuilder;
import software.amazon.awssdk.utils.builder.ToCopyableBuilder;

/**
 * 

* A structure containing information about an Amazon Managed Grafana workspace in your account. *

*/ @Generated("software.amazon.awssdk:codegen") public final class WorkspaceDescription implements SdkPojo, Serializable, ToCopyableBuilder { private static final SdkField ACCOUNT_ACCESS_TYPE_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("accountAccessType").getter(getter(WorkspaceDescription::accountAccessTypeAsString)) .setter(setter(Builder::accountAccessType)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("accountAccessType").build()).build(); private static final SdkField AUTHENTICATION_FIELD = SdkField . builder(MarshallingType.SDK_POJO).memberName("authentication") .getter(getter(WorkspaceDescription::authentication)).setter(setter(Builder::authentication)) .constructor(AuthenticationSummary::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("authentication").build()).build(); private static final SdkField CREATED_FIELD = SdkField. builder(MarshallingType.INSTANT) .memberName("created").getter(getter(WorkspaceDescription::created)).setter(setter(Builder::created)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("created").build()).build(); private static final SdkField> DATA_SOURCES_FIELD = SdkField .> builder(MarshallingType.LIST) .memberName("dataSources") .getter(getter(WorkspaceDescription::dataSourcesAsStrings)) .setter(setter(Builder::dataSourcesWithStrings)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("dataSources").build(), ListTrait .builder() .memberLocationName(null) .memberFieldInfo( SdkField. builder(MarshallingType.STRING) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD) .locationName("member").build()).build()).build()).build(); private static final SdkField DESCRIPTION_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("description").getter(getter(WorkspaceDescription::description)).setter(setter(Builder::description)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("description").build()).build(); private static final SdkField ENDPOINT_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("endpoint").getter(getter(WorkspaceDescription::endpoint)).setter(setter(Builder::endpoint)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("endpoint").build()).build(); private static final SdkField FREE_TRIAL_CONSUMED_FIELD = SdkField. builder(MarshallingType.BOOLEAN) .memberName("freeTrialConsumed").getter(getter(WorkspaceDescription::freeTrialConsumed)) .setter(setter(Builder::freeTrialConsumed)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("freeTrialConsumed").build()).build(); private static final SdkField FREE_TRIAL_EXPIRATION_FIELD = SdkField. builder(MarshallingType.INSTANT) .memberName("freeTrialExpiration").getter(getter(WorkspaceDescription::freeTrialExpiration)) .setter(setter(Builder::freeTrialExpiration)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("freeTrialExpiration").build()) .build(); private static final SdkField GRAFANA_VERSION_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("grafanaVersion").getter(getter(WorkspaceDescription::grafanaVersion)) .setter(setter(Builder::grafanaVersion)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("grafanaVersion").build()).build(); private static final SdkField ID_FIELD = SdkField. builder(MarshallingType.STRING).memberName("id") .getter(getter(WorkspaceDescription::id)).setter(setter(Builder::id)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("id").build()).build(); private static final SdkField LICENSE_EXPIRATION_FIELD = SdkField. builder(MarshallingType.INSTANT) .memberName("licenseExpiration").getter(getter(WorkspaceDescription::licenseExpiration)) .setter(setter(Builder::licenseExpiration)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("licenseExpiration").build()).build(); private static final SdkField LICENSE_TYPE_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("licenseType").getter(getter(WorkspaceDescription::licenseTypeAsString)) .setter(setter(Builder::licenseType)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("licenseType").build()).build(); private static final SdkField MODIFIED_FIELD = SdkField. builder(MarshallingType.INSTANT) .memberName("modified").getter(getter(WorkspaceDescription::modified)).setter(setter(Builder::modified)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("modified").build()).build(); private static final SdkField NAME_FIELD = SdkField. builder(MarshallingType.STRING).memberName("name") .getter(getter(WorkspaceDescription::name)).setter(setter(Builder::name)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("name").build()).build(); private static final SdkField> NOTIFICATION_DESTINATIONS_FIELD = SdkField .> builder(MarshallingType.LIST) .memberName("notificationDestinations") .getter(getter(WorkspaceDescription::notificationDestinationsAsStrings)) .setter(setter(Builder::notificationDestinationsWithStrings)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("notificationDestinations").build(), ListTrait .builder() .memberLocationName(null) .memberFieldInfo( SdkField. builder(MarshallingType.STRING) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD) .locationName("member").build()).build()).build()).build(); private static final SdkField ORGANIZATION_ROLE_NAME_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("organizationRoleName").getter(getter(WorkspaceDescription::organizationRoleName)) .setter(setter(Builder::organizationRoleName)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("organizationRoleName").build()) .build(); private static final SdkField> ORGANIZATIONAL_UNITS_FIELD = SdkField .> builder(MarshallingType.LIST) .memberName("organizationalUnits") .getter(getter(WorkspaceDescription::organizationalUnits)) .setter(setter(Builder::organizationalUnits)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("organizationalUnits").build(), ListTrait .builder() .memberLocationName(null) .memberFieldInfo( SdkField. builder(MarshallingType.STRING) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD) .locationName("member").build()).build()).build()).build(); private static final SdkField PERMISSION_TYPE_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("permissionType").getter(getter(WorkspaceDescription::permissionTypeAsString)) .setter(setter(Builder::permissionType)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("permissionType").build()).build(); private static final SdkField STACK_SET_NAME_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("stackSetName").getter(getter(WorkspaceDescription::stackSetName)).setter(setter(Builder::stackSetName)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("stackSetName").build()).build(); private static final SdkField STATUS_FIELD = SdkField. builder(MarshallingType.STRING).memberName("status") .getter(getter(WorkspaceDescription::statusAsString)).setter(setter(Builder::status)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("status").build()).build(); private static final SdkField WORKSPACE_ROLE_ARN_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("workspaceRoleArn").getter(getter(WorkspaceDescription::workspaceRoleArn)) .setter(setter(Builder::workspaceRoleArn)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("workspaceRoleArn").build()).build(); private static final List> SDK_FIELDS = Collections.unmodifiableList(Arrays.asList(ACCOUNT_ACCESS_TYPE_FIELD, AUTHENTICATION_FIELD, CREATED_FIELD, DATA_SOURCES_FIELD, DESCRIPTION_FIELD, ENDPOINT_FIELD, FREE_TRIAL_CONSUMED_FIELD, FREE_TRIAL_EXPIRATION_FIELD, GRAFANA_VERSION_FIELD, ID_FIELD, LICENSE_EXPIRATION_FIELD, LICENSE_TYPE_FIELD, MODIFIED_FIELD, NAME_FIELD, NOTIFICATION_DESTINATIONS_FIELD, ORGANIZATION_ROLE_NAME_FIELD, ORGANIZATIONAL_UNITS_FIELD, PERMISSION_TYPE_FIELD, STACK_SET_NAME_FIELD, STATUS_FIELD, WORKSPACE_ROLE_ARN_FIELD)); private static final long serialVersionUID = 1L; private final String accountAccessType; private final AuthenticationSummary authentication; private final Instant created; private final List dataSources; private final String description; private final String endpoint; private final Boolean freeTrialConsumed; private final Instant freeTrialExpiration; private final String grafanaVersion; private final String id; private final Instant licenseExpiration; private final String licenseType; private final Instant modified; private final String name; private final List notificationDestinations; private final String organizationRoleName; private final List organizationalUnits; private final String permissionType; private final String stackSetName; private final String status; private final String workspaceRoleArn; private WorkspaceDescription(BuilderImpl builder) { this.accountAccessType = builder.accountAccessType; this.authentication = builder.authentication; this.created = builder.created; this.dataSources = builder.dataSources; this.description = builder.description; this.endpoint = builder.endpoint; this.freeTrialConsumed = builder.freeTrialConsumed; this.freeTrialExpiration = builder.freeTrialExpiration; this.grafanaVersion = builder.grafanaVersion; this.id = builder.id; this.licenseExpiration = builder.licenseExpiration; this.licenseType = builder.licenseType; this.modified = builder.modified; this.name = builder.name; this.notificationDestinations = builder.notificationDestinations; this.organizationRoleName = builder.organizationRoleName; this.organizationalUnits = builder.organizationalUnits; this.permissionType = builder.permissionType; this.stackSetName = builder.stackSetName; this.status = builder.status; this.workspaceRoleArn = builder.workspaceRoleArn; } /** *

* Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services account * only, or whether it can also access Amazon Web Services resources in other accounts in the same organization. If * this is ORGANIZATION, the workspaceOrganizationalUnits parameter specifies which * organizational units the workspace can access. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #accountAccessType} * will return {@link AccountAccessType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available * from {@link #accountAccessTypeAsString}. *

* * @return Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services * account only, or whether it can also access Amazon Web Services resources in other accounts in the same * organization. If this is ORGANIZATION, the workspaceOrganizationalUnits * parameter specifies which organizational units the workspace can access. * @see AccountAccessType */ public final AccountAccessType accountAccessType() { return AccountAccessType.fromValue(accountAccessType); } /** *

* Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services account * only, or whether it can also access Amazon Web Services resources in other accounts in the same organization. If * this is ORGANIZATION, the workspaceOrganizationalUnits parameter specifies which * organizational units the workspace can access. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #accountAccessType} * will return {@link AccountAccessType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available * from {@link #accountAccessTypeAsString}. *

* * @return Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services * account only, or whether it can also access Amazon Web Services resources in other accounts in the same * organization. If this is ORGANIZATION, the workspaceOrganizationalUnits * parameter specifies which organizational units the workspace can access. * @see AccountAccessType */ public final String accountAccessTypeAsString() { return accountAccessType; } /** *

* A structure that describes whether the workspace uses SAML, Amazon Web Services SSO, or both methods for user * authentication. *

* * @return A structure that describes whether the workspace uses SAML, Amazon Web Services SSO, or both methods for * user authentication. */ public final AuthenticationSummary authentication() { return authentication; } /** *

* The date that the workspace was created. *

* * @return The date that the workspace was created. */ public final Instant created() { return created; } /** *

* Specifies the Amazon Web Services data sources that have been configured to have IAM roles and permissions * created to allow Amazon Managed Grafana to read data from these sources. *

*

* Attempts to modify the collection returned by this method will result in an UnsupportedOperationException. *

*

* This method will never return null. If you would like to know whether the service returned this field (so that * you can differentiate between null and empty), you can use the {@link #hasDataSources} method. *

* * @return Specifies the Amazon Web Services data sources that have been configured to have IAM roles and * permissions created to allow Amazon Managed Grafana to read data from these sources. */ public final List dataSources() { return DataSourceTypesListCopier.copyStringToEnum(dataSources); } /** * For responses, this returns true if the service returned a value for the DataSources property. This DOES NOT * check that the value is non-empty (for which, you should check the {@code isEmpty()} method on the property). * This is useful because the SDK will never return a null collection or map, but you may need to differentiate * between the service returning nothing (or null) and the service returning an empty collection or map. For * requests, this returns true if a value for the property was specified in the request builder, and false if a * value was not specified. */ public final boolean hasDataSources() { return dataSources != null && !(dataSources instanceof SdkAutoConstructList); } /** *

* Specifies the Amazon Web Services data sources that have been configured to have IAM roles and permissions * created to allow Amazon Managed Grafana to read data from these sources. *

*

* Attempts to modify the collection returned by this method will result in an UnsupportedOperationException. *

*

* This method will never return null. If you would like to know whether the service returned this field (so that * you can differentiate between null and empty), you can use the {@link #hasDataSources} method. *

* * @return Specifies the Amazon Web Services data sources that have been configured to have IAM roles and * permissions created to allow Amazon Managed Grafana to read data from these sources. */ public final List dataSourcesAsStrings() { return dataSources; } /** *

* The user-defined description of the workspace. *

* * @return The user-defined description of the workspace. */ public final String description() { return description; } /** *

* The URL that users can use to access the Grafana console in the workspace. *

* * @return The URL that users can use to access the Grafana console in the workspace. */ public final String endpoint() { return endpoint; } /** *

* Specifies whether this workspace has already fully used its free trial for Grafana Enterprise. *

* * @return Specifies whether this workspace has already fully used its free trial for Grafana Enterprise. */ public final Boolean freeTrialConsumed() { return freeTrialConsumed; } /** *

* If this workspace is currently in the free trial period for Grafana Enterprise, this value specifies when that * free trial ends. *

* * @return If this workspace is currently in the free trial period for Grafana Enterprise, this value specifies when * that free trial ends. */ public final Instant freeTrialExpiration() { return freeTrialExpiration; } /** *

* The version of Grafana supported in this workspace. *

* * @return The version of Grafana supported in this workspace. */ public final String grafanaVersion() { return grafanaVersion; } /** *

* The unique ID of this workspace. *

* * @return The unique ID of this workspace. */ public final String id() { return id; } /** *

* If this workspace has a full Grafana Enterprise license, this specifies when the license ends and will need to be * renewed. *

* * @return If this workspace has a full Grafana Enterprise license, this specifies when the license ends and will * need to be renewed. */ public final Instant licenseExpiration() { return licenseExpiration; } /** *

* Specifies whether this workspace has a full Grafana Enterprise license or a free trial license. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #licenseType} will * return {@link LicenseType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #licenseTypeAsString}. *

* * @return Specifies whether this workspace has a full Grafana Enterprise license or a free trial license. * @see LicenseType */ public final LicenseType licenseType() { return LicenseType.fromValue(licenseType); } /** *

* Specifies whether this workspace has a full Grafana Enterprise license or a free trial license. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #licenseType} will * return {@link LicenseType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #licenseTypeAsString}. *

* * @return Specifies whether this workspace has a full Grafana Enterprise license or a free trial license. * @see LicenseType */ public final String licenseTypeAsString() { return licenseType; } /** *

* The most recent date that the workspace was modified. *

* * @return The most recent date that the workspace was modified. */ public final Instant modified() { return modified; } /** *

* The name of the workspace. *

* * @return The name of the workspace. */ public final String name() { return name; } /** *

* The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM roles and * permissions for, to allow Amazon Managed Grafana to use these channels. *

*

* Attempts to modify the collection returned by this method will result in an UnsupportedOperationException. *

*

* This method will never return null. If you would like to know whether the service returned this field (so that * you can differentiate between null and empty), you can use the {@link #hasNotificationDestinations} method. *

* * @return The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM * roles and permissions for, to allow Amazon Managed Grafana to use these channels. */ public final List notificationDestinations() { return NotificationDestinationsListCopier.copyStringToEnum(notificationDestinations); } /** * For responses, this returns true if the service returned a value for the NotificationDestinations property. This * DOES NOT check that the value is non-empty (for which, you should check the {@code isEmpty()} method on the * property). This is useful because the SDK will never return a null collection or map, but you may need to * differentiate between the service returning nothing (or null) and the service returning an empty collection or * map. For requests, this returns true if a value for the property was specified in the request builder, and false * if a value was not specified. */ public final boolean hasNotificationDestinations() { return notificationDestinations != null && !(notificationDestinations instanceof SdkAutoConstructList); } /** *

* The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM roles and * permissions for, to allow Amazon Managed Grafana to use these channels. *

*

* Attempts to modify the collection returned by this method will result in an UnsupportedOperationException. *

*

* This method will never return null. If you would like to know whether the service returned this field (so that * you can differentiate between null and empty), you can use the {@link #hasNotificationDestinations} method. *

* * @return The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM * roles and permissions for, to allow Amazon Managed Grafana to use these channels. */ public final List notificationDestinationsAsStrings() { return notificationDestinations; } /** *

* The name of the IAM role that is used to access resources through Organizations. *

* * @return The name of the IAM role that is used to access resources through Organizations. */ public final String organizationRoleName() { return organizationRoleName; } /** * For responses, this returns true if the service returned a value for the OrganizationalUnits property. This DOES * NOT check that the value is non-empty (for which, you should check the {@code isEmpty()} method on the property). * This is useful because the SDK will never return a null collection or map, but you may need to differentiate * between the service returning nothing (or null) and the service returning an empty collection or map. For * requests, this returns true if a value for the property was specified in the request builder, and false if a * value was not specified. */ public final boolean hasOrganizationalUnits() { return organizationalUnits != null && !(organizationalUnits instanceof SdkAutoConstructList); } /** *

* Specifies the organizational units that this workspace is allowed to use data sources from, if this workspace is * in an account that is part of an organization. *

*

* Attempts to modify the collection returned by this method will result in an UnsupportedOperationException. *

*

* This method will never return null. If you would like to know whether the service returned this field (so that * you can differentiate between null and empty), you can use the {@link #hasOrganizationalUnits} method. *

* * @return Specifies the organizational units that this workspace is allowed to use data sources from, if this * workspace is in an account that is part of an organization. */ public final List organizationalUnits() { return organizationalUnits; } /** *

* If this is Service Managed, Amazon Managed Grafana automatically creates the IAM roles and * provisions the permissions that the workspace needs to use Amazon Web Services data sources and notification * channels. *

*

* If this is CUSTOMER_MANAGED, you manage those roles and permissions yourself. If you are creating * this workspace in a member account of an organization and that account is not a delegated administrator account, * and you want the workspace to access data sources in other Amazon Web Services accounts in the organization, you * must choose CUSTOMER_MANAGED. *

*

* For more information, see Amazon Managed Grafana * permissions and policies for Amazon Web Services data sources and notification channels *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #permissionType} * will return {@link PermissionType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available * from {@link #permissionTypeAsString}. *

* * @return If this is Service Managed, Amazon Managed Grafana automatically creates the IAM roles and * provisions the permissions that the workspace needs to use Amazon Web Services data sources and * notification channels.

*

* If this is CUSTOMER_MANAGED, you manage those roles and permissions yourself. If you are * creating this workspace in a member account of an organization and that account is not a delegated * administrator account, and you want the workspace to access data sources in other Amazon Web Services * accounts in the organization, you must choose CUSTOMER_MANAGED. *

*

* For more information, see Amazon Managed * Grafana permissions and policies for Amazon Web Services data sources and notification channels * @see PermissionType */ public final PermissionType permissionType() { return PermissionType.fromValue(permissionType); } /** *

* If this is Service Managed, Amazon Managed Grafana automatically creates the IAM roles and * provisions the permissions that the workspace needs to use Amazon Web Services data sources and notification * channels. *

*

* If this is CUSTOMER_MANAGED, you manage those roles and permissions yourself. If you are creating * this workspace in a member account of an organization and that account is not a delegated administrator account, * and you want the workspace to access data sources in other Amazon Web Services accounts in the organization, you * must choose CUSTOMER_MANAGED. *

*

* For more information, see Amazon Managed Grafana * permissions and policies for Amazon Web Services data sources and notification channels *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #permissionType} * will return {@link PermissionType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available * from {@link #permissionTypeAsString}. *

* * @return If this is Service Managed, Amazon Managed Grafana automatically creates the IAM roles and * provisions the permissions that the workspace needs to use Amazon Web Services data sources and * notification channels.

*

* If this is CUSTOMER_MANAGED, you manage those roles and permissions yourself. If you are * creating this workspace in a member account of an organization and that account is not a delegated * administrator account, and you want the workspace to access data sources in other Amazon Web Services * accounts in the organization, you must choose CUSTOMER_MANAGED. *

*

* For more information, see Amazon Managed * Grafana permissions and policies for Amazon Web Services data sources and notification channels * @see PermissionType */ public final String permissionTypeAsString() { return permissionType; } /** *

* The name of the CloudFormation stack set that is used to generate IAM roles to be used for this workspace. *

* * @return The name of the CloudFormation stack set that is used to generate IAM roles to be used for this * workspace. */ public final String stackSetName() { return stackSetName; } /** *

* The current status of the workspace. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #status} will * return {@link WorkspaceStatus#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #statusAsString}. *

* * @return The current status of the workspace. * @see WorkspaceStatus */ public final WorkspaceStatus status() { return WorkspaceStatus.fromValue(status); } /** *

* The current status of the workspace. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #status} will * return {@link WorkspaceStatus#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #statusAsString}. *

* * @return The current status of the workspace. * @see WorkspaceStatus */ public final String statusAsString() { return status; } /** *

* The IAM role that grants permissions to the Amazon Web Services resources that the workspace will view data from. * This role must already exist. *

* * @return The IAM role that grants permissions to the Amazon Web Services resources that the workspace will view * data from. This role must already exist. */ public final String workspaceRoleArn() { return workspaceRoleArn; } @Override public Builder toBuilder() { return new BuilderImpl(this); } public static Builder builder() { return new BuilderImpl(); } public static Class serializableBuilderClass() { return BuilderImpl.class; } @Override public final int hashCode() { int hashCode = 1; hashCode = 31 * hashCode + Objects.hashCode(accountAccessTypeAsString()); hashCode = 31 * hashCode + Objects.hashCode(authentication()); hashCode = 31 * hashCode + Objects.hashCode(created()); hashCode = 31 * hashCode + Objects.hashCode(hasDataSources() ? dataSourcesAsStrings() : null); hashCode = 31 * hashCode + Objects.hashCode(description()); hashCode = 31 * hashCode + Objects.hashCode(endpoint()); hashCode = 31 * hashCode + Objects.hashCode(freeTrialConsumed()); hashCode = 31 * hashCode + Objects.hashCode(freeTrialExpiration()); hashCode = 31 * hashCode + Objects.hashCode(grafanaVersion()); hashCode = 31 * hashCode + Objects.hashCode(id()); hashCode = 31 * hashCode + Objects.hashCode(licenseExpiration()); hashCode = 31 * hashCode + Objects.hashCode(licenseTypeAsString()); hashCode = 31 * hashCode + Objects.hashCode(modified()); hashCode = 31 * hashCode + Objects.hashCode(name()); hashCode = 31 * hashCode + Objects.hashCode(hasNotificationDestinations() ? notificationDestinationsAsStrings() : null); hashCode = 31 * hashCode + Objects.hashCode(organizationRoleName()); hashCode = 31 * hashCode + Objects.hashCode(hasOrganizationalUnits() ? organizationalUnits() : null); hashCode = 31 * hashCode + Objects.hashCode(permissionTypeAsString()); hashCode = 31 * hashCode + Objects.hashCode(stackSetName()); hashCode = 31 * hashCode + Objects.hashCode(statusAsString()); hashCode = 31 * hashCode + Objects.hashCode(workspaceRoleArn()); return hashCode; } @Override public final boolean equals(Object obj) { return equalsBySdkFields(obj); } @Override public final boolean equalsBySdkFields(Object obj) { if (this == obj) { return true; } if (obj == null) { return false; } if (!(obj instanceof WorkspaceDescription)) { return false; } WorkspaceDescription other = (WorkspaceDescription) obj; return Objects.equals(accountAccessTypeAsString(), other.accountAccessTypeAsString()) && Objects.equals(authentication(), other.authentication()) && Objects.equals(created(), other.created()) && hasDataSources() == other.hasDataSources() && Objects.equals(dataSourcesAsStrings(), other.dataSourcesAsStrings()) && Objects.equals(description(), other.description()) && Objects.equals(endpoint(), other.endpoint()) && Objects.equals(freeTrialConsumed(), other.freeTrialConsumed()) && Objects.equals(freeTrialExpiration(), other.freeTrialExpiration()) && Objects.equals(grafanaVersion(), other.grafanaVersion()) && Objects.equals(id(), other.id()) && Objects.equals(licenseExpiration(), other.licenseExpiration()) && Objects.equals(licenseTypeAsString(), other.licenseTypeAsString()) && Objects.equals(modified(), other.modified()) && Objects.equals(name(), other.name()) && hasNotificationDestinations() == other.hasNotificationDestinations() && Objects.equals(notificationDestinationsAsStrings(), other.notificationDestinationsAsStrings()) && Objects.equals(organizationRoleName(), other.organizationRoleName()) && hasOrganizationalUnits() == other.hasOrganizationalUnits() && Objects.equals(organizationalUnits(), other.organizationalUnits()) && Objects.equals(permissionTypeAsString(), other.permissionTypeAsString()) && Objects.equals(stackSetName(), other.stackSetName()) && Objects.equals(statusAsString(), other.statusAsString()) && Objects.equals(workspaceRoleArn(), other.workspaceRoleArn()); } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. */ @Override public final String toString() { return ToString.builder("WorkspaceDescription").add("AccountAccessType", accountAccessTypeAsString()) .add("Authentication", authentication()).add("Created", created()) .add("DataSources", hasDataSources() ? dataSourcesAsStrings() : null) .add("Description", description() == null ? null : "*** Sensitive Data Redacted ***").add("Endpoint", endpoint()) .add("FreeTrialConsumed", freeTrialConsumed()).add("FreeTrialExpiration", freeTrialExpiration()) .add("GrafanaVersion", grafanaVersion()).add("Id", id()).add("LicenseExpiration", licenseExpiration()) .add("LicenseType", licenseTypeAsString()).add("Modified", modified()) .add("Name", name() == null ? null : "*** Sensitive Data Redacted ***") .add("NotificationDestinations", hasNotificationDestinations() ? notificationDestinationsAsStrings() : null) .add("OrganizationRoleName", organizationRoleName() == null ? null : "*** Sensitive Data Redacted ***") .add("OrganizationalUnits", organizationalUnits() == null ? null : "*** Sensitive Data Redacted ***") .add("PermissionType", permissionTypeAsString()).add("StackSetName", stackSetName()) .add("Status", statusAsString()) .add("WorkspaceRoleArn", workspaceRoleArn() == null ? null : "*** Sensitive Data Redacted ***").build(); } public final Optional getValueForField(String fieldName, Class clazz) { switch (fieldName) { case "accountAccessType": return Optional.ofNullable(clazz.cast(accountAccessTypeAsString())); case "authentication": return Optional.ofNullable(clazz.cast(authentication())); case "created": return Optional.ofNullable(clazz.cast(created())); case "dataSources": return Optional.ofNullable(clazz.cast(dataSourcesAsStrings())); case "description": return Optional.ofNullable(clazz.cast(description())); case "endpoint": return Optional.ofNullable(clazz.cast(endpoint())); case "freeTrialConsumed": return Optional.ofNullable(clazz.cast(freeTrialConsumed())); case "freeTrialExpiration": return Optional.ofNullable(clazz.cast(freeTrialExpiration())); case "grafanaVersion": return Optional.ofNullable(clazz.cast(grafanaVersion())); case "id": return Optional.ofNullable(clazz.cast(id())); case "licenseExpiration": return Optional.ofNullable(clazz.cast(licenseExpiration())); case "licenseType": return Optional.ofNullable(clazz.cast(licenseTypeAsString())); case "modified": return Optional.ofNullable(clazz.cast(modified())); case "name": return Optional.ofNullable(clazz.cast(name())); case "notificationDestinations": return Optional.ofNullable(clazz.cast(notificationDestinationsAsStrings())); case "organizationRoleName": return Optional.ofNullable(clazz.cast(organizationRoleName())); case "organizationalUnits": return Optional.ofNullable(clazz.cast(organizationalUnits())); case "permissionType": return Optional.ofNullable(clazz.cast(permissionTypeAsString())); case "stackSetName": return Optional.ofNullable(clazz.cast(stackSetName())); case "status": return Optional.ofNullable(clazz.cast(statusAsString())); case "workspaceRoleArn": return Optional.ofNullable(clazz.cast(workspaceRoleArn())); default: return Optional.empty(); } } @Override public final List> sdkFields() { return SDK_FIELDS; } private static Function getter(Function g) { return obj -> g.apply((WorkspaceDescription) obj); } private static BiConsumer setter(BiConsumer s) { return (obj, val) -> s.accept((Builder) obj, val); } public interface Builder extends SdkPojo, CopyableBuilder { /** *

* Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services account * only, or whether it can also access Amazon Web Services resources in other accounts in the same organization. * If this is ORGANIZATION, the workspaceOrganizationalUnits parameter specifies which * organizational units the workspace can access. *

* * @param accountAccessType * Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services * account only, or whether it can also access Amazon Web Services resources in other accounts in the * same organization. If this is ORGANIZATION, the workspaceOrganizationalUnits * parameter specifies which organizational units the workspace can access. * @see AccountAccessType * @return Returns a reference to this object so that method calls can be chained together. * @see AccountAccessType */ Builder accountAccessType(String accountAccessType); /** *

* Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services account * only, or whether it can also access Amazon Web Services resources in other accounts in the same organization. * If this is ORGANIZATION, the workspaceOrganizationalUnits parameter specifies which * organizational units the workspace can access. *

* * @param accountAccessType * Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services * account only, or whether it can also access Amazon Web Services resources in other accounts in the * same organization. If this is ORGANIZATION, the workspaceOrganizationalUnits * parameter specifies which organizational units the workspace can access. * @see AccountAccessType * @return Returns a reference to this object so that method calls can be chained together. * @see AccountAccessType */ Builder accountAccessType(AccountAccessType accountAccessType); /** *

* A structure that describes whether the workspace uses SAML, Amazon Web Services SSO, or both methods for user * authentication. *

* * @param authentication * A structure that describes whether the workspace uses SAML, Amazon Web Services SSO, or both methods * for user authentication. * @return Returns a reference to this object so that method calls can be chained together. */ Builder authentication(AuthenticationSummary authentication); /** *

* A structure that describes whether the workspace uses SAML, Amazon Web Services SSO, or both methods for user * authentication. *

* This is a convenience that creates an instance of the {@link AuthenticationSummary.Builder} avoiding the need * to create one manually via {@link AuthenticationSummary#builder()}. * * When the {@link Consumer} completes, {@link AuthenticationSummary.Builder#build()} is called immediately and * its result is passed to {@link #authentication(AuthenticationSummary)}. * * @param authentication * a consumer that will call methods on {@link AuthenticationSummary.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #authentication(AuthenticationSummary) */ default Builder authentication(Consumer authentication) { return authentication(AuthenticationSummary.builder().applyMutation(authentication).build()); } /** *

* The date that the workspace was created. *

* * @param created * The date that the workspace was created. * @return Returns a reference to this object so that method calls can be chained together. */ Builder created(Instant created); /** *

* Specifies the Amazon Web Services data sources that have been configured to have IAM roles and permissions * created to allow Amazon Managed Grafana to read data from these sources. *

* * @param dataSources * Specifies the Amazon Web Services data sources that have been configured to have IAM roles and * permissions created to allow Amazon Managed Grafana to read data from these sources. * @return Returns a reference to this object so that method calls can be chained together. */ Builder dataSourcesWithStrings(Collection dataSources); /** *

* Specifies the Amazon Web Services data sources that have been configured to have IAM roles and permissions * created to allow Amazon Managed Grafana to read data from these sources. *

* * @param dataSources * Specifies the Amazon Web Services data sources that have been configured to have IAM roles and * permissions created to allow Amazon Managed Grafana to read data from these sources. * @return Returns a reference to this object so that method calls can be chained together. */ Builder dataSourcesWithStrings(String... dataSources); /** *

* Specifies the Amazon Web Services data sources that have been configured to have IAM roles and permissions * created to allow Amazon Managed Grafana to read data from these sources. *

* * @param dataSources * Specifies the Amazon Web Services data sources that have been configured to have IAM roles and * permissions created to allow Amazon Managed Grafana to read data from these sources. * @return Returns a reference to this object so that method calls can be chained together. */ Builder dataSources(Collection dataSources); /** *

* Specifies the Amazon Web Services data sources that have been configured to have IAM roles and permissions * created to allow Amazon Managed Grafana to read data from these sources. *

* * @param dataSources * Specifies the Amazon Web Services data sources that have been configured to have IAM roles and * permissions created to allow Amazon Managed Grafana to read data from these sources. * @return Returns a reference to this object so that method calls can be chained together. */ Builder dataSources(DataSourceType... dataSources); /** *

* The user-defined description of the workspace. *

* * @param description * The user-defined description of the workspace. * @return Returns a reference to this object so that method calls can be chained together. */ Builder description(String description); /** *

* The URL that users can use to access the Grafana console in the workspace. *

* * @param endpoint * The URL that users can use to access the Grafana console in the workspace. * @return Returns a reference to this object so that method calls can be chained together. */ Builder endpoint(String endpoint); /** *

* Specifies whether this workspace has already fully used its free trial for Grafana Enterprise. *

* * @param freeTrialConsumed * Specifies whether this workspace has already fully used its free trial for Grafana Enterprise. * @return Returns a reference to this object so that method calls can be chained together. */ Builder freeTrialConsumed(Boolean freeTrialConsumed); /** *

* If this workspace is currently in the free trial period for Grafana Enterprise, this value specifies when * that free trial ends. *

* * @param freeTrialExpiration * If this workspace is currently in the free trial period for Grafana Enterprise, this value specifies * when that free trial ends. * @return Returns a reference to this object so that method calls can be chained together. */ Builder freeTrialExpiration(Instant freeTrialExpiration); /** *

* The version of Grafana supported in this workspace. *

* * @param grafanaVersion * The version of Grafana supported in this workspace. * @return Returns a reference to this object so that method calls can be chained together. */ Builder grafanaVersion(String grafanaVersion); /** *

* The unique ID of this workspace. *

* * @param id * The unique ID of this workspace. * @return Returns a reference to this object so that method calls can be chained together. */ Builder id(String id); /** *

* If this workspace has a full Grafana Enterprise license, this specifies when the license ends and will need * to be renewed. *

* * @param licenseExpiration * If this workspace has a full Grafana Enterprise license, this specifies when the license ends and will * need to be renewed. * @return Returns a reference to this object so that method calls can be chained together. */ Builder licenseExpiration(Instant licenseExpiration); /** *

* Specifies whether this workspace has a full Grafana Enterprise license or a free trial license. *

* * @param licenseType * Specifies whether this workspace has a full Grafana Enterprise license or a free trial license. * @see LicenseType * @return Returns a reference to this object so that method calls can be chained together. * @see LicenseType */ Builder licenseType(String licenseType); /** *

* Specifies whether this workspace has a full Grafana Enterprise license or a free trial license. *

* * @param licenseType * Specifies whether this workspace has a full Grafana Enterprise license or a free trial license. * @see LicenseType * @return Returns a reference to this object so that method calls can be chained together. * @see LicenseType */ Builder licenseType(LicenseType licenseType); /** *

* The most recent date that the workspace was modified. *

* * @param modified * The most recent date that the workspace was modified. * @return Returns a reference to this object so that method calls can be chained together. */ Builder modified(Instant modified); /** *

* The name of the workspace. *

* * @param name * The name of the workspace. * @return Returns a reference to this object so that method calls can be chained together. */ Builder name(String name); /** *

* The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM roles * and permissions for, to allow Amazon Managed Grafana to use these channels. *

* * @param notificationDestinations * The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM * roles and permissions for, to allow Amazon Managed Grafana to use these channels. * @return Returns a reference to this object so that method calls can be chained together. */ Builder notificationDestinationsWithStrings(Collection notificationDestinations); /** *

* The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM roles * and permissions for, to allow Amazon Managed Grafana to use these channels. *

* * @param notificationDestinations * The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM * roles and permissions for, to allow Amazon Managed Grafana to use these channels. * @return Returns a reference to this object so that method calls can be chained together. */ Builder notificationDestinationsWithStrings(String... notificationDestinations); /** *

* The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM roles * and permissions for, to allow Amazon Managed Grafana to use these channels. *

* * @param notificationDestinations * The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM * roles and permissions for, to allow Amazon Managed Grafana to use these channels. * @return Returns a reference to this object so that method calls can be chained together. */ Builder notificationDestinations(Collection notificationDestinations); /** *

* The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM roles * and permissions for, to allow Amazon Managed Grafana to use these channels. *

* * @param notificationDestinations * The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM * roles and permissions for, to allow Amazon Managed Grafana to use these channels. * @return Returns a reference to this object so that method calls can be chained together. */ Builder notificationDestinations(NotificationDestinationType... notificationDestinations); /** *

* The name of the IAM role that is used to access resources through Organizations. *

* * @param organizationRoleName * The name of the IAM role that is used to access resources through Organizations. * @return Returns a reference to this object so that method calls can be chained together. */ Builder organizationRoleName(String organizationRoleName); /** *

* Specifies the organizational units that this workspace is allowed to use data sources from, if this workspace * is in an account that is part of an organization. *

* * @param organizationalUnits * Specifies the organizational units that this workspace is allowed to use data sources from, if this * workspace is in an account that is part of an organization. * @return Returns a reference to this object so that method calls can be chained together. */ Builder organizationalUnits(Collection organizationalUnits); /** *

* Specifies the organizational units that this workspace is allowed to use data sources from, if this workspace * is in an account that is part of an organization. *

* * @param organizationalUnits * Specifies the organizational units that this workspace is allowed to use data sources from, if this * workspace is in an account that is part of an organization. * @return Returns a reference to this object so that method calls can be chained together. */ Builder organizationalUnits(String... organizationalUnits); /** *

* If this is Service Managed, Amazon Managed Grafana automatically creates the IAM roles and * provisions the permissions that the workspace needs to use Amazon Web Services data sources and notification * channels. *

*

* If this is CUSTOMER_MANAGED, you manage those roles and permissions yourself. If you are * creating this workspace in a member account of an organization and that account is not a delegated * administrator account, and you want the workspace to access data sources in other Amazon Web Services * accounts in the organization, you must choose CUSTOMER_MANAGED. *

*

* For more information, see Amazon Managed * Grafana permissions and policies for Amazon Web Services data sources and notification channels *

* * @param permissionType * If this is Service Managed, Amazon Managed Grafana automatically creates the IAM roles * and provisions the permissions that the workspace needs to use Amazon Web Services data sources and * notification channels.

*

* If this is CUSTOMER_MANAGED, you manage those roles and permissions yourself. If you are * creating this workspace in a member account of an organization and that account is not a delegated * administrator account, and you want the workspace to access data sources in other Amazon Web Services * accounts in the organization, you must choose CUSTOMER_MANAGED. *

*

* For more information, see Amazon Managed * Grafana permissions and policies for Amazon Web Services data sources and notification channels * @see PermissionType * @return Returns a reference to this object so that method calls can be chained together. * @see PermissionType */ Builder permissionType(String permissionType); /** *

* If this is Service Managed, Amazon Managed Grafana automatically creates the IAM roles and * provisions the permissions that the workspace needs to use Amazon Web Services data sources and notification * channels. *

*

* If this is CUSTOMER_MANAGED, you manage those roles and permissions yourself. If you are * creating this workspace in a member account of an organization and that account is not a delegated * administrator account, and you want the workspace to access data sources in other Amazon Web Services * accounts in the organization, you must choose CUSTOMER_MANAGED. *

*

* For more information, see Amazon Managed * Grafana permissions and policies for Amazon Web Services data sources and notification channels *

* * @param permissionType * If this is Service Managed, Amazon Managed Grafana automatically creates the IAM roles * and provisions the permissions that the workspace needs to use Amazon Web Services data sources and * notification channels.

*

* If this is CUSTOMER_MANAGED, you manage those roles and permissions yourself. If you are * creating this workspace in a member account of an organization and that account is not a delegated * administrator account, and you want the workspace to access data sources in other Amazon Web Services * accounts in the organization, you must choose CUSTOMER_MANAGED. *

*

* For more information, see Amazon Managed * Grafana permissions and policies for Amazon Web Services data sources and notification channels * @see PermissionType * @return Returns a reference to this object so that method calls can be chained together. * @see PermissionType */ Builder permissionType(PermissionType permissionType); /** *

* The name of the CloudFormation stack set that is used to generate IAM roles to be used for this workspace. *

* * @param stackSetName * The name of the CloudFormation stack set that is used to generate IAM roles to be used for this * workspace. * @return Returns a reference to this object so that method calls can be chained together. */ Builder stackSetName(String stackSetName); /** *

* The current status of the workspace. *

* * @param status * The current status of the workspace. * @see WorkspaceStatus * @return Returns a reference to this object so that method calls can be chained together. * @see WorkspaceStatus */ Builder status(String status); /** *

* The current status of the workspace. *

* * @param status * The current status of the workspace. * @see WorkspaceStatus * @return Returns a reference to this object so that method calls can be chained together. * @see WorkspaceStatus */ Builder status(WorkspaceStatus status); /** *

* The IAM role that grants permissions to the Amazon Web Services resources that the workspace will view data * from. This role must already exist. *

* * @param workspaceRoleArn * The IAM role that grants permissions to the Amazon Web Services resources that the workspace will view * data from. This role must already exist. * @return Returns a reference to this object so that method calls can be chained together. */ Builder workspaceRoleArn(String workspaceRoleArn); } static final class BuilderImpl implements Builder { private String accountAccessType; private AuthenticationSummary authentication; private Instant created; private List dataSources = DefaultSdkAutoConstructList.getInstance(); private String description; private String endpoint; private Boolean freeTrialConsumed; private Instant freeTrialExpiration; private String grafanaVersion; private String id; private Instant licenseExpiration; private String licenseType; private Instant modified; private String name; private List notificationDestinations = DefaultSdkAutoConstructList.getInstance(); private String organizationRoleName; private List organizationalUnits = DefaultSdkAutoConstructList.getInstance(); private String permissionType; private String stackSetName; private String status; private String workspaceRoleArn; private BuilderImpl() { } private BuilderImpl(WorkspaceDescription model) { accountAccessType(model.accountAccessType); authentication(model.authentication); created(model.created); dataSourcesWithStrings(model.dataSources); description(model.description); endpoint(model.endpoint); freeTrialConsumed(model.freeTrialConsumed); freeTrialExpiration(model.freeTrialExpiration); grafanaVersion(model.grafanaVersion); id(model.id); licenseExpiration(model.licenseExpiration); licenseType(model.licenseType); modified(model.modified); name(model.name); notificationDestinationsWithStrings(model.notificationDestinations); organizationRoleName(model.organizationRoleName); organizationalUnits(model.organizationalUnits); permissionType(model.permissionType); stackSetName(model.stackSetName); status(model.status); workspaceRoleArn(model.workspaceRoleArn); } public final String getAccountAccessType() { return accountAccessType; } public final void setAccountAccessType(String accountAccessType) { this.accountAccessType = accountAccessType; } @Override @Transient public final Builder accountAccessType(String accountAccessType) { this.accountAccessType = accountAccessType; return this; } @Override @Transient public final Builder accountAccessType(AccountAccessType accountAccessType) { this.accountAccessType(accountAccessType == null ? null : accountAccessType.toString()); return this; } public final AuthenticationSummary.Builder getAuthentication() { return authentication != null ? authentication.toBuilder() : null; } public final void setAuthentication(AuthenticationSummary.BuilderImpl authentication) { this.authentication = authentication != null ? authentication.build() : null; } @Override @Transient public final Builder authentication(AuthenticationSummary authentication) { this.authentication = authentication; return this; } public final Instant getCreated() { return created; } public final void setCreated(Instant created) { this.created = created; } @Override @Transient public final Builder created(Instant created) { this.created = created; return this; } public final Collection getDataSources() { if (dataSources instanceof SdkAutoConstructList) { return null; } return dataSources; } public final void setDataSources(Collection dataSources) { this.dataSources = DataSourceTypesListCopier.copy(dataSources); } @Override @Transient public final Builder dataSourcesWithStrings(Collection dataSources) { this.dataSources = DataSourceTypesListCopier.copy(dataSources); return this; } @Override @Transient @SafeVarargs public final Builder dataSourcesWithStrings(String... dataSources) { dataSourcesWithStrings(Arrays.asList(dataSources)); return this; } @Override @Transient public final Builder dataSources(Collection dataSources) { this.dataSources = DataSourceTypesListCopier.copyEnumToString(dataSources); return this; } @Override @Transient @SafeVarargs public final Builder dataSources(DataSourceType... dataSources) { dataSources(Arrays.asList(dataSources)); return this; } public final String getDescription() { return description; } public final void setDescription(String description) { this.description = description; } @Override @Transient public final Builder description(String description) { this.description = description; return this; } public final String getEndpoint() { return endpoint; } public final void setEndpoint(String endpoint) { this.endpoint = endpoint; } @Override @Transient public final Builder endpoint(String endpoint) { this.endpoint = endpoint; return this; } public final Boolean getFreeTrialConsumed() { return freeTrialConsumed; } public final void setFreeTrialConsumed(Boolean freeTrialConsumed) { this.freeTrialConsumed = freeTrialConsumed; } @Override @Transient public final Builder freeTrialConsumed(Boolean freeTrialConsumed) { this.freeTrialConsumed = freeTrialConsumed; return this; } public final Instant getFreeTrialExpiration() { return freeTrialExpiration; } public final void setFreeTrialExpiration(Instant freeTrialExpiration) { this.freeTrialExpiration = freeTrialExpiration; } @Override @Transient public final Builder freeTrialExpiration(Instant freeTrialExpiration) { this.freeTrialExpiration = freeTrialExpiration; return this; } public final String getGrafanaVersion() { return grafanaVersion; } public final void setGrafanaVersion(String grafanaVersion) { this.grafanaVersion = grafanaVersion; } @Override @Transient public final Builder grafanaVersion(String grafanaVersion) { this.grafanaVersion = grafanaVersion; return this; } public final String getId() { return id; } public final void setId(String id) { this.id = id; } @Override @Transient public final Builder id(String id) { this.id = id; return this; } public final Instant getLicenseExpiration() { return licenseExpiration; } public final void setLicenseExpiration(Instant licenseExpiration) { this.licenseExpiration = licenseExpiration; } @Override @Transient public final Builder licenseExpiration(Instant licenseExpiration) { this.licenseExpiration = licenseExpiration; return this; } public final String getLicenseType() { return licenseType; } public final void setLicenseType(String licenseType) { this.licenseType = licenseType; } @Override @Transient public final Builder licenseType(String licenseType) { this.licenseType = licenseType; return this; } @Override @Transient public final Builder licenseType(LicenseType licenseType) { this.licenseType(licenseType == null ? null : licenseType.toString()); return this; } public final Instant getModified() { return modified; } public final void setModified(Instant modified) { this.modified = modified; } @Override @Transient public final Builder modified(Instant modified) { this.modified = modified; return this; } public final String getName() { return name; } public final void setName(String name) { this.name = name; } @Override @Transient public final Builder name(String name) { this.name = name; return this; } public final Collection getNotificationDestinations() { if (notificationDestinations instanceof SdkAutoConstructList) { return null; } return notificationDestinations; } public final void setNotificationDestinations(Collection notificationDestinations) { this.notificationDestinations = NotificationDestinationsListCopier.copy(notificationDestinations); } @Override @Transient public final Builder notificationDestinationsWithStrings(Collection notificationDestinations) { this.notificationDestinations = NotificationDestinationsListCopier.copy(notificationDestinations); return this; } @Override @Transient @SafeVarargs public final Builder notificationDestinationsWithStrings(String... notificationDestinations) { notificationDestinationsWithStrings(Arrays.asList(notificationDestinations)); return this; } @Override @Transient public final Builder notificationDestinations(Collection notificationDestinations) { this.notificationDestinations = NotificationDestinationsListCopier.copyEnumToString(notificationDestinations); return this; } @Override @Transient @SafeVarargs public final Builder notificationDestinations(NotificationDestinationType... notificationDestinations) { notificationDestinations(Arrays.asList(notificationDestinations)); return this; } public final String getOrganizationRoleName() { return organizationRoleName; } public final void setOrganizationRoleName(String organizationRoleName) { this.organizationRoleName = organizationRoleName; } @Override @Transient public final Builder organizationRoleName(String organizationRoleName) { this.organizationRoleName = organizationRoleName; return this; } public final Collection getOrganizationalUnits() { if (organizationalUnits instanceof SdkAutoConstructList) { return null; } return organizationalUnits; } public final void setOrganizationalUnits(Collection organizationalUnits) { this.organizationalUnits = OrganizationalUnitListCopier.copy(organizationalUnits); } @Override @Transient public final Builder organizationalUnits(Collection organizationalUnits) { this.organizationalUnits = OrganizationalUnitListCopier.copy(organizationalUnits); return this; } @Override @Transient @SafeVarargs public final Builder organizationalUnits(String... organizationalUnits) { organizationalUnits(Arrays.asList(organizationalUnits)); return this; } public final String getPermissionType() { return permissionType; } public final void setPermissionType(String permissionType) { this.permissionType = permissionType; } @Override @Transient public final Builder permissionType(String permissionType) { this.permissionType = permissionType; return this; } @Override @Transient public final Builder permissionType(PermissionType permissionType) { this.permissionType(permissionType == null ? null : permissionType.toString()); return this; } public final String getStackSetName() { return stackSetName; } public final void setStackSetName(String stackSetName) { this.stackSetName = stackSetName; } @Override @Transient public final Builder stackSetName(String stackSetName) { this.stackSetName = stackSetName; return this; } public final String getStatus() { return status; } public final void setStatus(String status) { this.status = status; } @Override @Transient public final Builder status(String status) { this.status = status; return this; } @Override @Transient public final Builder status(WorkspaceStatus status) { this.status(status == null ? null : status.toString()); return this; } public final String getWorkspaceRoleArn() { return workspaceRoleArn; } public final void setWorkspaceRoleArn(String workspaceRoleArn) { this.workspaceRoleArn = workspaceRoleArn; } @Override @Transient public final Builder workspaceRoleArn(String workspaceRoleArn) { this.workspaceRoleArn = workspaceRoleArn; return this; } @Override public WorkspaceDescription build() { return new WorkspaceDescription(this); } @Override public List> sdkFields() { return SDK_FIELDS; } } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy