File tree Expand file tree Collapse file tree 5 files changed +6
-6
lines changed Expand file tree Collapse file tree 5 files changed +6
-6
lines changed Original file line number Diff line number Diff line change 11import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
22
33plugins {
4- kotlin(" jvm" ) version " 1.9 .0"
4+ kotlin(" jvm" ) version " 2.1 .0"
55 application
66}
77
@@ -27,7 +27,7 @@ repositories {
2727}
2828apply (plugin = " org.jlleitschuh.gradle.ktlint" )
2929dependencies {
30- implementation(platform(" aws.sdk.kotlin:bom:1.3.112 " ))
30+ implementation(platform(" aws.sdk.kotlin:bom:1.4.119 " ))
3131 implementation(" aws.sdk.kotlin:textract" )
3232 implementation(" aws.sdk.kotlin:secretsmanager" )
3333 implementation(" aws.smithy.kotlin:http-client-engine-okhttp" )
Original file line number Diff line number Diff line change @@ -59,7 +59,7 @@ suspend fun analyzeDoc(sourceDoc: String?) {
5959 document = myDoc
6060 }
6161
62- TextractClient { region = " us-east-1" }.use { textractClient ->
62+ TextractClient .fromEnvironment { region = " us-east-1" }.use { textractClient ->
6363 val response = textractClient.analyzeDocument(analyzeDocumentRequest)
6464 response.blocks?.forEach { block ->
6565 println (" The block type is ${block.blockType} " )
Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ suspend fun detectDocText(sourceDoc: String) {
5353 document = myDoc
5454 }
5555
56- TextractClient { region = " us-east-1" }.use { textractClient ->
56+ TextractClient .fromEnvironment { region = " us-east-1" }.use { textractClient ->
5757 val response = textractClient.detectDocumentText(detectDocumentTextRequest)
5858 response.blocks?.forEach { block ->
5959 println (" The block type is ${block.blockType} " )
Original file line number Diff line number Diff line change @@ -59,7 +59,7 @@ suspend fun detectDocTextS3(
5959 document = myDoc
6060 }
6161
62- TextractClient { region = " us-west-2" }.use { textractClient ->
62+ TextractClient .fromEnvironment { region = " us-west-2" }.use { textractClient ->
6363 val response = textractClient.detectDocumentText(detectDocumentTextRequest)
6464 response.blocks?.forEach { block ->
6565 println (" The block type is ${block.blockType} " )
Original file line number Diff line number Diff line change @@ -67,7 +67,7 @@ suspend fun startDocAnalysisS3(
6767 featureTypes = myList
6868 }
6969
70- TextractClient { region = " us-west-2" }.use { textractClient ->
70+ TextractClient .fromEnvironment { region = " us-west-2" }.use { textractClient ->
7171 val response = textractClient.startDocumentAnalysis(documentAnalysisRequest)
7272
7373 // Get the job ID.
You can’t perform that action at this time.
0 commit comments