Há mais exemplos do AWS SDK disponíveis no repositório do GitHub Documento de Exemplos do AWS SDK
Usar updateModelManifest com um SDK da AWS
Os exemplos de código a seguir mostram como usar o updateModelManifest.
- Java
-
- SDK para Java 2.x
-
nota
Há mais no GitHub. Encontre o exemplo completo e veja como configurar e executar no AWS Code Examples Repository
. /** * Updates the model manifest. * * @param name the name of the model manifest to update */ public void updateModelManifestAsync(String name) { UpdateModelManifestRequest request = UpdateModelManifestRequest.builder() .name(name) .status(ManifestStatus.ACTIVE) .build(); getAsyncClient().updateModelManifest(request) .whenComplete((response, exception) -> { if (exception != null) { throw new CompletionException("Failed to update model manifest: " + exception.getMessage(), exception); } }) .thenApply(response -> null); }-
Consulte detalhes da API em updateModelManifest na Referência de API do AWS SDK for Java 2.x.
-
- Kotlin
-
- SDK para Kotlin
-
nota
Há mais no GitHub. Encontre o exemplo completo e veja como configurar e executar no AWS Code Examples Repository
. /** * Updates the model manifest. * * @param nameVal the name of the model manifest to update */ suspend fun updateModelManifest(nameVal: String) { val request = UpdateModelManifestRequest { name = nameVal status = ManifestStatus.Active } IotFleetWiseClient.fromEnvironment { region = "us-east-1" }.use { fleetwiseClient -> fleetwiseClient.updateModelManifest(request) println("$nameVal was successfully updated") } }-
Consulte detalhes da API em updateModelManifest
na Referência de API do AWS SDK para Kotlin.
-
updateDecoderManifest
AWS IoT SiteWise