AWS 문서 AWS SDK 예제 리포지토리에 더 많은 SDK
기계 번역으로 제공되는 번역입니다. 제공된 번역과 원본 영어의 내용이 상충하는 경우에는 영어 버전이 우선합니다.
AWS SDK 또는 DeleteLexicon
CLI와 함께 사용
다음 코드 예제는 DeleteLexicon
의 사용 방법을 보여줍니다.
- .NET
-
- AWS SDK for .NET
-
참고
더 많은 정보가 있습니다. GitHub AWS 코드 예제 리포지토리
에서 전체 예제를 찾고 설정 및 실행하는 방법을 배워보세요. using System; using System.Threading.Tasks; using Amazon.Polly; using Amazon.Polly.Model; /// <summary> /// Deletes an existing Amazon Polly lexicon using the AWS SDK for .NET. /// </summary> public class DeleteLexicon { public static async Task Main() { string lexiconName = "SampleLexicon"; var client = new AmazonPollyClient(); var success = await DeletePollyLexiconAsync(client, lexiconName); if (success) { Console.WriteLine($"Successfully deleted {lexiconName}."); } else { Console.WriteLine($"Could not delete {lexiconName}."); } } /// <summary> /// Deletes the named Amazon Polly lexicon. /// </summary> /// <param name="client">The initialized Amazon Polly client object.</param> /// <param name="lexiconName">The name of the Amazon Polly lexicon to /// delete.</param> /// <returns>A Boolean value indicating the success of the operation.</returns> public static async Task<bool> DeletePollyLexiconAsync( AmazonPollyClient client, string lexiconName) { var deleteLexiconRequest = new DeleteLexiconRequest() { Name = lexiconName, }; var response = await client.DeleteLexiconAsync(deleteLexiconRequest); return response.HttpStatusCode == System.Net.HttpStatusCode.OK; } }
-
API 세부 정보는 AWS SDK for .NET API DeleteLexicon참조를 참조하십시오.
-
- CLI
-
- AWS CLI
-
어휘를 삭제하는 방법
다음
delete-lexicon
예시에서는 지정된 어휘를 삭제합니다.aws polly delete-lexicon \ --name w3c
이 명령은 출력을 생성하지 않습니다.
자세한 내용은 Amazon Polly 개발자 안내서의 DeleteLexicon 작업 사용을 참조하십시오.
-
API 세부 정보는 AWS CLI 명령 DeleteLexicon
참조를 참조하십시오.
-
작업
DescribeVoices