Sha256: a3a6a17f392565b01b4499374d747bb6c2013647a58b2a0cba95fb17c772e226

Contents?: true

Size: 1.03 KB

Versions: 16

Compression:

Stored size: 1.03 KB

Contents

let library;

class TransmitterWrapper {
    static initialize() {
        if (process.platform === "win32")
            library = require(`${require('path').resolve(__dirname, '../../../')}/build/Release/JavonetNodejsRuntimeAddon.node`)
        else if (process.platform === "darwin")
            library = require(`${require('path').resolve(__dirname, '../../../')}/build/Release/JavonetNodejsRuntimeAddon.node`)
        else
            library = require(`${require('path').resolve(__dirname, '../../../')}/build/Release/JavonetNodejsRuntimeAddon.node`)
        let binariesRootPath = String(`${require('path').resolve(__dirname, '../../../')}`)
        return library.initializeTransmitter(binariesRootPath)
    }

    static activate(licenceKey, proxyHost, proxyUserName, proxyUserPassword) {
        this.initialize()
        return library.activate(licenceKey, proxyHost, proxyUserName, proxyUserPassword)
    }

    static sendCommand(messageArray) {
        return library.sendCommand(messageArray)
    }
}

module.exports = TransmitterWrapper

Version data entries

16 entries across 8 versions & 1 rubygems

Version Path
javonet-ruby-sdk-2.3.0 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.3.0 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.2.0 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.2.0 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.1.14 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.1.14 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.1.13 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.1.13 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.1.12 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.1.12 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.1.11 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.1.11 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.1.10 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.1.10 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.1.9 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/transmitter/TransmitterWrapper.js
javonet-ruby-sdk-2.1.9 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/transmitter/TransmitterWrapper.js