Sha256: 09b5e8a891821e89bad544dab783ca83b612f038cea2d40f04838d5202f44f86

Contents?: true

Size: 470 Bytes

Versions: 14

Compression:

Stored size: 470 Bytes

Contents

const AbstractHandler = require("./AbstractHandler");

class CreateClassInstanceHandler extends AbstractHandler {
    process(command) {
        try {
            let clazz = command.payload[0]
            let methodArguments = command.payload.slice(1)
            return new clazz(...methodArguments)
        } catch (error) {
            return this.process_stack_trace(error, this.constructor.name)
        }
    }
}

module.exports = new CreateClassInstanceHandler()

Version data entries

14 entries across 7 versions & 1 rubygems

Version Path
javonet-ruby-sdk-2.1.7 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/handler/CreateClassInstanceHandler.js
javonet-ruby-sdk-2.1.7 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/handler/CreateClassInstanceHandler.js
javonet-ruby-sdk-2.1.6 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/handler/CreateClassInstanceHandler.js
javonet-ruby-sdk-2.1.6 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/handler/CreateClassInstanceHandler.js
javonet-ruby-sdk-2.1.5 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/handler/CreateClassInstanceHandler.js
javonet-ruby-sdk-2.1.5 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/handler/CreateClassInstanceHandler.js
javonet-ruby-sdk-2.1.4 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/handler/CreateClassInstanceHandler.js
javonet-ruby-sdk-2.1.4 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/handler/CreateClassInstanceHandler.js
javonet-ruby-sdk-2.1.3 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/handler/CreateClassInstanceHandler.js
javonet-ruby-sdk-2.1.3 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/handler/CreateClassInstanceHandler.js
javonet-ruby-sdk-2.1.2 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/handler/CreateClassInstanceHandler.js
javonet-ruby-sdk-2.1.2 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/handler/CreateClassInstanceHandler.js
javonet-ruby-sdk-2.1.1 lib/javonet-ruby-sdk/Binaries/Nodejs/Linux/X64/core/handler/CreateClassInstanceHandler.js
javonet-ruby-sdk-2.1.1 lib/javonet-ruby-sdk/Binaries/Nodejs/MacOs/X64/core/handler/CreateClassInstanceHandler.js