com.javonet.core.transmitter.TransmitterWrapper Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of javonet-java-sdk Show documentation
Show all versions of javonet-java-sdk Show documentation
Javonet allows you to reference and use modules or packages written in (Java/Kotlin/Groovy/Clojure, C#/VB.NET, Ruby, Perl, Python, JavaScript/TypeScript) like they were created in your technology.
It works on Linux/Windows and MacOS for applications created in JVM, CLR/Netcore, Perl, Python, Ruby, NodeJS, C++ or GoLang and gives you unparalleled freedom and flexibility with native performance in building your mixed-technologies products.
Let it be accessing best AI or cryptography libraries, devices SDKs, legacy client modules, internal custom packages or anything from public repositories available on NPM, Nuget, PyPI, Maven/Gradle, RubyGems or GitHub. Get free from programming languages barriers today!
For more information check out our guides at https://www.javonet.com/guides/v2/
package com.javonet.core.transmitter;
import java.util.Locale;
public class TransmitterWrapper {
static {
String dir = System.getProperty("user.dir");
if (System.getProperty("os.name").toLowerCase(Locale.US).contains("win")) {
System.load(dir + "\\Binaries\\Native\\Windows\\X64\\JavonetJvmRuntimeNative.dll");
} else if (System.getProperty("os.name").toLowerCase(Locale.US).contains("mac")) {
System.load(dir + "/Binaries/Native/MacOs/X64/libJavonetJvmRuntimeNative.dylib");
} else if (System.getProperty("os.name").toLowerCase(Locale.US).contains("linux")) {
if (System.getProperty("os.version").toLowerCase(Locale.US).contains("android")) {
System.loadLibrary("JavonetJvmRuntimeNative");
} else{
System.load(dir + "/Binaries/Native/Linux/X64/libJavonetJvmRuntimeNative.so");
}
}
}
public native static int sendCommand(byte[] byteArray);
public native static int readResponse(byte[] byteArray);
public native static boolean setEmbeddedRuntime(byte callingRuntimeNumber, byte calledRuntimeNumber, byte calledRuntimeVersion, String path);
public native static boolean deployRuntime(byte[] byteArray, String path, byte channel);
public native static int activate(String licenseKey, String proxyHost, String proxyUserName, String proxyPassword);
public native static String getNativeError();
public native static int setConfigSource(String configSource);
}