-
-
Notifications
You must be signed in to change notification settings - Fork 88
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Built Backup/DirectoryService Paginators
- Loading branch information
1 parent
37f9c54
commit 72650d0
Showing
3 changed files
with
242 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
214 changes: 214 additions & 0 deletions
214
Sources/AWSSDKSwift/Services/Backup/Backup_Paginator.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,214 @@ | ||
// THIS FILE IS AUTOMATICALLY GENERATED by https://github.com/swift-aws/aws-sdk-swift/blob/master/CodeGenerator/Sources/CodeGenerator/main.swift. DO NOT EDIT. | ||
|
||
import NIO | ||
|
||
//MARK: Paginators | ||
|
||
extension Backup { | ||
|
||
/// Returns metadata about your backup jobs. | ||
public func listBackupJobsPaginator(_ input: ListBackupJobsInput, onPage: @escaping (ListBackupJobsOutput, EventLoop)->EventLoopFuture<Bool>) -> EventLoopFuture<Void> { | ||
return client.paginate(input: input, command: listBackupJobs, tokenKey: \ListBackupJobsOutput.nextToken, onPage: onPage) | ||
} | ||
|
||
/// Returns metadata of your saved backup plan templates, including the template ID, name, and the creation and deletion dates. | ||
public func listBackupPlanTemplatesPaginator(_ input: ListBackupPlanTemplatesInput, onPage: @escaping (ListBackupPlanTemplatesOutput, EventLoop)->EventLoopFuture<Bool>) -> EventLoopFuture<Void> { | ||
return client.paginate(input: input, command: listBackupPlanTemplates, tokenKey: \ListBackupPlanTemplatesOutput.nextToken, onPage: onPage) | ||
} | ||
|
||
/// Returns version metadata of your backup plans, including Amazon Resource Names (ARNs), backup plan IDs, creation and deletion dates, plan names, and version IDs. | ||
public func listBackupPlanVersionsPaginator(_ input: ListBackupPlanVersionsInput, onPage: @escaping (ListBackupPlanVersionsOutput, EventLoop)->EventLoopFuture<Bool>) -> EventLoopFuture<Void> { | ||
return client.paginate(input: input, command: listBackupPlanVersions, tokenKey: \ListBackupPlanVersionsOutput.nextToken, onPage: onPage) | ||
} | ||
|
||
/// Returns metadata of your saved backup plans, including Amazon Resource Names (ARNs), plan IDs, creation and deletion dates, version IDs, plan names, and creator request IDs. | ||
public func listBackupPlansPaginator(_ input: ListBackupPlansInput, onPage: @escaping (ListBackupPlansOutput, EventLoop)->EventLoopFuture<Bool>) -> EventLoopFuture<Void> { | ||
return client.paginate(input: input, command: listBackupPlans, tokenKey: \ListBackupPlansOutput.nextToken, onPage: onPage) | ||
} | ||
|
||
/// Returns an array containing metadata of the resources associated with the target backup plan. | ||
public func listBackupSelectionsPaginator(_ input: ListBackupSelectionsInput, onPage: @escaping (ListBackupSelectionsOutput, EventLoop)->EventLoopFuture<Bool>) -> EventLoopFuture<Void> { | ||
return client.paginate(input: input, command: listBackupSelections, tokenKey: \ListBackupSelectionsOutput.nextToken, onPage: onPage) | ||
} | ||
|
||
/// Returns a list of recovery point storage containers along with information about them. | ||
public func listBackupVaultsPaginator(_ input: ListBackupVaultsInput, onPage: @escaping (ListBackupVaultsOutput, EventLoop)->EventLoopFuture<Bool>) -> EventLoopFuture<Void> { | ||
return client.paginate(input: input, command: listBackupVaults, tokenKey: \ListBackupVaultsOutput.nextToken, onPage: onPage) | ||
} | ||
|
||
/// Returns metadata about your copy jobs. | ||
public func listCopyJobsPaginator(_ input: ListCopyJobsInput, onPage: @escaping (ListCopyJobsOutput, EventLoop)->EventLoopFuture<Bool>) -> EventLoopFuture<Void> { | ||
return client.paginate(input: input, command: listCopyJobs, tokenKey: \ListCopyJobsOutput.nextToken, onPage: onPage) | ||
} | ||
|
||
/// Returns an array of resources successfully backed up by AWS Backup, including the time the resource was saved, an Amazon Resource Name (ARN) of the resource, and a resource type. | ||
public func listProtectedResourcesPaginator(_ input: ListProtectedResourcesInput, onPage: @escaping (ListProtectedResourcesOutput, EventLoop)->EventLoopFuture<Bool>) -> EventLoopFuture<Void> { | ||
return client.paginate(input: input, command: listProtectedResources, tokenKey: \ListProtectedResourcesOutput.nextToken, onPage: onPage) | ||
} | ||
|
||
/// Returns detailed information about the recovery points stored in a backup vault. | ||
public func listRecoveryPointsByBackupVaultPaginator(_ input: ListRecoveryPointsByBackupVaultInput, onPage: @escaping (ListRecoveryPointsByBackupVaultOutput, EventLoop)->EventLoopFuture<Bool>) -> EventLoopFuture<Void> { | ||
return client.paginate(input: input, command: listRecoveryPointsByBackupVault, tokenKey: \ListRecoveryPointsByBackupVaultOutput.nextToken, onPage: onPage) | ||
} | ||
|
||
/// Returns detailed information about recovery points of the type specified by a resource Amazon Resource Name (ARN). | ||
public func listRecoveryPointsByResourcePaginator(_ input: ListRecoveryPointsByResourceInput, onPage: @escaping (ListRecoveryPointsByResourceOutput, EventLoop)->EventLoopFuture<Bool>) -> EventLoopFuture<Void> { | ||
return client.paginate(input: input, command: listRecoveryPointsByResource, tokenKey: \ListRecoveryPointsByResourceOutput.nextToken, onPage: onPage) | ||
} | ||
|
||
/// Returns a list of jobs that AWS Backup initiated to restore a saved resource, including metadata about the recovery process. | ||
public func listRestoreJobsPaginator(_ input: ListRestoreJobsInput, onPage: @escaping (ListRestoreJobsOutput, EventLoop)->EventLoopFuture<Bool>) -> EventLoopFuture<Void> { | ||
return client.paginate(input: input, command: listRestoreJobs, tokenKey: \ListRestoreJobsOutput.nextToken, onPage: onPage) | ||
} | ||
|
||
/// Returns a list of key-value pairs assigned to a target recovery point, backup plan, or backup vault. | ||
public func listTagsPaginator(_ input: ListTagsInput, onPage: @escaping (ListTagsOutput, EventLoop)->EventLoopFuture<Bool>) -> EventLoopFuture<Void> { | ||
return client.paginate(input: input, command: listTags, tokenKey: \ListTagsOutput.nextToken, onPage: onPage) | ||
} | ||
|
||
} | ||
|
||
extension Backup.ListBackupJobsInput: AWSPaginateStringToken { | ||
public func usingPaginationToken(_ token: String) -> Backup.ListBackupJobsInput { | ||
return .init( | ||
byBackupVaultName: self.byBackupVaultName, | ||
byCreatedAfter: self.byCreatedAfter, | ||
byCreatedBefore: self.byCreatedBefore, | ||
byResourceArn: self.byResourceArn, | ||
byResourceType: self.byResourceType, | ||
byState: self.byState, | ||
maxResults: self.maxResults, | ||
nextToken: token | ||
) | ||
|
||
} | ||
} | ||
|
||
extension Backup.ListBackupPlanTemplatesInput: AWSPaginateStringToken { | ||
public func usingPaginationToken(_ token: String) -> Backup.ListBackupPlanTemplatesInput { | ||
return .init( | ||
maxResults: self.maxResults, | ||
nextToken: token | ||
) | ||
|
||
} | ||
} | ||
|
||
extension Backup.ListBackupPlanVersionsInput: AWSPaginateStringToken { | ||
public func usingPaginationToken(_ token: String) -> Backup.ListBackupPlanVersionsInput { | ||
return .init( | ||
backupPlanId: self.backupPlanId, | ||
maxResults: self.maxResults, | ||
nextToken: token | ||
) | ||
|
||
} | ||
} | ||
|
||
extension Backup.ListBackupPlansInput: AWSPaginateStringToken { | ||
public func usingPaginationToken(_ token: String) -> Backup.ListBackupPlansInput { | ||
return .init( | ||
includeDeleted: self.includeDeleted, | ||
maxResults: self.maxResults, | ||
nextToken: token | ||
) | ||
|
||
} | ||
} | ||
|
||
extension Backup.ListBackupSelectionsInput: AWSPaginateStringToken { | ||
public func usingPaginationToken(_ token: String) -> Backup.ListBackupSelectionsInput { | ||
return .init( | ||
backupPlanId: self.backupPlanId, | ||
maxResults: self.maxResults, | ||
nextToken: token | ||
) | ||
|
||
} | ||
} | ||
|
||
extension Backup.ListBackupVaultsInput: AWSPaginateStringToken { | ||
public func usingPaginationToken(_ token: String) -> Backup.ListBackupVaultsInput { | ||
return .init( | ||
maxResults: self.maxResults, | ||
nextToken: token | ||
) | ||
|
||
} | ||
} | ||
|
||
extension Backup.ListCopyJobsInput: AWSPaginateStringToken { | ||
public func usingPaginationToken(_ token: String) -> Backup.ListCopyJobsInput { | ||
return .init( | ||
byCreatedAfter: self.byCreatedAfter, | ||
byCreatedBefore: self.byCreatedBefore, | ||
byDestinationVaultArn: self.byDestinationVaultArn, | ||
byResourceArn: self.byResourceArn, | ||
byResourceType: self.byResourceType, | ||
byState: self.byState, | ||
maxResults: self.maxResults, | ||
nextToken: token | ||
) | ||
|
||
} | ||
} | ||
|
||
extension Backup.ListProtectedResourcesInput: AWSPaginateStringToken { | ||
public func usingPaginationToken(_ token: String) -> Backup.ListProtectedResourcesInput { | ||
return .init( | ||
maxResults: self.maxResults, | ||
nextToken: token | ||
) | ||
|
||
} | ||
} | ||
|
||
extension Backup.ListRecoveryPointsByBackupVaultInput: AWSPaginateStringToken { | ||
public func usingPaginationToken(_ token: String) -> Backup.ListRecoveryPointsByBackupVaultInput { | ||
return .init( | ||
backupVaultName: self.backupVaultName, | ||
byBackupPlanId: self.byBackupPlanId, | ||
byCreatedAfter: self.byCreatedAfter, | ||
byCreatedBefore: self.byCreatedBefore, | ||
byResourceArn: self.byResourceArn, | ||
byResourceType: self.byResourceType, | ||
maxResults: self.maxResults, | ||
nextToken: token | ||
) | ||
|
||
} | ||
} | ||
|
||
extension Backup.ListRecoveryPointsByResourceInput: AWSPaginateStringToken { | ||
public func usingPaginationToken(_ token: String) -> Backup.ListRecoveryPointsByResourceInput { | ||
return .init( | ||
maxResults: self.maxResults, | ||
nextToken: token, | ||
resourceArn: self.resourceArn | ||
) | ||
|
||
} | ||
} | ||
|
||
extension Backup.ListRestoreJobsInput: AWSPaginateStringToken { | ||
public func usingPaginationToken(_ token: String) -> Backup.ListRestoreJobsInput { | ||
return .init( | ||
maxResults: self.maxResults, | ||
nextToken: token | ||
) | ||
|
||
} | ||
} | ||
|
||
extension Backup.ListTagsInput: AWSPaginateStringToken { | ||
public func usingPaginationToken(_ token: String) -> Backup.ListTagsInput { | ||
return .init( | ||
maxResults: self.maxResults, | ||
nextToken: token, | ||
resourceArn: self.resourceArn | ||
) | ||
|
||
} | ||
} | ||
|
||
|
28 changes: 28 additions & 0 deletions
28
Sources/AWSSDKSwift/Services/DirectoryService/DirectoryService_Paginator.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
// THIS FILE IS AUTOMATICALLY GENERATED by https://github.com/swift-aws/aws-sdk-swift/blob/master/CodeGenerator/Sources/CodeGenerator/main.swift. DO NOT EDIT. | ||
|
||
import NIO | ||
|
||
//MARK: Paginators | ||
|
||
extension DirectoryService { | ||
|
||
/// Provides information about any domain controllers in your directory. | ||
public func describeDomainControllersPaginator(_ input: DescribeDomainControllersRequest, onPage: @escaping (DescribeDomainControllersResult, EventLoop)->EventLoopFuture<Bool>) -> EventLoopFuture<Void> { | ||
return client.paginate(input: input, command: describeDomainControllers, tokenKey: \DescribeDomainControllersResult.nextToken, onPage: onPage) | ||
} | ||
|
||
} | ||
|
||
extension DirectoryService.DescribeDomainControllersRequest: AWSPaginateStringToken { | ||
public func usingPaginationToken(_ token: String) -> DirectoryService.DescribeDomainControllersRequest { | ||
return .init( | ||
directoryId: self.directoryId, | ||
domainControllerIds: self.domainControllerIds, | ||
limit: self.limit, | ||
nextToken: token | ||
) | ||
|
||
} | ||
} | ||
|
||
|