Sha256: 8bef86eaf9a62bdb0ce6eb49f298f12785a93c7f3fbabf56a4ed3381a74c7b8b
Contents?: true
Size: 627 Bytes
Versions: 58
Compression:
Stored size: 627 Bytes
Contents
require_relative 'abstract_command_handler' class LoadLibraryHandler < AbstractCommandHandler def initialize @required_parameters_count = 1 end def process(command) begin if command.payload.length < @required_parameters_count raise ArgumentError.new "Load library parameters mismatch" end if command.payload.length > @required_parameters_count assembly_name = command.payload[1] else assembly_name = command.payload[0] end #noinspection RubyResolve require(assembly_name) return 0 rescue Exception => e return e end end end
Version data entries
58 entries across 29 versions & 1 rubygems