aws.sdk.kotlin.services.configservice.paginators.Paginators.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.configservice.paginators
import aws.sdk.kotlin.services.configservice.ConfigClient
import aws.sdk.kotlin.services.configservice.model.AggregateComplianceByConformancePack
import aws.sdk.kotlin.services.configservice.model.AggregateEvaluationResult
import aws.sdk.kotlin.services.configservice.model.AggregateResourceIdentifier
import aws.sdk.kotlin.services.configservice.model.AggregatedSourceStatus
import aws.sdk.kotlin.services.configservice.model.AggregationAuthorization
import aws.sdk.kotlin.services.configservice.model.ComplianceByConfigRule
import aws.sdk.kotlin.services.configservice.model.ComplianceByResource
import aws.sdk.kotlin.services.configservice.model.ConfigRule
import aws.sdk.kotlin.services.configservice.model.ConfigRuleEvaluationStatus
import aws.sdk.kotlin.services.configservice.model.ConfigurationAggregator
import aws.sdk.kotlin.services.configservice.model.ConfigurationItem
import aws.sdk.kotlin.services.configservice.model.ConformancePackComplianceSummary
import aws.sdk.kotlin.services.configservice.model.ConformancePackDetail
import aws.sdk.kotlin.services.configservice.model.ConformancePackStatusDetail
import aws.sdk.kotlin.services.configservice.model.DescribeAggregateComplianceByConfigRulesRequest
import aws.sdk.kotlin.services.configservice.model.DescribeAggregateComplianceByConfigRulesResponse
import aws.sdk.kotlin.services.configservice.model.DescribeAggregateComplianceByConformancePacksRequest
import aws.sdk.kotlin.services.configservice.model.DescribeAggregateComplianceByConformancePacksResponse
import aws.sdk.kotlin.services.configservice.model.DescribeAggregationAuthorizationsRequest
import aws.sdk.kotlin.services.configservice.model.DescribeAggregationAuthorizationsResponse
import aws.sdk.kotlin.services.configservice.model.DescribeComplianceByConfigRuleRequest
import aws.sdk.kotlin.services.configservice.model.DescribeComplianceByConfigRuleResponse
import aws.sdk.kotlin.services.configservice.model.DescribeComplianceByResourceRequest
import aws.sdk.kotlin.services.configservice.model.DescribeComplianceByResourceResponse
import aws.sdk.kotlin.services.configservice.model.DescribeConfigRuleEvaluationStatusRequest
import aws.sdk.kotlin.services.configservice.model.DescribeConfigRuleEvaluationStatusResponse
import aws.sdk.kotlin.services.configservice.model.DescribeConfigRulesRequest
import aws.sdk.kotlin.services.configservice.model.DescribeConfigRulesResponse
import aws.sdk.kotlin.services.configservice.model.DescribeConfigurationAggregatorSourcesStatusRequest
import aws.sdk.kotlin.services.configservice.model.DescribeConfigurationAggregatorSourcesStatusResponse
import aws.sdk.kotlin.services.configservice.model.DescribeConfigurationAggregatorsRequest
import aws.sdk.kotlin.services.configservice.model.DescribeConfigurationAggregatorsResponse
import aws.sdk.kotlin.services.configservice.model.DescribeConformancePackComplianceRequest
import aws.sdk.kotlin.services.configservice.model.DescribeConformancePackComplianceResponse
import aws.sdk.kotlin.services.configservice.model.DescribeConformancePackStatusRequest
import aws.sdk.kotlin.services.configservice.model.DescribeConformancePackStatusResponse
import aws.sdk.kotlin.services.configservice.model.DescribeConformancePacksRequest
import aws.sdk.kotlin.services.configservice.model.DescribeConformancePacksResponse
import aws.sdk.kotlin.services.configservice.model.DescribeOrganizationConfigRuleStatusesRequest
import aws.sdk.kotlin.services.configservice.model.DescribeOrganizationConfigRuleStatusesResponse
import aws.sdk.kotlin.services.configservice.model.DescribeOrganizationConfigRulesRequest
import aws.sdk.kotlin.services.configservice.model.DescribeOrganizationConfigRulesResponse
import aws.sdk.kotlin.services.configservice.model.DescribeOrganizationConformancePackStatusesRequest
import aws.sdk.kotlin.services.configservice.model.DescribeOrganizationConformancePackStatusesResponse
import aws.sdk.kotlin.services.configservice.model.DescribeOrganizationConformancePacksRequest
import aws.sdk.kotlin.services.configservice.model.DescribeOrganizationConformancePacksResponse
import aws.sdk.kotlin.services.configservice.model.DescribePendingAggregationRequestsRequest
import aws.sdk.kotlin.services.configservice.model.DescribePendingAggregationRequestsResponse
import aws.sdk.kotlin.services.configservice.model.DescribeRemediationExceptionsRequest
import aws.sdk.kotlin.services.configservice.model.DescribeRemediationExceptionsResponse
import aws.sdk.kotlin.services.configservice.model.DescribeRemediationExecutionStatusRequest
import aws.sdk.kotlin.services.configservice.model.DescribeRemediationExecutionStatusResponse
import aws.sdk.kotlin.services.configservice.model.DescribeRetentionConfigurationsRequest
import aws.sdk.kotlin.services.configservice.model.DescribeRetentionConfigurationsResponse
import aws.sdk.kotlin.services.configservice.model.EvaluationResult
import aws.sdk.kotlin.services.configservice.model.GetAggregateComplianceDetailsByConfigRuleRequest
import aws.sdk.kotlin.services.configservice.model.GetAggregateComplianceDetailsByConfigRuleResponse
import aws.sdk.kotlin.services.configservice.model.GetAggregateConfigRuleComplianceSummaryRequest
import aws.sdk.kotlin.services.configservice.model.GetAggregateConfigRuleComplianceSummaryResponse
import aws.sdk.kotlin.services.configservice.model.GetAggregateConformancePackComplianceSummaryRequest
import aws.sdk.kotlin.services.configservice.model.GetAggregateConformancePackComplianceSummaryResponse
import aws.sdk.kotlin.services.configservice.model.GetAggregateDiscoveredResourceCountsRequest
import aws.sdk.kotlin.services.configservice.model.GetAggregateDiscoveredResourceCountsResponse
import aws.sdk.kotlin.services.configservice.model.GetComplianceDetailsByConfigRuleRequest
import aws.sdk.kotlin.services.configservice.model.GetComplianceDetailsByConfigRuleResponse
import aws.sdk.kotlin.services.configservice.model.GetComplianceDetailsByResourceRequest
import aws.sdk.kotlin.services.configservice.model.GetComplianceDetailsByResourceResponse
import aws.sdk.kotlin.services.configservice.model.GetConformancePackComplianceDetailsRequest
import aws.sdk.kotlin.services.configservice.model.GetConformancePackComplianceDetailsResponse
import aws.sdk.kotlin.services.configservice.model.GetConformancePackComplianceSummaryRequest
import aws.sdk.kotlin.services.configservice.model.GetConformancePackComplianceSummaryResponse
import aws.sdk.kotlin.services.configservice.model.GetDiscoveredResourceCountsRequest
import aws.sdk.kotlin.services.configservice.model.GetDiscoveredResourceCountsResponse
import aws.sdk.kotlin.services.configservice.model.GetOrganizationConfigRuleDetailedStatusRequest
import aws.sdk.kotlin.services.configservice.model.GetOrganizationConfigRuleDetailedStatusResponse
import aws.sdk.kotlin.services.configservice.model.GetOrganizationConformancePackDetailedStatusRequest
import aws.sdk.kotlin.services.configservice.model.GetOrganizationConformancePackDetailedStatusResponse
import aws.sdk.kotlin.services.configservice.model.GetResourceConfigHistoryRequest
import aws.sdk.kotlin.services.configservice.model.GetResourceConfigHistoryResponse
import aws.sdk.kotlin.services.configservice.model.ListAggregateDiscoveredResourcesRequest
import aws.sdk.kotlin.services.configservice.model.ListAggregateDiscoveredResourcesResponse
import aws.sdk.kotlin.services.configservice.model.ListDiscoveredResourcesRequest
import aws.sdk.kotlin.services.configservice.model.ListDiscoveredResourcesResponse
import aws.sdk.kotlin.services.configservice.model.ListStoredQueriesRequest
import aws.sdk.kotlin.services.configservice.model.ListStoredQueriesResponse
import aws.sdk.kotlin.services.configservice.model.ListTagsForResourceRequest
import aws.sdk.kotlin.services.configservice.model.ListTagsForResourceResponse
import aws.sdk.kotlin.services.configservice.model.MemberAccountStatus
import aws.sdk.kotlin.services.configservice.model.OrganizationConfigRule
import aws.sdk.kotlin.services.configservice.model.OrganizationConfigRuleStatus
import aws.sdk.kotlin.services.configservice.model.OrganizationConformancePack
import aws.sdk.kotlin.services.configservice.model.OrganizationConformancePackDetailedStatus
import aws.sdk.kotlin.services.configservice.model.OrganizationConformancePackStatus
import aws.sdk.kotlin.services.configservice.model.PendingAggregationRequest
import aws.sdk.kotlin.services.configservice.model.RemediationExecutionStatus
import aws.sdk.kotlin.services.configservice.model.ResourceIdentifier
import aws.sdk.kotlin.services.configservice.model.RetentionConfiguration
import aws.sdk.kotlin.services.configservice.model.SelectAggregateResourceConfigRequest
import aws.sdk.kotlin.services.configservice.model.SelectAggregateResourceConfigResponse
import aws.sdk.kotlin.services.configservice.model.SelectResourceConfigRequest
import aws.sdk.kotlin.services.configservice.model.SelectResourceConfigResponse
import aws.sdk.kotlin.services.configservice.model.Tag
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.flow
import kotlinx.coroutines.flow.transform
/**
* Paginate over [DescribeAggregateComplianceByConfigRulesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeAggregateComplianceByConfigRulesRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeAggregateComplianceByConfigRulesResponse]
*/
fun ConfigClient.describeAggregateComplianceByConfigRulesPaginated(initialRequest: DescribeAggregateComplianceByConfigRulesRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeAggregateComplianceByConfigRulesPaginated.describeAggregateComplianceByConfigRules(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeAggregateComplianceByConfigRulesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeAggregateComplianceByConfigRulesResponse]
*/
fun ConfigClient.describeAggregateComplianceByConfigRulesPaginated(block: DescribeAggregateComplianceByConfigRulesRequest.Builder.() -> Unit): Flow =
describeAggregateComplianceByConfigRulesPaginated(DescribeAggregateComplianceByConfigRulesRequest.Builder().apply(block).build())
/**
* Paginate over [DescribeAggregateComplianceByConformancePacksResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeAggregateComplianceByConformancePacksRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeAggregateComplianceByConformancePacksResponse]
*/
fun ConfigClient.describeAggregateComplianceByConformancePacksPaginated(initialRequest: DescribeAggregateComplianceByConformancePacksRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeAggregateComplianceByConformancePacksPaginated.describeAggregateComplianceByConformancePacks(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeAggregateComplianceByConformancePacksResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeAggregateComplianceByConformancePacksResponse]
*/
fun ConfigClient.describeAggregateComplianceByConformancePacksPaginated(block: DescribeAggregateComplianceByConformancePacksRequest.Builder.() -> Unit): Flow =
describeAggregateComplianceByConformancePacksPaginated(DescribeAggregateComplianceByConformancePacksRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeAggregateComplianceByConformancePacksPaginated]
* to access the nested member [AggregateComplianceByConformancePack]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [AggregateComplianceByConformancePack]
*/
@JvmName("describeAggregateComplianceByConformancePacksResponseAggregateComplianceByConformancePack")
fun Flow.aggregateComplianceByConformancePacks(): Flow =
transform() { response ->
response.aggregateComplianceByConformancePacks?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeAggregationAuthorizationsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeAggregationAuthorizationsRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeAggregationAuthorizationsResponse]
*/
fun ConfigClient.describeAggregationAuthorizationsPaginated(initialRequest: DescribeAggregationAuthorizationsRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeAggregationAuthorizationsPaginated.describeAggregationAuthorizations(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeAggregationAuthorizationsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeAggregationAuthorizationsResponse]
*/
fun ConfigClient.describeAggregationAuthorizationsPaginated(block: DescribeAggregationAuthorizationsRequest.Builder.() -> Unit): Flow =
describeAggregationAuthorizationsPaginated(DescribeAggregationAuthorizationsRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeAggregationAuthorizationsPaginated]
* to access the nested member [AggregationAuthorization]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [AggregationAuthorization]
*/
@JvmName("describeAggregationAuthorizationsResponseAggregationAuthorization")
fun Flow.aggregationAuthorizations(): Flow =
transform() { response ->
response.aggregationAuthorizations?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeComplianceByConfigRuleResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeComplianceByConfigRuleRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeComplianceByConfigRuleResponse]
*/
fun ConfigClient.describeComplianceByConfigRulePaginated(initialRequest: DescribeComplianceByConfigRuleRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeComplianceByConfigRulePaginated.describeComplianceByConfigRule(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeComplianceByConfigRuleResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeComplianceByConfigRuleResponse]
*/
fun ConfigClient.describeComplianceByConfigRulePaginated(block: DescribeComplianceByConfigRuleRequest.Builder.() -> Unit): Flow =
describeComplianceByConfigRulePaginated(DescribeComplianceByConfigRuleRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeComplianceByConfigRulePaginated]
* to access the nested member [ComplianceByConfigRule]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ComplianceByConfigRule]
*/
@JvmName("describeComplianceByConfigRuleResponseComplianceByConfigRule")
fun Flow.complianceByConfigRules(): Flow =
transform() { response ->
response.complianceByConfigRules?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeComplianceByResourceResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeComplianceByResourceRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeComplianceByResourceResponse]
*/
fun ConfigClient.describeComplianceByResourcePaginated(initialRequest: DescribeComplianceByResourceRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeComplianceByResourcePaginated.describeComplianceByResource(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeComplianceByResourceResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeComplianceByResourceResponse]
*/
fun ConfigClient.describeComplianceByResourcePaginated(block: DescribeComplianceByResourceRequest.Builder.() -> Unit): Flow =
describeComplianceByResourcePaginated(DescribeComplianceByResourceRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeComplianceByResourcePaginated]
* to access the nested member [ComplianceByResource]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ComplianceByResource]
*/
@JvmName("describeComplianceByResourceResponseComplianceByResource")
fun Flow.complianceByResources(): Flow =
transform() { response ->
response.complianceByResources?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeConfigRuleEvaluationStatusResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeConfigRuleEvaluationStatusRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConfigRuleEvaluationStatusResponse]
*/
fun ConfigClient.describeConfigRuleEvaluationStatusPaginated(initialRequest: DescribeConfigRuleEvaluationStatusRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeConfigRuleEvaluationStatusPaginated.describeConfigRuleEvaluationStatus(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeConfigRuleEvaluationStatusResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConfigRuleEvaluationStatusResponse]
*/
fun ConfigClient.describeConfigRuleEvaluationStatusPaginated(block: DescribeConfigRuleEvaluationStatusRequest.Builder.() -> Unit): Flow =
describeConfigRuleEvaluationStatusPaginated(DescribeConfigRuleEvaluationStatusRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeConfigRuleEvaluationStatusPaginated]
* to access the nested member [ConfigRuleEvaluationStatus]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ConfigRuleEvaluationStatus]
*/
@JvmName("describeConfigRuleEvaluationStatusResponseConfigRuleEvaluationStatus")
fun Flow.configRulesEvaluationStatus(): Flow =
transform() { response ->
response.configRulesEvaluationStatus?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeConfigRulesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeConfigRulesRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConfigRulesResponse]
*/
fun ConfigClient.describeConfigRulesPaginated(initialRequest: DescribeConfigRulesRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = [email protected](req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeConfigRulesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConfigRulesResponse]
*/
fun ConfigClient.describeConfigRulesPaginated(block: DescribeConfigRulesRequest.Builder.() -> Unit): Flow =
describeConfigRulesPaginated(DescribeConfigRulesRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeConfigRulesPaginated]
* to access the nested member [ConfigRule]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ConfigRule]
*/
@JvmName("describeConfigRulesResponseConfigRule")
fun Flow.configRules(): Flow =
transform() { response ->
response.configRules?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeConfigurationAggregatorsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeConfigurationAggregatorsRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConfigurationAggregatorsResponse]
*/
fun ConfigClient.describeConfigurationAggregatorsPaginated(initialRequest: DescribeConfigurationAggregatorsRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeConfigurationAggregatorsPaginated.describeConfigurationAggregators(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeConfigurationAggregatorsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConfigurationAggregatorsResponse]
*/
fun ConfigClient.describeConfigurationAggregatorsPaginated(block: DescribeConfigurationAggregatorsRequest.Builder.() -> Unit): Flow =
describeConfigurationAggregatorsPaginated(DescribeConfigurationAggregatorsRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeConfigurationAggregatorsPaginated]
* to access the nested member [ConfigurationAggregator]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ConfigurationAggregator]
*/
@JvmName("describeConfigurationAggregatorsResponseConfigurationAggregator")
fun Flow.configurationAggregators(): Flow =
transform() { response ->
response.configurationAggregators?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeConfigurationAggregatorSourcesStatusResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeConfigurationAggregatorSourcesStatusRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConfigurationAggregatorSourcesStatusResponse]
*/
fun ConfigClient.describeConfigurationAggregatorSourcesStatusPaginated(initialRequest: DescribeConfigurationAggregatorSourcesStatusRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeConfigurationAggregatorSourcesStatusPaginated.describeConfigurationAggregatorSourcesStatus(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeConfigurationAggregatorSourcesStatusResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConfigurationAggregatorSourcesStatusResponse]
*/
fun ConfigClient.describeConfigurationAggregatorSourcesStatusPaginated(block: DescribeConfigurationAggregatorSourcesStatusRequest.Builder.() -> Unit): Flow =
describeConfigurationAggregatorSourcesStatusPaginated(DescribeConfigurationAggregatorSourcesStatusRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeConfigurationAggregatorSourcesStatusPaginated]
* to access the nested member [AggregatedSourceStatus]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [AggregatedSourceStatus]
*/
@JvmName("describeConfigurationAggregatorSourcesStatusResponseAggregatedSourceStatus")
fun Flow.aggregatedSourceStatusList(): Flow =
transform() { response ->
response.aggregatedSourceStatusList?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeConformancePackComplianceResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeConformancePackComplianceRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConformancePackComplianceResponse]
*/
fun ConfigClient.describeConformancePackCompliancePaginated(initialRequest: DescribeConformancePackComplianceRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeConformancePackCompliancePaginated.describeConformancePackCompliance(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeConformancePackComplianceResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConformancePackComplianceResponse]
*/
fun ConfigClient.describeConformancePackCompliancePaginated(block: DescribeConformancePackComplianceRequest.Builder.() -> Unit): Flow =
describeConformancePackCompliancePaginated(DescribeConformancePackComplianceRequest.Builder().apply(block).build())
/**
* Paginate over [DescribeConformancePacksResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeConformancePacksRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConformancePacksResponse]
*/
fun ConfigClient.describeConformancePacksPaginated(initialRequest: DescribeConformancePacksRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = [email protected](req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeConformancePacksResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConformancePacksResponse]
*/
fun ConfigClient.describeConformancePacksPaginated(block: DescribeConformancePacksRequest.Builder.() -> Unit): Flow =
describeConformancePacksPaginated(DescribeConformancePacksRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeConformancePacksPaginated]
* to access the nested member [ConformancePackDetail]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ConformancePackDetail]
*/
@JvmName("describeConformancePacksResponseConformancePackDetail")
fun Flow.conformancePackDetails(): Flow =
transform() { response ->
response.conformancePackDetails?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeConformancePackStatusResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeConformancePackStatusRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConformancePackStatusResponse]
*/
fun ConfigClient.describeConformancePackStatusPaginated(initialRequest: DescribeConformancePackStatusRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeConformancePackStatusPaginated.describeConformancePackStatus(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeConformancePackStatusResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeConformancePackStatusResponse]
*/
fun ConfigClient.describeConformancePackStatusPaginated(block: DescribeConformancePackStatusRequest.Builder.() -> Unit): Flow =
describeConformancePackStatusPaginated(DescribeConformancePackStatusRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeConformancePackStatusPaginated]
* to access the nested member [ConformancePackStatusDetail]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ConformancePackStatusDetail]
*/
@JvmName("describeConformancePackStatusResponseConformancePackStatusDetail")
fun Flow.conformancePackStatusDetails(): Flow =
transform() { response ->
response.conformancePackStatusDetails?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeOrganizationConfigRulesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeOrganizationConfigRulesRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeOrganizationConfigRulesResponse]
*/
fun ConfigClient.describeOrganizationConfigRulesPaginated(initialRequest: DescribeOrganizationConfigRulesRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeOrganizationConfigRulesPaginated.describeOrganizationConfigRules(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeOrganizationConfigRulesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeOrganizationConfigRulesResponse]
*/
fun ConfigClient.describeOrganizationConfigRulesPaginated(block: DescribeOrganizationConfigRulesRequest.Builder.() -> Unit): Flow =
describeOrganizationConfigRulesPaginated(DescribeOrganizationConfigRulesRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeOrganizationConfigRulesPaginated]
* to access the nested member [OrganizationConfigRule]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [OrganizationConfigRule]
*/
@JvmName("describeOrganizationConfigRulesResponseOrganizationConfigRule")
fun Flow.organizationConfigRules(): Flow =
transform() { response ->
response.organizationConfigRules?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeOrganizationConfigRuleStatusesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeOrganizationConfigRuleStatusesRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeOrganizationConfigRuleStatusesResponse]
*/
fun ConfigClient.describeOrganizationConfigRuleStatusesPaginated(initialRequest: DescribeOrganizationConfigRuleStatusesRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeOrganizationConfigRuleStatusesPaginated.describeOrganizationConfigRuleStatuses(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeOrganizationConfigRuleStatusesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeOrganizationConfigRuleStatusesResponse]
*/
fun ConfigClient.describeOrganizationConfigRuleStatusesPaginated(block: DescribeOrganizationConfigRuleStatusesRequest.Builder.() -> Unit): Flow =
describeOrganizationConfigRuleStatusesPaginated(DescribeOrganizationConfigRuleStatusesRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeOrganizationConfigRuleStatusesPaginated]
* to access the nested member [OrganizationConfigRuleStatus]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [OrganizationConfigRuleStatus]
*/
@JvmName("describeOrganizationConfigRuleStatusesResponseOrganizationConfigRuleStatus")
fun Flow.organizationConfigRuleStatuses(): Flow =
transform() { response ->
response.organizationConfigRuleStatuses?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeOrganizationConformancePacksResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeOrganizationConformancePacksRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeOrganizationConformancePacksResponse]
*/
fun ConfigClient.describeOrganizationConformancePacksPaginated(initialRequest: DescribeOrganizationConformancePacksRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeOrganizationConformancePacksPaginated.describeOrganizationConformancePacks(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeOrganizationConformancePacksResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeOrganizationConformancePacksResponse]
*/
fun ConfigClient.describeOrganizationConformancePacksPaginated(block: DescribeOrganizationConformancePacksRequest.Builder.() -> Unit): Flow =
describeOrganizationConformancePacksPaginated(DescribeOrganizationConformancePacksRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeOrganizationConformancePacksPaginated]
* to access the nested member [OrganizationConformancePack]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [OrganizationConformancePack]
*/
@JvmName("describeOrganizationConformancePacksResponseOrganizationConformancePack")
fun Flow.organizationConformancePacks(): Flow =
transform() { response ->
response.organizationConformancePacks?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeOrganizationConformancePackStatusesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeOrganizationConformancePackStatusesRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeOrganizationConformancePackStatusesResponse]
*/
fun ConfigClient.describeOrganizationConformancePackStatusesPaginated(initialRequest: DescribeOrganizationConformancePackStatusesRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeOrganizationConformancePackStatusesPaginated.describeOrganizationConformancePackStatuses(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeOrganizationConformancePackStatusesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeOrganizationConformancePackStatusesResponse]
*/
fun ConfigClient.describeOrganizationConformancePackStatusesPaginated(block: DescribeOrganizationConformancePackStatusesRequest.Builder.() -> Unit): Flow =
describeOrganizationConformancePackStatusesPaginated(DescribeOrganizationConformancePackStatusesRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeOrganizationConformancePackStatusesPaginated]
* to access the nested member [OrganizationConformancePackStatus]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [OrganizationConformancePackStatus]
*/
@JvmName("describeOrganizationConformancePackStatusesResponseOrganizationConformancePackStatus")
fun Flow.organizationConformancePackStatuses(): Flow =
transform() { response ->
response.organizationConformancePackStatuses?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribePendingAggregationRequestsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribePendingAggregationRequestsRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribePendingAggregationRequestsResponse]
*/
fun ConfigClient.describePendingAggregationRequestsPaginated(initialRequest: DescribePendingAggregationRequestsRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describePendingAggregationRequestsPaginated.describePendingAggregationRequests(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribePendingAggregationRequestsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribePendingAggregationRequestsResponse]
*/
fun ConfigClient.describePendingAggregationRequestsPaginated(block: DescribePendingAggregationRequestsRequest.Builder.() -> Unit): Flow =
describePendingAggregationRequestsPaginated(DescribePendingAggregationRequestsRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describePendingAggregationRequestsPaginated]
* to access the nested member [PendingAggregationRequest]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [PendingAggregationRequest]
*/
@JvmName("describePendingAggregationRequestsResponsePendingAggregationRequest")
fun Flow.pendingAggregationRequests(): Flow =
transform() { response ->
response.pendingAggregationRequests?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeRemediationExceptionsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeRemediationExceptionsRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeRemediationExceptionsResponse]
*/
fun ConfigClient.describeRemediationExceptionsPaginated(initialRequest: DescribeRemediationExceptionsRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeRemediationExceptionsPaginated.describeRemediationExceptions(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeRemediationExceptionsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeRemediationExceptionsResponse]
*/
fun ConfigClient.describeRemediationExceptionsPaginated(block: DescribeRemediationExceptionsRequest.Builder.() -> Unit): Flow =
describeRemediationExceptionsPaginated(DescribeRemediationExceptionsRequest.Builder().apply(block).build())
/**
* Paginate over [DescribeRemediationExecutionStatusResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeRemediationExecutionStatusRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeRemediationExecutionStatusResponse]
*/
fun ConfigClient.describeRemediationExecutionStatusPaginated(initialRequest: DescribeRemediationExecutionStatusRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeRemediationExecutionStatusPaginated.describeRemediationExecutionStatus(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeRemediationExecutionStatusResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeRemediationExecutionStatusResponse]
*/
fun ConfigClient.describeRemediationExecutionStatusPaginated(block: DescribeRemediationExecutionStatusRequest.Builder.() -> Unit): Flow =
describeRemediationExecutionStatusPaginated(DescribeRemediationExecutionStatusRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeRemediationExecutionStatusPaginated]
* to access the nested member [RemediationExecutionStatus]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [RemediationExecutionStatus]
*/
@JvmName("describeRemediationExecutionStatusResponseRemediationExecutionStatus")
fun Flow.remediationExecutionStatuses(): Flow =
transform() { response ->
response.remediationExecutionStatuses?.forEach {
emit(it)
}
}
/**
* Paginate over [DescribeRetentionConfigurationsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [DescribeRetentionConfigurationsRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeRetentionConfigurationsResponse]
*/
fun ConfigClient.describeRetentionConfigurationsPaginated(initialRequest: DescribeRetentionConfigurationsRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@describeRetentionConfigurationsPaginated.describeRetentionConfigurations(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [DescribeRetentionConfigurationsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [DescribeRetentionConfigurationsResponse]
*/
fun ConfigClient.describeRetentionConfigurationsPaginated(block: DescribeRetentionConfigurationsRequest.Builder.() -> Unit): Flow =
describeRetentionConfigurationsPaginated(DescribeRetentionConfigurationsRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [describeRetentionConfigurationsPaginated]
* to access the nested member [RetentionConfiguration]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [RetentionConfiguration]
*/
@JvmName("describeRetentionConfigurationsResponseRetentionConfiguration")
fun Flow.retentionConfigurations(): Flow =
transform() { response ->
response.retentionConfigurations?.forEach {
emit(it)
}
}
/**
* Paginate over [GetAggregateComplianceDetailsByConfigRuleResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [GetAggregateComplianceDetailsByConfigRuleRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetAggregateComplianceDetailsByConfigRuleResponse]
*/
fun ConfigClient.getAggregateComplianceDetailsByConfigRulePaginated(initialRequest: GetAggregateComplianceDetailsByConfigRuleRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@getAggregateComplianceDetailsByConfigRulePaginated.getAggregateComplianceDetailsByConfigRule(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [GetAggregateComplianceDetailsByConfigRuleResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetAggregateComplianceDetailsByConfigRuleResponse]
*/
fun ConfigClient.getAggregateComplianceDetailsByConfigRulePaginated(block: GetAggregateComplianceDetailsByConfigRuleRequest.Builder.() -> Unit): Flow =
getAggregateComplianceDetailsByConfigRulePaginated(GetAggregateComplianceDetailsByConfigRuleRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [getAggregateComplianceDetailsByConfigRulePaginated]
* to access the nested member [AggregateEvaluationResult]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [AggregateEvaluationResult]
*/
@JvmName("getAggregateComplianceDetailsByConfigRuleResponseAggregateEvaluationResult")
fun Flow.aggregateEvaluationResults(): Flow =
transform() { response ->
response.aggregateEvaluationResults?.forEach {
emit(it)
}
}
/**
* Paginate over [GetAggregateConfigRuleComplianceSummaryResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [GetAggregateConfigRuleComplianceSummaryRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetAggregateConfigRuleComplianceSummaryResponse]
*/
fun ConfigClient.getAggregateConfigRuleComplianceSummaryPaginated(initialRequest: GetAggregateConfigRuleComplianceSummaryRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@getAggregateConfigRuleComplianceSummaryPaginated.getAggregateConfigRuleComplianceSummary(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [GetAggregateConfigRuleComplianceSummaryResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetAggregateConfigRuleComplianceSummaryResponse]
*/
fun ConfigClient.getAggregateConfigRuleComplianceSummaryPaginated(block: GetAggregateConfigRuleComplianceSummaryRequest.Builder.() -> Unit): Flow =
getAggregateConfigRuleComplianceSummaryPaginated(GetAggregateConfigRuleComplianceSummaryRequest.Builder().apply(block).build())
/**
* Paginate over [GetAggregateConformancePackComplianceSummaryResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [GetAggregateConformancePackComplianceSummaryRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetAggregateConformancePackComplianceSummaryResponse]
*/
fun ConfigClient.getAggregateConformancePackComplianceSummaryPaginated(initialRequest: GetAggregateConformancePackComplianceSummaryRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@getAggregateConformancePackComplianceSummaryPaginated.getAggregateConformancePackComplianceSummary(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [GetAggregateConformancePackComplianceSummaryResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetAggregateConformancePackComplianceSummaryResponse]
*/
fun ConfigClient.getAggregateConformancePackComplianceSummaryPaginated(block: GetAggregateConformancePackComplianceSummaryRequest.Builder.() -> Unit): Flow =
getAggregateConformancePackComplianceSummaryPaginated(GetAggregateConformancePackComplianceSummaryRequest.Builder().apply(block).build())
/**
* Paginate over [GetAggregateDiscoveredResourceCountsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [GetAggregateDiscoveredResourceCountsRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetAggregateDiscoveredResourceCountsResponse]
*/
fun ConfigClient.getAggregateDiscoveredResourceCountsPaginated(initialRequest: GetAggregateDiscoveredResourceCountsRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@getAggregateDiscoveredResourceCountsPaginated.getAggregateDiscoveredResourceCounts(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [GetAggregateDiscoveredResourceCountsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetAggregateDiscoveredResourceCountsResponse]
*/
fun ConfigClient.getAggregateDiscoveredResourceCountsPaginated(block: GetAggregateDiscoveredResourceCountsRequest.Builder.() -> Unit): Flow =
getAggregateDiscoveredResourceCountsPaginated(GetAggregateDiscoveredResourceCountsRequest.Builder().apply(block).build())
/**
* Paginate over [GetComplianceDetailsByConfigRuleResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [GetComplianceDetailsByConfigRuleRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetComplianceDetailsByConfigRuleResponse]
*/
fun ConfigClient.getComplianceDetailsByConfigRulePaginated(initialRequest: GetComplianceDetailsByConfigRuleRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@getComplianceDetailsByConfigRulePaginated.getComplianceDetailsByConfigRule(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [GetComplianceDetailsByConfigRuleResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetComplianceDetailsByConfigRuleResponse]
*/
fun ConfigClient.getComplianceDetailsByConfigRulePaginated(block: GetComplianceDetailsByConfigRuleRequest.Builder.() -> Unit): Flow =
getComplianceDetailsByConfigRulePaginated(GetComplianceDetailsByConfigRuleRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [getComplianceDetailsByConfigRulePaginated]
* to access the nested member [EvaluationResult]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [EvaluationResult]
*/
@JvmName("getComplianceDetailsByConfigRuleResponseEvaluationResult")
fun Flow.evaluationResults(): Flow =
transform() { response ->
response.evaluationResults?.forEach {
emit(it)
}
}
/**
* Paginate over [GetComplianceDetailsByResourceResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [GetComplianceDetailsByResourceRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetComplianceDetailsByResourceResponse]
*/
fun ConfigClient.getComplianceDetailsByResourcePaginated(initialRequest: GetComplianceDetailsByResourceRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@getComplianceDetailsByResourcePaginated.getComplianceDetailsByResource(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [GetComplianceDetailsByResourceResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetComplianceDetailsByResourceResponse]
*/
fun ConfigClient.getComplianceDetailsByResourcePaginated(block: GetComplianceDetailsByResourceRequest.Builder.() -> Unit): Flow =
getComplianceDetailsByResourcePaginated(GetComplianceDetailsByResourceRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [getComplianceDetailsByResourcePaginated]
* to access the nested member [EvaluationResult]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [EvaluationResult]
*/
@JvmName("getComplianceDetailsByResourceResponseEvaluationResult")
fun Flow.evaluationResults(): Flow =
transform() { response ->
response.evaluationResults?.forEach {
emit(it)
}
}
/**
* Paginate over [GetConformancePackComplianceDetailsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [GetConformancePackComplianceDetailsRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetConformancePackComplianceDetailsResponse]
*/
fun ConfigClient.getConformancePackComplianceDetailsPaginated(initialRequest: GetConformancePackComplianceDetailsRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@getConformancePackComplianceDetailsPaginated.getConformancePackComplianceDetails(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [GetConformancePackComplianceDetailsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetConformancePackComplianceDetailsResponse]
*/
fun ConfigClient.getConformancePackComplianceDetailsPaginated(block: GetConformancePackComplianceDetailsRequest.Builder.() -> Unit): Flow =
getConformancePackComplianceDetailsPaginated(GetConformancePackComplianceDetailsRequest.Builder().apply(block).build())
/**
* Paginate over [GetConformancePackComplianceSummaryResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [GetConformancePackComplianceSummaryRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetConformancePackComplianceSummaryResponse]
*/
fun ConfigClient.getConformancePackComplianceSummaryPaginated(initialRequest: GetConformancePackComplianceSummaryRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@getConformancePackComplianceSummaryPaginated.getConformancePackComplianceSummary(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [GetConformancePackComplianceSummaryResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetConformancePackComplianceSummaryResponse]
*/
fun ConfigClient.getConformancePackComplianceSummaryPaginated(block: GetConformancePackComplianceSummaryRequest.Builder.() -> Unit): Flow =
getConformancePackComplianceSummaryPaginated(GetConformancePackComplianceSummaryRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [getConformancePackComplianceSummaryPaginated]
* to access the nested member [ConformancePackComplianceSummary]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ConformancePackComplianceSummary]
*/
@JvmName("getConformancePackComplianceSummaryResponseConformancePackComplianceSummary")
fun Flow.conformancePackComplianceSummaryList(): Flow =
transform() { response ->
response.conformancePackComplianceSummaryList?.forEach {
emit(it)
}
}
/**
* Paginate over [GetDiscoveredResourceCountsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [GetDiscoveredResourceCountsRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetDiscoveredResourceCountsResponse]
*/
fun ConfigClient.getDiscoveredResourceCountsPaginated(initialRequest: GetDiscoveredResourceCountsRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@getDiscoveredResourceCountsPaginated.getDiscoveredResourceCounts(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [GetDiscoveredResourceCountsResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetDiscoveredResourceCountsResponse]
*/
fun ConfigClient.getDiscoveredResourceCountsPaginated(block: GetDiscoveredResourceCountsRequest.Builder.() -> Unit): Flow =
getDiscoveredResourceCountsPaginated(GetDiscoveredResourceCountsRequest.Builder().apply(block).build())
/**
* Paginate over [GetOrganizationConfigRuleDetailedStatusResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [GetOrganizationConfigRuleDetailedStatusRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetOrganizationConfigRuleDetailedStatusResponse]
*/
fun ConfigClient.getOrganizationConfigRuleDetailedStatusPaginated(initialRequest: GetOrganizationConfigRuleDetailedStatusRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@getOrganizationConfigRuleDetailedStatusPaginated.getOrganizationConfigRuleDetailedStatus(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [GetOrganizationConfigRuleDetailedStatusResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetOrganizationConfigRuleDetailedStatusResponse]
*/
fun ConfigClient.getOrganizationConfigRuleDetailedStatusPaginated(block: GetOrganizationConfigRuleDetailedStatusRequest.Builder.() -> Unit): Flow =
getOrganizationConfigRuleDetailedStatusPaginated(GetOrganizationConfigRuleDetailedStatusRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [getOrganizationConfigRuleDetailedStatusPaginated]
* to access the nested member [MemberAccountStatus]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [MemberAccountStatus]
*/
@JvmName("getOrganizationConfigRuleDetailedStatusResponseMemberAccountStatus")
fun Flow.organizationConfigRuleDetailedStatus(): Flow =
transform() { response ->
response.organizationConfigRuleDetailedStatus?.forEach {
emit(it)
}
}
/**
* Paginate over [GetOrganizationConformancePackDetailedStatusResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [GetOrganizationConformancePackDetailedStatusRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetOrganizationConformancePackDetailedStatusResponse]
*/
fun ConfigClient.getOrganizationConformancePackDetailedStatusPaginated(initialRequest: GetOrganizationConformancePackDetailedStatusRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@getOrganizationConformancePackDetailedStatusPaginated.getOrganizationConformancePackDetailedStatus(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [GetOrganizationConformancePackDetailedStatusResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetOrganizationConformancePackDetailedStatusResponse]
*/
fun ConfigClient.getOrganizationConformancePackDetailedStatusPaginated(block: GetOrganizationConformancePackDetailedStatusRequest.Builder.() -> Unit): Flow =
getOrganizationConformancePackDetailedStatusPaginated(GetOrganizationConformancePackDetailedStatusRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [getOrganizationConformancePackDetailedStatusPaginated]
* to access the nested member [OrganizationConformancePackDetailedStatus]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [OrganizationConformancePackDetailedStatus]
*/
@JvmName("getOrganizationConformancePackDetailedStatusResponseOrganizationConformancePackDetailedStatus")
fun Flow.organizationConformancePackDetailedStatuses(): Flow =
transform() { response ->
response.organizationConformancePackDetailedStatuses?.forEach {
emit(it)
}
}
/**
* Paginate over [GetResourceConfigHistoryResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [GetResourceConfigHistoryRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetResourceConfigHistoryResponse]
*/
fun ConfigClient.getResourceConfigHistoryPaginated(initialRequest: GetResourceConfigHistoryRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = [email protected](req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [GetResourceConfigHistoryResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [GetResourceConfigHistoryResponse]
*/
fun ConfigClient.getResourceConfigHistoryPaginated(block: GetResourceConfigHistoryRequest.Builder.() -> Unit): Flow =
getResourceConfigHistoryPaginated(GetResourceConfigHistoryRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [getResourceConfigHistoryPaginated]
* to access the nested member [ConfigurationItem]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ConfigurationItem]
*/
@JvmName("getResourceConfigHistoryResponseConfigurationItem")
fun Flow.configurationItems(): Flow =
transform() { response ->
response.configurationItems?.forEach {
emit(it)
}
}
/**
* Paginate over [ListAggregateDiscoveredResourcesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [ListAggregateDiscoveredResourcesRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ListAggregateDiscoveredResourcesResponse]
*/
fun ConfigClient.listAggregateDiscoveredResourcesPaginated(initialRequest: ListAggregateDiscoveredResourcesRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@listAggregateDiscoveredResourcesPaginated.listAggregateDiscoveredResources(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [ListAggregateDiscoveredResourcesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ListAggregateDiscoveredResourcesResponse]
*/
fun ConfigClient.listAggregateDiscoveredResourcesPaginated(block: ListAggregateDiscoveredResourcesRequest.Builder.() -> Unit): Flow =
listAggregateDiscoveredResourcesPaginated(ListAggregateDiscoveredResourcesRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [listAggregateDiscoveredResourcesPaginated]
* to access the nested member [AggregateResourceIdentifier]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [AggregateResourceIdentifier]
*/
@JvmName("listAggregateDiscoveredResourcesResponseAggregateResourceIdentifier")
fun Flow.resourceIdentifiers(): Flow =
transform() { response ->
response.resourceIdentifiers?.forEach {
emit(it)
}
}
/**
* Paginate over [ListDiscoveredResourcesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [ListDiscoveredResourcesRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ListDiscoveredResourcesResponse]
*/
fun ConfigClient.listDiscoveredResourcesPaginated(initialRequest: ListDiscoveredResourcesRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = [email protected](req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [ListDiscoveredResourcesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ListDiscoveredResourcesResponse]
*/
fun ConfigClient.listDiscoveredResourcesPaginated(block: ListDiscoveredResourcesRequest.Builder.() -> Unit): Flow =
listDiscoveredResourcesPaginated(ListDiscoveredResourcesRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [listDiscoveredResourcesPaginated]
* to access the nested member [ResourceIdentifier]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ResourceIdentifier]
*/
@JvmName("listDiscoveredResourcesResponseResourceIdentifier")
fun Flow.resourceIdentifiers(): Flow =
transform() { response ->
response.resourceIdentifiers?.forEach {
emit(it)
}
}
/**
* Paginate over [ListStoredQueriesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [ListStoredQueriesRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ListStoredQueriesResponse]
*/
fun ConfigClient.listStoredQueriesPaginated(initialRequest: ListStoredQueriesRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = [email protected](req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [ListStoredQueriesResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ListStoredQueriesResponse]
*/
fun ConfigClient.listStoredQueriesPaginated(block: ListStoredQueriesRequest.Builder.() -> Unit): Flow =
listStoredQueriesPaginated(ListStoredQueriesRequest.Builder().apply(block).build())
/**
* Paginate over [ListTagsForResourceResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [ListTagsForResourceRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ListTagsForResourceResponse]
*/
fun ConfigClient.listTagsForResourcePaginated(initialRequest: ListTagsForResourceRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = [email protected](req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [ListTagsForResourceResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [ListTagsForResourceResponse]
*/
fun ConfigClient.listTagsForResourcePaginated(block: ListTagsForResourceRequest.Builder.() -> Unit): Flow =
listTagsForResourcePaginated(ListTagsForResourceRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [listTagsForResourcePaginated]
* to access the nested member [Tag]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [Tag]
*/
@JvmName("listTagsForResourceResponseTag")
fun Flow.tags(): Flow =
transform() { response ->
response.tags?.forEach {
emit(it)
}
}
/**
* Paginate over [SelectAggregateResourceConfigResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [SelectAggregateResourceConfigRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [SelectAggregateResourceConfigResponse]
*/
fun ConfigClient.selectAggregateResourceConfigPaginated(initialRequest: SelectAggregateResourceConfigRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = this@selectAggregateResourceConfigPaginated.selectAggregateResourceConfig(req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [SelectAggregateResourceConfigResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [SelectAggregateResourceConfigResponse]
*/
fun ConfigClient.selectAggregateResourceConfigPaginated(block: SelectAggregateResourceConfigRequest.Builder.() -> Unit): Flow =
selectAggregateResourceConfigPaginated(SelectAggregateResourceConfigRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [selectAggregateResourceConfigPaginated]
* to access the nested member [String]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [String]
*/
@JvmName("selectAggregateResourceConfigResponseString")
fun Flow.results(): Flow =
transform() { response ->
response.results?.forEach {
emit(it)
}
}
/**
* Paginate over [SelectResourceConfigResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param initialRequest A [SelectResourceConfigRequest] to start pagination
* @return A [kotlinx.coroutines.flow.Flow] that can collect [SelectResourceConfigResponse]
*/
fun ConfigClient.selectResourceConfigPaginated(initialRequest: SelectResourceConfigRequest): Flow =
flow {
var cursor: kotlin.String? = null
var isFirstPage: Boolean = true
while (isFirstPage || (cursor?.isNotEmpty() == true)) {
val req = initialRequest.copy {
this.nextToken = cursor
}
val result = [email protected](req)
isFirstPage = false
cursor = result.nextToken
emit(result)
}
}
/**
* Paginate over [SelectResourceConfigResponse] results.
*
* When this operation is called, a [kotlinx.coroutines.Flow] is created. Flows are lazy (cold) so no service
* calls are made until the flow is collected. This also means there is no guarantee that the request is valid
* until then. Once you start collecting the flow, the SDK will lazily load response pages by making service
* calls until there are no pages left or the flow is cancelled. If there are errors in your request, you will
* see the failures only after you start collection.
* @param block A builder block used for DSL-style invocation of the operation
* @return A [kotlinx.coroutines.flow.Flow] that can collect [SelectResourceConfigResponse]
*/
fun ConfigClient.selectResourceConfigPaginated(block: SelectResourceConfigRequest.Builder.() -> Unit): Flow =
selectResourceConfigPaginated(SelectResourceConfigRequest.Builder().apply(block).build())
/**
* This paginator transforms the flow returned by [selectResourceConfigPaginated]
* to access the nested member [String]
* @return A [kotlinx.coroutines.flow.Flow] that can collect [String]
*/
@JvmName("selectResourceConfigResponseString")
fun Flow.results(): Flow =
transform() { response ->
response.results?.forEach {
emit(it)
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy