AWS 文档 AWS SDK示例 GitHub 存储库中还有更多SDK示例
本文属于机器翻译版本。若本译文内容与英语原文存在差异,则一律以英文原文为准。
与 AWS SDK或ListIdentityPoolUsage
一起使用 CLI
以下代码示例演示如何使用 ListIdentityPoolUsage
。
- Rust
-
- SDK对于 Rust
-
注意
还有更多相关信息 GitHub。在 AWS 代码示例存储库
中查找完整实例,了解如何进行设置和运行。 async fn show_pools(client: &Client) -> Result<(), Error> { let response = client .list_identity_pool_usage() .max_results(10) .send() .await?; let pools = response.identity_pool_usages(); println!("Identity pools:"); for pool in pools { println!( " Identity pool ID: {}", pool.identity_pool_id().unwrap_or_default() ); println!( " Data storage: {}", pool.data_storage().unwrap_or_default() ); println!( " Sync sessions count: {}", pool.sync_sessions_count().unwrap_or_default() ); println!( " Last modified: {}", pool.last_modified_date().unwrap().to_chrono_utc()? ); println!(); } println!("Next token: {}", response.next_token().unwrap_or_default()); Ok(()) }
-
有关API详细信息,请参见ListIdentityPoolUsage
中的 Rust AWS SDK API 参考。
-
操作
Amazon Comprehend