diff --git a/build.gradle b/build.gradle index 410aab8..a824515 100644 --- a/build.gradle +++ b/build.gradle @@ -11,13 +11,13 @@ repositories { sourceCompatibility = '11' dependencies { - implementation group: 'net.java.dev.jna', name: 'jna', version: '5.13.0' - implementation group: 'net.java.dev.jna', name: 'jna-platform', version: '5.13.0' + implementation group: 'net.java.dev.jna', name: 'jna', version: '5.15.0' + implementation group: 'net.java.dev.jna', name: 'jna-platform', version: '5.15.0' - compileOnly group: 'com.bloxbean.cardano', name: 'cardano-client-lib', version: '0.5.0' + compileOnly group: 'com.bloxbean.cardano', name: 'cardano-client-lib', version: '0.6.0' - compileOnly 'org.projectlombok:lombok:1.18.26' - annotationProcessor 'org.projectlombok:lombok:1.18.26' + compileOnly 'org.projectlombok:lombok:1.18.30' + annotationProcessor 'org.projectlombok:lombok:1.18.30' testImplementation 'org.junit.jupiter:junit-jupiter-api:5.9.2' testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine' @@ -28,9 +28,9 @@ dependencies { testImplementation('org.assertj:assertj-core:3.24.2') testRuntimeOnly 'org.slf4j:slf4j-log4j12:2.0.5' - testImplementation group: 'com.bloxbean.cardano', name: 'cardano-client-lib', version: '0.5.0' - testImplementation group: 'com.bloxbean.cardano', name: 'cardano-client-backend-koios', version: '0.5.0' - testImplementation group: 'com.bloxbean.cardano', name: 'cardano-client-backend-blockfrost', version: '0.5.0' + testImplementation group: 'com.bloxbean.cardano', name: 'cardano-client-lib', version: '0.6.0' + testImplementation group: 'com.bloxbean.cardano', name: 'cardano-client-backend-koios', version: '0.6.0' + testImplementation group: 'com.bloxbean.cardano', name: 'cardano-client-backend-blockfrost', version: '0.6.0' testCompileOnly 'org.projectlombok:lombok:1.18.30' testAnnotationProcessor 'org.projectlombok:lombok:1.18.30' diff --git a/download_libs.sh b/download_libs.sh index 4b0de5c..b528b06 100755 --- a/download_libs.sh +++ b/download_libs.sh @@ -1,6 +1,6 @@ #!/bin/bash -tag=v0.5.0 +tag=v0.6.0 mkdir -p native/linux-x86-64 mkdir -p native/darwin-aarch64 diff --git a/native/darwin-aarch64/libaiken_jna_wrapper.dylib b/native/darwin-aarch64/libaiken_jna_wrapper.dylib index 6e13161..a961989 100644 Binary files a/native/darwin-aarch64/libaiken_jna_wrapper.dylib and b/native/darwin-aarch64/libaiken_jna_wrapper.dylib differ diff --git a/native/darwin-x86-64/libaiken_jna_wrapper.dylib b/native/darwin-x86-64/libaiken_jna_wrapper.dylib index a1c0107..7b7d442 100644 Binary files a/native/darwin-x86-64/libaiken_jna_wrapper.dylib and b/native/darwin-x86-64/libaiken_jna_wrapper.dylib differ diff --git a/native/linux-x86-64/libaiken_jna_wrapper.so b/native/linux-x86-64/libaiken_jna_wrapper.so index 0e8222d..e376a43 100644 Binary files a/native/linux-x86-64/libaiken_jna_wrapper.so and b/native/linux-x86-64/libaiken_jna_wrapper.so differ diff --git a/native/version b/native/version index b043aa6..60f6343 100644 --- a/native/version +++ b/native/version @@ -1 +1 @@ -v0.5.0 +v0.6.0 diff --git a/native/win32-aarch64/aiken_jna_wrapper.dll b/native/win32-aarch64/aiken_jna_wrapper.dll index 6eb4a78..3bf9fa3 100644 Binary files a/native/win32-aarch64/aiken_jna_wrapper.dll and b/native/win32-aarch64/aiken_jna_wrapper.dll differ diff --git a/native/win32-x86-64/aiken_jna_wrapper.dll b/native/win32-x86-64/aiken_jna_wrapper.dll index cf2d3e1..0908500 100644 Binary files a/native/win32-x86-64/aiken_jna_wrapper.dll and b/native/win32-x86-64/aiken_jna_wrapper.dll differ diff --git a/src/main/java/com/bloxbean/cardano/aiken/AikenTransactionEvaluator.java b/src/main/java/com/bloxbean/cardano/aiken/AikenTransactionEvaluator.java index 5af8aa5..5d26fc9 100644 --- a/src/main/java/com/bloxbean/cardano/aiken/AikenTransactionEvaluator.java +++ b/src/main/java/com/bloxbean/cardano/aiken/AikenTransactionEvaluator.java @@ -18,6 +18,7 @@ import com.bloxbean.cardano.client.transaction.spec.TransactionInput; import com.bloxbean.cardano.client.transaction.spec.TransactionWitnessSet; import com.bloxbean.cardano.client.util.JsonUtil; +import com.bloxbean.cardano.client.api.ScriptSupplier; import lombok.NonNull; import java.util.*; @@ -101,7 +102,7 @@ public Result> evaluateTx(byte[] cbor, Set inputUtx //Get reference input script if (utxo.getReferenceScriptHash() != null && scriptSupplier != null) { - additionalScripts.add(scriptSupplier.getScript(utxo.getReferenceScriptHash())); + scriptSupplier.getScript(utxo.getReferenceScriptHash()).ifPresent(additionalScripts::add); } } diff --git a/src/main/java/com/bloxbean/cardano/aiken/ScriptSupplier.java b/src/main/java/com/bloxbean/cardano/aiken/ScriptSupplier.java deleted file mode 100644 index 1a47bea..0000000 --- a/src/main/java/com/bloxbean/cardano/aiken/ScriptSupplier.java +++ /dev/null @@ -1,10 +0,0 @@ -package com.bloxbean.cardano.aiken; - -import com.bloxbean.cardano.client.plutus.spec.PlutusScript; - -/** - * Interface for supplying Plutus scripts - */ -public interface ScriptSupplier { - PlutusScript getScript(String scriptHash); -}