javonet-ruby-sdk 2.6.6 → 2.6.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/lib/javonet-ruby-sdk/Binaries/Clr/JavonetClrRuntime.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Jvm/JavonetJvmRuntime.jar +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Linux/ARM64/libJavonetActivationService.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Linux/ARM64/libJavonetJvmRuntimeNative.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Linux/ARM64/libJavonetRubyRuntimeNative.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Linux/ARM64/libUtils.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Linux/ARM64/version.txt +1 -1
- data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetActivationService.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetJvmRuntimeNative.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetNodejs2218RuntimeNative.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetRubyRuntimeNative.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libUtils.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/version.txt +1 -1
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/ARM64/libJavonetActivationService.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/ARM64/libJavonetCppRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/ARM64/libJavonetGoRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/ARM64/libJavonetJvmRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/ARM64/libJavonetNetcoreRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/ARM64/libJavonetPythonRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/ARM64/libJavonetRubyRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/ARM64/libJavonetTcpClient.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/ARM64/libJavonetTcpTlsClient.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/ARM64/libUtils.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/ARM64/version.txt +1 -1
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetActivationService.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetCppRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetGoRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetJvmRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetNetcoreRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetNodejs2218RuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetNodejsRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetPerlRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetPhp848RuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetPhpRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetPythonRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetRubyRuntimeNative.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetTcpClient.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetTcpTlsClient.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libUtils.dylib +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/version.txt +1 -1
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/ARM64/Configs.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/ARM64/JavonetActivationService.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/ARM64/JavonetCppRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/ARM64/JavonetGoRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/ARM64/JavonetJvmRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/ARM64/JavonetNetcoreRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/ARM64/JavonetPhpRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/ARM64/JavonetPythonRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/ARM64/JavonetRubyRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/ARM64/JavonetTcpClient.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/ARM64/JavonetTcpTlsClient.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/ARM64/Utils.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/ARM64/version.txt +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/Configs.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetActivationService.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetClrRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetCppRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetGoRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetJvmRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetNetcoreRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetNodejs2218RuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetNodejsRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetPerlRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetPhp848RuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetPhpRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetPython2RuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetPythonRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetRubyRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetTcpClient.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetTcpTlsClient.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/Utils.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/version.txt +1 -1
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/Configs.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/JavonetActivationService.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/JavonetClrRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/JavonetCppRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/JavonetGoRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/JavonetJvmRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/JavonetNetcoreRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/JavonetPhpRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/JavonetPython2RuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/JavonetPythonRuntimeNative.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/JavonetTcpClient.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/JavonetTcpTlsClient.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/Utils.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X86/version.txt +1 -1
- data/lib/javonet-ruby-sdk/Binaries/Netcore/Javonet.Netcore.Core.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Netcore/Javonet.Netcore.Plugins.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Netcore/Javonet.Netcore.Utils.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/core/handler/Handler.cjs +2 -7
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/core/handler/LoadLibraryHandler.cjs +26 -12
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/core/handler/PassDelegateHandler.cjs +2 -2
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/core/interpreter/Interpreter.cjs +27 -92
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/core/protocol/CommandSerializer.cjs +3 -8
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/core/receiver/Receiver.cjs +6 -6
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/sdk/Activator.cjs +44 -0
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/sdk/ActivatorDetails.cjs +13 -3
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/sdk/ConfigRuntimeFactory.cjs +9 -0
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/sdk/InvocationContext.cjs +52 -200
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/sdk/Javonet.cjs +3 -11
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/sdk/RuntimeContext.cjs +11 -57
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/sdk/configuration/ConfigSourceResolver.cjs +43 -21
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/sdk/tools/ComplexTypeResolver.cjs +84 -45
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/core/handler/Handler.d.ts +2 -1
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/core/handler/PassDelegateHandler.d.ts +2 -2
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/core/interpreter/Interpreter.d.ts +2 -9
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/core/protocol/CommandSerializer.d.ts +3 -3
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/core/receiver/Receiver.d.ts +4 -4
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/sdk/Activator.d.ts +12 -0
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/sdk/ActivatorDetails.d.ts +5 -3
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/sdk/ConfigRuntimeFactory.d.ts +7 -0
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/sdk/InvocationContext.d.ts +11 -34
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/sdk/Javonet.d.ts +3 -1
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/sdk/RuntimeContext.d.ts +4 -3
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/sdk/configuration/ConfigSourceResolver.d.ts +21 -4
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/sdk/tools/ComplexTypeResolver.d.ts +21 -5
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/types/utils/Primitives.d.ts +5 -0
- data/lib/javonet-ruby-sdk/Binaries/Nodejs/dist/utils/Primitives.cjs +201 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/auto/Class/Load/XS/XS.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/auto/Data/UUID/UUID.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/auto/FFI/Platypus/Platypus.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/auto/List/Util/Util.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/auto/Moose/Moose.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/auto/PPI/XS/XS.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/auto/Package/Stash/XS/XS.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/auto/Params/Util/Util.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/auto/Want/Want.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/auto/share/dist/FFI-Platypus/lib/libplfill.so +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/perllocal.pod +96 -96
- data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/lib/Javonet/Core/Handler/CommandHandler/LoadLibraryHandler.pm +108 -11
- data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/MSWin32-x64-multi-thread/auto/Data/UUID/UUID.xs.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/MSWin32-x64-multi-thread/auto/PPI/XS/XS.xs.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/MSWin32-x64-multi-thread/auto/Scalar/Util/Numeric/Numeric.xs.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/MSWin32-x64-multi-thread/auto/Want/Want.xs.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/MSWin32-x64-multi-thread/auto/autobox/autobox.xs.dll +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/MSWin32-x64-multi-thread/perllocal.pod +24 -24
- data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/lib/Javonet/Core/Handler/CommandHandler/LoadLibraryHandler.pm +108 -11
- data/lib/javonet-ruby-sdk/Binaries/Php/javonet/core/handler/LoadLibraryHandler.php +56 -21
- data/lib/javonet-ruby-sdk/Binaries/Php/javonet/core/interpreter/Interpreter.php +2 -2
- data/lib/javonet-ruby-sdk/Binaries/Php/javonet/core/protocol/CommandDeserializer.php +219 -106
- data/lib/javonet-ruby-sdk/Binaries/Php/javonet/core/protocol/CommandSerializer.php +55 -13
- data/lib/javonet-ruby-sdk/Binaries/Php/javonet/utils/Command.php +27 -9
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/__pycache__/__init__.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/delegateCache/__pycache__/DelegatesCache.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/delegateCache/__pycache__/__init__.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/GetTypeHandler.py +2 -2
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/LoadLibraryHandler.py +54 -14
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/AbstractCommandHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/AbstractHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/AddEventListenerHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/ArrayGetItemHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/ArrayGetRankHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/ArrayGetSizeHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/ArrayHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/ArrayReferenceHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/ArraySetItemHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/AsOutHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/AsRefHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/CastingHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/ConvertTypeHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/CreateClassInstanceHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/CreateNullHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/DestructReferenceHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/EnableNamespaceHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/EnableTypeHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/ExceptionHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GenerateLibHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetAsyncOperationResultHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetEnumItemHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetEnumNameHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetEnumValueHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetGlobalFieldHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetInstanceFieldHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetInstanceMethodAsDelegateHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetKwargHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetModuleHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetRefValueHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetResultTypeHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetStaticFieldHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetStaticMethodAsDelegateHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/GetTypeHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/Handler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/HandlerDictionary.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/HeartBeatHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/InvokeDelegateHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/InvokeGenericMethodHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/InvokeGenericStaticMethodHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/InvokeGlobalFunctionHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/InvokeInstanceMethodHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/InvokeStaticMethodHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/LoadLibraryHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/OptimizeHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/PassDelegateHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/PluginWrapperHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/ResolveInstanceHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/RetrieveArrayHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/SetInstanceFieldHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/SetStaticFieldHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/ValueHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/handler/__pycache__/__init__.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/interpreter/__pycache__/Interpreter.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/interpreter/__pycache__/__init__.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/namespaceCache/__pycache__/NamespaceCache.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/namespaceCache/__pycache__/__init__.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/protocol/__pycache__/CommandDeserializer.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/protocol/__pycache__/CommandSerializer.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/protocol/__pycache__/TypeDeserializer.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/protocol/__pycache__/TypeSerializer.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/protocol/__pycache__/__init__.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/receiver/__pycache__/Receiver.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/receiver/__pycache__/__init__.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/referenceCache/__pycache__/ReferencesCache.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/referenceCache/__pycache__/__init__.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/typeCache/__pycache__/TypeCache.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/core/typeCache/__pycache__/__init__.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/LazyModuleLoader.py +8 -11
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/__pycache__/Command.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/__pycache__/CommandType.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/__pycache__/ConnectionType.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/__pycache__/ExceptionType.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/__pycache__/LazyModuleLoader.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/__pycache__/RuntimeLogger.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/__pycache__/RuntimeName.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/__pycache__/StringEncodingMode.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/__pycache__/Type.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/__pycache__/TypesHandler.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/__pycache__/UtilsConst.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/__pycache__/__init__.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/connectionData/__pycache__/IConnectionData.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/connectionData/__pycache__/InMemoryConnectionData.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/connectionData/__pycache__/__init__.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/exception/ExceptionSerializer.py +1 -1
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/exception/__pycache__/ExceptionSerializer.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/exception/__pycache__/ExceptionThrower.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/exception/__pycache__/JavonetException.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/exception/__pycache__/__init__.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/messageHelper/__pycache__/MessageHelper.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/Python/javonet/utils/messageHelper/__pycache__/__init__.cpython-312.pyc +0 -0
- data/lib/javonet-ruby-sdk/Binaries/version.txt +1 -1
- data/lib/javonet-ruby-sdk/core/handler/load_library_handler.rb +22 -9
- data/lib/javonet-ruby-sdk/core/interpreter/interpreter.rb +1 -1
- data/lib/javonet-ruby-sdk/core/receiver/receiver_new.rb +3 -3
- data/lib/javonet-ruby-sdk/sdk/config_runtime_factory.rb +8 -0
- data/lib/javonet-ruby-sdk/utils/exceptions/exception_serializer.rb +0 -1
- data/lib/javonet-ruby-sdk/utils/runtime_logger.rb +3 -0
- metadata +6 -2
|
@@ -22,13 +22,23 @@ __export(ActivatorDetails_exports, {
|
|
|
22
22
|
});
|
|
23
23
|
module.exports = __toCommonJS(ActivatorDetails_exports);
|
|
24
24
|
class ActivatorDetails {
|
|
25
|
+
/** @type {Function} */
|
|
26
|
+
Type;
|
|
27
|
+
/** @type {any[]} */
|
|
28
|
+
arguments;
|
|
25
29
|
/**
|
|
26
30
|
* @param {Function} type - The constructor function/class
|
|
27
|
-
* @param {any[]} [args] - Arguments to pass to constructor
|
|
31
|
+
* @param {any[]|any} [args] - Arguments to pass to constructor (array or single value)
|
|
28
32
|
*/
|
|
29
33
|
constructor(type, args = []) {
|
|
30
|
-
this.
|
|
31
|
-
|
|
34
|
+
this.Type = type;
|
|
35
|
+
if (args == null) {
|
|
36
|
+
this.arguments = [];
|
|
37
|
+
} else if (Array.isArray(args)) {
|
|
38
|
+
this.arguments = args;
|
|
39
|
+
} else {
|
|
40
|
+
this.arguments = [args];
|
|
41
|
+
}
|
|
32
42
|
}
|
|
33
43
|
}
|
|
34
44
|
// Annotate the CommonJS export names for ESM import in node:
|
|
@@ -105,6 +105,15 @@ class ConfigRuntimeFactory {
|
|
|
105
105
|
nodejs(configName = "default") {
|
|
106
106
|
return this.#getRuntimeContext(import_RuntimeName.RuntimeName.Nodejs, configName);
|
|
107
107
|
}
|
|
108
|
+
/**
|
|
109
|
+
* Creates RuntimeContext instance to interact with the Php runtime.
|
|
110
|
+
* @param {string} [configName="default"] - The name of the configuration to use (optional).
|
|
111
|
+
* @return {RuntimeContext} a RuntimeContext instance for the Php runtime
|
|
112
|
+
* @see [Javonet Guides](https://www.javonet.com/guides/v2/javascript/foundations/runtime-context)
|
|
113
|
+
*/
|
|
114
|
+
php(configName = "default") {
|
|
115
|
+
return this.#getRuntimeContext(import_RuntimeName.RuntimeName.Php, configName);
|
|
116
|
+
}
|
|
108
117
|
/**
|
|
109
118
|
* Creates RuntimeContext instance to interact with the Python 2.7 runtime.
|
|
110
119
|
* @param {string} [configName="default"] - The name of the configuration to use (optional).
|
|
@@ -18,8 +18,7 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
18
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
19
|
var InvocationContext_exports = {};
|
|
20
20
|
__export(InvocationContext_exports, {
|
|
21
|
-
InvocationContext: () => InvocationContext
|
|
22
|
-
InvocationWsContext: () => InvocationWsContext
|
|
21
|
+
InvocationContext: () => InvocationContext
|
|
23
22
|
});
|
|
24
23
|
module.exports = __toCommonJS(InvocationContext_exports);
|
|
25
24
|
var import_DelegatesCache = require("../core/delegatesCache/DelegatesCache.cjs");
|
|
@@ -37,7 +36,7 @@ class InvocationContext {
|
|
|
37
36
|
#connectionData;
|
|
38
37
|
/** @type {Command | null} */
|
|
39
38
|
#currentCommand = null;
|
|
40
|
-
/** @type {Command |
|
|
39
|
+
/** @type {Command | null} */
|
|
41
40
|
#responseCommand = null;
|
|
42
41
|
/** @type {boolean} */
|
|
43
42
|
#isExecuted = false;
|
|
@@ -63,13 +62,6 @@ class InvocationContext {
|
|
|
63
62
|
* @returns {InvocationContext}
|
|
64
63
|
*/
|
|
65
64
|
#createInstanceContext(localCommand) {
|
|
66
|
-
if (this.#connectionData.connectionType === import_ConnectionType.ConnectionType.WEB_SOCKET) {
|
|
67
|
-
return new InvocationWsContext(
|
|
68
|
-
this.#runtimeName,
|
|
69
|
-
this.#connectionData,
|
|
70
|
-
this.#buildCommand(localCommand)
|
|
71
|
-
);
|
|
72
|
-
}
|
|
73
65
|
return new InvocationContext(
|
|
74
66
|
this.#runtimeName,
|
|
75
67
|
this.#connectionData,
|
|
@@ -92,30 +84,21 @@ class InvocationContext {
|
|
|
92
84
|
// this.execute();
|
|
93
85
|
// }
|
|
94
86
|
//}
|
|
95
|
-
|
|
87
|
+
/**
|
|
88
|
+
* Async iterator for InvocationContext arrays
|
|
89
|
+
* Use: for await (const item of invocationContext) { ... }
|
|
90
|
+
* @returns {AsyncGenerator<InvocationContext, void, unknown>}
|
|
91
|
+
*/
|
|
92
|
+
async *[Symbol.asyncIterator]() {
|
|
96
93
|
if (this.#currentCommand?.commandType !== import_CommandType.CommandType.Reference) {
|
|
97
94
|
throw new Error("Object is not iterable");
|
|
98
95
|
}
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
this.getSize().execute()
|
|
104
|
-
);
|
|
105
|
-
if (sizeCtx instanceof Promise) {
|
|
106
|
-
sizeCtx.then((ctx) => {
|
|
107
|
-
arraySize = Number(ctx.getValue());
|
|
108
|
-
});
|
|
109
|
-
} else {
|
|
110
|
-
arraySize = Number(sizeCtx.getValue());
|
|
96
|
+
const sizeCtx = await this.getSize().execute();
|
|
97
|
+
const arraySize = Number(sizeCtx.getValue());
|
|
98
|
+
for (let position = 0; position < arraySize; position++) {
|
|
99
|
+
yield this.getIndex(position);
|
|
111
100
|
}
|
|
112
|
-
|
|
113
|
-
next: () => ({
|
|
114
|
-
value: this.getIndex(++position),
|
|
115
|
-
done: position >= arraySize
|
|
116
|
-
})
|
|
117
|
-
};
|
|
118
|
-
};
|
|
101
|
+
}
|
|
119
102
|
/**
|
|
120
103
|
* Executes the current command.
|
|
121
104
|
* Because invocation context is building the intent of executing particular expression on target environment, we call the initial state of invocation context as non-materialized.
|
|
@@ -123,37 +106,30 @@ class InvocationContext {
|
|
|
123
106
|
* Commands are becoming nested through each invocation of methods on Invocation Context.
|
|
124
107
|
* Each invocation triggers the creation of new Invocation Context instance wrapping the current command with new parent command valid for invoked method.
|
|
125
108
|
* Developer can decide on any moment of the materialization for the context taking full control of the chunks of the expression being transferred and processed on target runtime.
|
|
126
|
-
* @returns {Promise<InvocationContext>
|
|
109
|
+
* @returns {Promise<InvocationContext>} the InvocationContext after executing the command.
|
|
127
110
|
* @see [Javonet Guides](https://www.javonet.com/guides/v2/javascript/foundations/execute-method)
|
|
128
111
|
* @method
|
|
129
112
|
*/
|
|
130
|
-
execute() {
|
|
113
|
+
async execute() {
|
|
131
114
|
if (this.#currentCommand === null) {
|
|
132
115
|
throw new Error("currentCommand is undefined in Invocation Context execute method");
|
|
133
116
|
}
|
|
134
117
|
if (!this.#interpreter) {
|
|
135
118
|
this.#interpreter = new import_Interpreter.Interpreter();
|
|
136
119
|
}
|
|
137
|
-
this.#responseCommand = this.#interpreter.execute(this.#currentCommand, this.#connectionData);
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
throw new Error("responseCommand is undefined in Invocation Context execute method");
|
|
141
|
-
}
|
|
142
|
-
if (resolvedResponse.commandType === import_CommandType.CommandType.Exception) {
|
|
143
|
-
throw import_ExceptionThrower.ExceptionThrower.throwException(resolvedResponse);
|
|
144
|
-
}
|
|
145
|
-
if (resolvedResponse.commandType === import_CommandType.CommandType.CreateClassInstance) {
|
|
146
|
-
this.#currentCommand = resolvedResponse;
|
|
147
|
-
this.#isExecuted = true;
|
|
148
|
-
return this;
|
|
149
|
-
}
|
|
150
|
-
return new InvocationContext(this.#runtimeName, this.#connectionData, resolvedResponse, true);
|
|
151
|
-
};
|
|
152
|
-
if (this.#responseCommand instanceof Promise) {
|
|
153
|
-
return this.#responseCommand.then(handleResponse);
|
|
154
|
-
} else {
|
|
155
|
-
return handleResponse(this.#responseCommand);
|
|
120
|
+
this.#responseCommand = await this.#interpreter.execute(this.#currentCommand, this.#connectionData);
|
|
121
|
+
if (!this.#responseCommand) {
|
|
122
|
+
throw new Error("responseCommand is undefined in Invocation Context execute method");
|
|
156
123
|
}
|
|
124
|
+
if (this.#responseCommand.commandType === import_CommandType.CommandType.Exception) {
|
|
125
|
+
throw import_ExceptionThrower.ExceptionThrower.throwException(this.#responseCommand);
|
|
126
|
+
}
|
|
127
|
+
if (this.#responseCommand.commandType === import_CommandType.CommandType.CreateClassInstance) {
|
|
128
|
+
this.#currentCommand = this.#responseCommand;
|
|
129
|
+
this.#isExecuted = true;
|
|
130
|
+
return this;
|
|
131
|
+
}
|
|
132
|
+
return new InvocationContext(this.#runtimeName, this.#connectionData, this.#responseCommand, true);
|
|
157
133
|
}
|
|
158
134
|
/**
|
|
159
135
|
* Invokes a static method on the target runtime.
|
|
@@ -376,7 +352,7 @@ class InvocationContext {
|
|
|
376
352
|
* Creates a null object of a specific type on the target runtime.
|
|
377
353
|
* @param {string} methodName - The name of the method to invoke.
|
|
378
354
|
* @param {...any} args - Method arguments.
|
|
379
|
-
* @returns {InvocationContext
|
|
355
|
+
* @returns {InvocationContext} An InvocationContext instance with the command to create a null object.
|
|
380
356
|
* TODO: connect documentation page url
|
|
381
357
|
* @see [Javonet Guides](https://www.javonet.com/guides/)
|
|
382
358
|
* @method
|
|
@@ -390,26 +366,19 @@ class InvocationContext {
|
|
|
390
366
|
}
|
|
391
367
|
/**
|
|
392
368
|
* Retrieves the type of the object from the target runtime.
|
|
393
|
-
* @returns {Promise<string>
|
|
369
|
+
* @returns {Promise<string>} The type of the object.
|
|
394
370
|
* @see [Javonet Guides](https://www.javonet.com/guides/v2/javascript/type-handling/getting-object-type)
|
|
395
371
|
* @method
|
|
396
372
|
*/
|
|
397
|
-
getResultType() {
|
|
373
|
+
async getResultType() {
|
|
398
374
|
const localCommand = new import_Command.Command(this.#runtimeName, import_CommandType.CommandType.GetResultType, []);
|
|
399
375
|
const invocationContext = new InvocationContext(
|
|
400
376
|
this.#runtimeName,
|
|
401
377
|
this.#connectionData,
|
|
402
378
|
this.#buildCommand(localCommand)
|
|
403
379
|
);
|
|
404
|
-
const execCtx = (
|
|
405
|
-
|
|
406
|
-
invocationContext.execute()
|
|
407
|
-
);
|
|
408
|
-
const result = execCtx.getValue();
|
|
409
|
-
return (
|
|
410
|
-
/** @type {string} */
|
|
411
|
-
result
|
|
412
|
-
);
|
|
380
|
+
const execCtx = await invocationContext.execute();
|
|
381
|
+
return String(execCtx.getValue());
|
|
413
382
|
}
|
|
414
383
|
/**
|
|
415
384
|
* Retrieves the name of the runtime where the command is executed.
|
|
@@ -422,21 +391,33 @@ class InvocationContext {
|
|
|
422
391
|
}
|
|
423
392
|
/**
|
|
424
393
|
* Retrieves an array from the target runtime.
|
|
394
|
+
* @async
|
|
425
395
|
* @returns {Promise<any[]>}
|
|
426
396
|
* @method
|
|
427
397
|
*/
|
|
428
|
-
retrieveArray() {
|
|
398
|
+
async retrieveArray() {
|
|
429
399
|
const localCommand = new import_Command.Command(this.#runtimeName, import_CommandType.CommandType.RetrieveArray, []);
|
|
430
400
|
const localInvCtx = new InvocationContext(
|
|
431
401
|
this.#runtimeName,
|
|
432
402
|
this.#connectionData,
|
|
433
403
|
this.#buildCommand(localCommand)
|
|
434
404
|
);
|
|
435
|
-
localInvCtx.execute();
|
|
436
|
-
const
|
|
437
|
-
return
|
|
405
|
+
await localInvCtx.execute();
|
|
406
|
+
const resolve = (item) => {
|
|
407
|
+
return item?.commandType === import_CommandType.CommandType.Reference ? new InvocationContext(
|
|
408
|
+
this.#runtimeName,
|
|
409
|
+
this.#connectionData,
|
|
410
|
+
item
|
|
411
|
+
) : item;
|
|
438
412
|
};
|
|
439
|
-
|
|
413
|
+
const respCommand = localInvCtx.#responseCommand;
|
|
414
|
+
if (!respCommand) {
|
|
415
|
+
return [];
|
|
416
|
+
}
|
|
417
|
+
if (respCommand.payload) {
|
|
418
|
+
return respCommand.payload.map((item) => resolve(item));
|
|
419
|
+
}
|
|
420
|
+
return respCommand.payload || [];
|
|
440
421
|
}
|
|
441
422
|
/**
|
|
442
423
|
* Returns the primitive value from the target runtime. This could be any primitive type in JavaScript,
|
|
@@ -478,136 +459,8 @@ class InvocationContext {
|
|
|
478
459
|
for (let i = 0; i < newArray.length; i++) {
|
|
479
460
|
newArray[i] = typeof Object;
|
|
480
461
|
}
|
|
481
|
-
const args = [import_DelegatesCache.delegatesCacheInstance.addDelegate(payloadItem), import_RuntimeName.RuntimeName.Nodejs]
|
|
482
|
-
|
|
483
|
-
);
|
|
484
|
-
return new import_Command.Command(this.#runtimeName, import_CommandType.CommandType.PassDelegate, args);
|
|
485
|
-
} else if (import_TypesHandler.TypesHandler.isPrimitiveOrNullOrUndefined(payloadItem)) {
|
|
486
|
-
return new import_Command.Command(this.#runtimeName, import_CommandType.CommandType.Value, [payloadItem]);
|
|
487
|
-
} else {
|
|
488
|
-
throw Error(
|
|
489
|
-
"Unsupported payload item type: " + (payloadItem?.constructor?.name || typeof payloadItem) + " for payload item: " + payloadItem
|
|
490
|
-
);
|
|
491
|
-
}
|
|
492
|
-
}
|
|
493
|
-
}
|
|
494
|
-
class InvocationWsContext extends InvocationContext {
|
|
495
|
-
/** @type {RuntimeNameType} */
|
|
496
|
-
#runtimeName;
|
|
497
|
-
/** @type {IConnectionData} */
|
|
498
|
-
#connectionData;
|
|
499
|
-
/** @type {Command | null} */
|
|
500
|
-
#currentCommand;
|
|
501
|
-
/** @type {Command | null} */
|
|
502
|
-
#responseCommand;
|
|
503
|
-
/** @type {Interpreter | null} */
|
|
504
|
-
#interpreter;
|
|
505
|
-
/** @type {boolean} */
|
|
506
|
-
#isExecuted;
|
|
507
|
-
/**
|
|
508
|
-
* @param {RuntimeNameType} runtimeName
|
|
509
|
-
* @param {IConnectionData} connectionData
|
|
510
|
-
* @param {Command} command
|
|
511
|
-
* @param {boolean} isExecuted
|
|
512
|
-
*/
|
|
513
|
-
constructor(runtimeName, connectionData, command, isExecuted = false) {
|
|
514
|
-
super(runtimeName, connectionData, command, isExecuted);
|
|
515
|
-
this.#runtimeName = runtimeName;
|
|
516
|
-
this.#connectionData = connectionData;
|
|
517
|
-
this.#currentCommand = command;
|
|
518
|
-
this.#responseCommand = null;
|
|
519
|
-
this.#isExecuted = isExecuted;
|
|
520
|
-
this.#interpreter = null;
|
|
521
|
-
}
|
|
522
|
-
/**
|
|
523
|
-
* Executes the current command.
|
|
524
|
-
* Because invocation context is building the intent of executing particular expression on target environment, we call the initial state of invocation context as non-materialized.
|
|
525
|
-
* The non-materialized context wraps either single command or chain of recursively nested commands.
|
|
526
|
-
* Commands are becoming nested through each invocation of methods on Invocation Context.
|
|
527
|
-
* Each invocation triggers the creation of new Invocation Context instance wrapping the current command with new parent command valid for invoked method.
|
|
528
|
-
* Developer can decide on any moment of the materialization for the context taking full control of the chunks of the expression being transferred and processed on target runtime.
|
|
529
|
-
* @returns {Promise<InvocationWsContext>} the InvocationContext after executing the command.
|
|
530
|
-
* @see [Javonet Guides](https://www.javonet.com/guides/v2/javascript/foundations/execute-method)
|
|
531
|
-
* @async
|
|
532
|
-
* @method
|
|
533
|
-
*/
|
|
534
|
-
async execute() {
|
|
535
|
-
if (this.#currentCommand === null) {
|
|
536
|
-
throw new Error("currentCommand is undefined in Invocation Context execute method");
|
|
537
|
-
}
|
|
538
|
-
if (!this.#interpreter) {
|
|
539
|
-
this.#interpreter = new import_Interpreter.Interpreter();
|
|
540
|
-
}
|
|
541
|
-
this.#responseCommand = await this.#interpreter.executeAsync(
|
|
542
|
-
this.#currentCommand,
|
|
543
|
-
this.#connectionData
|
|
544
|
-
);
|
|
545
|
-
if (this.#responseCommand === void 0) {
|
|
546
|
-
throw new Error("responseCommand is undefined in Invocation Context execute method");
|
|
547
|
-
}
|
|
548
|
-
if (this.#responseCommand.commandType === import_CommandType.CommandType.Exception) {
|
|
549
|
-
throw import_ExceptionThrower.ExceptionThrower.throwException(this.#responseCommand);
|
|
550
|
-
}
|
|
551
|
-
if (this.#responseCommand.commandType === import_CommandType.CommandType.CreateClassInstance) {
|
|
552
|
-
this.#currentCommand = this.#responseCommand;
|
|
553
|
-
this.#isExecuted = true;
|
|
554
|
-
return this;
|
|
555
|
-
}
|
|
556
|
-
return new InvocationWsContext(this.#runtimeName, this.#connectionData, this.#responseCommand, true);
|
|
557
|
-
}
|
|
558
|
-
/**
|
|
559
|
-
* Retrieves the type of the object from the target runtime.
|
|
560
|
-
* @returns {Promise<string>} The type of the object.
|
|
561
|
-
* @see [Javonet Guides](https://www.javonet.com/guides/v2/javascript/type-handling/getting-object-type)
|
|
562
|
-
* @async
|
|
563
|
-
* @method
|
|
564
|
-
*/
|
|
565
|
-
async getResultType() {
|
|
566
|
-
const localCommand = new import_Command.Command(this.#runtimeName, import_CommandType.CommandType.GetResultType, []);
|
|
567
|
-
const invocationContext = new InvocationWsContext(
|
|
568
|
-
this.#runtimeName,
|
|
569
|
-
this.#connectionData,
|
|
570
|
-
this.#buildCommand(localCommand)
|
|
571
|
-
);
|
|
572
|
-
const result = await invocationContext.execute();
|
|
573
|
-
return (
|
|
574
|
-
/** @type {string} */
|
|
575
|
-
result.getValue()
|
|
576
|
-
);
|
|
577
|
-
}
|
|
578
|
-
/**
|
|
579
|
-
* @param {Command} command
|
|
580
|
-
* @returns {Command}
|
|
581
|
-
*/
|
|
582
|
-
#buildCommand(command) {
|
|
583
|
-
for (let i = 0; i < command.payload.length; i++) {
|
|
584
|
-
command.payload[i] = this.#encapsulatePayloadItem(command.payload[i]);
|
|
585
|
-
}
|
|
586
|
-
return command.prependArgToPayload(this.#currentCommand);
|
|
587
|
-
}
|
|
588
|
-
/**
|
|
589
|
-
* @param {unknown} payloadItem
|
|
590
|
-
* @returns {Command|null}
|
|
591
|
-
*/
|
|
592
|
-
#encapsulatePayloadItem(payloadItem) {
|
|
593
|
-
if (payloadItem instanceof import_Command.Command) {
|
|
594
|
-
for (let i = 0; i < payloadItem.payload.length; i++) {
|
|
595
|
-
payloadItem.payload[i] = this.#encapsulatePayloadItem(payloadItem.payload[i]);
|
|
596
|
-
}
|
|
597
|
-
return payloadItem;
|
|
598
|
-
} else if (payloadItem instanceof InvocationContext || payloadItem instanceof InvocationWsContext) {
|
|
599
|
-
return payloadItem.get_current_command();
|
|
600
|
-
} else if (payloadItem instanceof Array) {
|
|
601
|
-
const copiedArray = payloadItem.map((item) => this.#encapsulatePayloadItem(item));
|
|
602
|
-
return new import_Command.Command(this.#runtimeName, import_CommandType.CommandType.Array, copiedArray);
|
|
603
|
-
} else if (typeof payloadItem === "function") {
|
|
604
|
-
let newArray = new Array(payloadItem.length + 1);
|
|
605
|
-
for (let i = 0; i < newArray.length; i++) {
|
|
606
|
-
newArray[i] = typeof Object;
|
|
607
|
-
}
|
|
608
|
-
const args = [import_DelegatesCache.delegatesCacheInstance.addDelegate(payloadItem), import_RuntimeName.RuntimeName.Nodejs].push(
|
|
609
|
-
...newArray
|
|
610
|
-
);
|
|
462
|
+
const args = [import_DelegatesCache.delegatesCacheInstance.addDelegate(payloadItem), import_RuntimeName.RuntimeName.Nodejs];
|
|
463
|
+
args.push(...newArray);
|
|
611
464
|
return new import_Command.Command(this.#runtimeName, import_CommandType.CommandType.PassDelegate, args);
|
|
612
465
|
} else if (import_TypesHandler.TypesHandler.isPrimitiveOrNullOrUndefined(payloadItem)) {
|
|
613
466
|
return new import_Command.Command(this.#runtimeName, import_CommandType.CommandType.Value, [payloadItem]);
|
|
@@ -620,6 +473,5 @@ class InvocationWsContext extends InvocationContext {
|
|
|
620
473
|
}
|
|
621
474
|
// Annotate the CommonJS export names for ESM import in node:
|
|
622
475
|
0 && (module.exports = {
|
|
623
|
-
InvocationContext
|
|
624
|
-
InvocationWsContext
|
|
476
|
+
InvocationContext
|
|
625
477
|
});
|
|
@@ -20,6 +20,7 @@ var Javonet_exports = {};
|
|
|
20
20
|
__export(Javonet_exports, {
|
|
21
21
|
CommandDeserializer: () => import_CommandDeserializer.CommandDeserializer,
|
|
22
22
|
CommandSerializer: () => import_CommandSerializer.CommandSerializer,
|
|
23
|
+
ComplexTypeResolver: () => import_ComplexTypeResolver.ComplexTypeResolver,
|
|
23
24
|
ConfigPriority: () => import_ConfigPriority.ConfigPriority,
|
|
24
25
|
Javonet: () => Javonet,
|
|
25
26
|
TcpConnectionData: () => import_TcpConnectionData.TcpConnectionData,
|
|
@@ -39,17 +40,7 @@ var import_WsConnectionData = require("../utils/connectionData/WsConnectionData.
|
|
|
39
40
|
var import_UtilsConst = require("../utils/UtilsConst.cjs");
|
|
40
41
|
var import_ConfigSourceResolver = require("./configuration/ConfigSourceResolver.cjs");
|
|
41
42
|
var import_ConfigPriority = require("./configuration/ConfigPriority.cjs");
|
|
42
|
-
|
|
43
|
-
const requireDynamic = (0, import_Runtime.getRequire)(import_meta.url);
|
|
44
|
-
let _Transmitter = null;
|
|
45
|
-
if ((0, import_Runtime.isNodejsRuntime)()) {
|
|
46
|
-
try {
|
|
47
|
-
const { Transmitter } = require("../core/transmitter/Transmitter.cjs");
|
|
48
|
-
_Transmitter = Transmitter;
|
|
49
|
-
} catch (error) {
|
|
50
|
-
throw error;
|
|
51
|
-
}
|
|
52
|
-
}
|
|
43
|
+
var import_ComplexTypeResolver = require("./tools/ComplexTypeResolver.cjs");
|
|
53
44
|
class Javonet {
|
|
54
45
|
/**
|
|
55
46
|
* Initializes Javonet using an in-memory channel on the same machine.
|
|
@@ -145,6 +136,7 @@ class Javonet {
|
|
|
145
136
|
0 && (module.exports = {
|
|
146
137
|
CommandDeserializer,
|
|
147
138
|
CommandSerializer,
|
|
139
|
+
ComplexTypeResolver,
|
|
148
140
|
ConfigPriority,
|
|
149
141
|
Javonet,
|
|
150
142
|
TcpConnectionData,
|
|
@@ -75,6 +75,9 @@ class RuntimeContext {
|
|
|
75
75
|
* @returns {RuntimeContext}
|
|
76
76
|
*/
|
|
77
77
|
static getInstance(runtimeName, connectionData) {
|
|
78
|
+
if (!(0, import_Runtime.isNodejsRuntime)() && connectionData.connectionType === import_ConnectionType.ConnectionType.IN_MEMORY) {
|
|
79
|
+
throw new Error("Nodejs Core Error: inMemory is only allowed in Nodejs runtime, not in browser");
|
|
80
|
+
}
|
|
78
81
|
switch (connectionData.connectionType) {
|
|
79
82
|
case import_ConnectionType.ConnectionType.IN_MEMORY:
|
|
80
83
|
const key = String(runtimeName);
|
|
@@ -133,10 +136,11 @@ class RuntimeContext {
|
|
|
133
136
|
* Each invocation triggers the creation of a new RuntimeContext instance wrapping the current command with a new parent command.
|
|
134
137
|
* The developer can decide at any moment of the materialization for the context, taking full control of the chunks of the expression being transferred and processed on the target runtime.
|
|
135
138
|
* @see [Javonet Guides](https://www.javonet.com/guides/v2/javascript/foundations/execute-method)
|
|
139
|
+
* @returns {Promise<void>}
|
|
136
140
|
* @method
|
|
137
141
|
*/
|
|
138
|
-
execute() {
|
|
139
|
-
this.#responseCommand = this.#interpreter?.execute(this.#currentCommand, this.connectionData);
|
|
142
|
+
async execute() {
|
|
143
|
+
this.#responseCommand = await this.#interpreter?.execute(this.#currentCommand, this.connectionData);
|
|
140
144
|
this.#currentCommand = null;
|
|
141
145
|
if (this.#responseCommand === void 0) {
|
|
142
146
|
throw new Error("responseCommand is undefined in Runtime Context execute method");
|
|
@@ -151,14 +155,14 @@ class RuntimeContext {
|
|
|
151
155
|
* The argument is a relative or full path to the library. If the library has dependencies on other libraries, the latter needs to be added first.
|
|
152
156
|
* After referencing the library, any objects stored in this package can be used. Use static classes, create instances, call methods, use fields and properties, and much more.
|
|
153
157
|
* @param {string} libraryPath - The relative or full path to the library.
|
|
154
|
-
* @returns {RuntimeContext} RuntimeContext instance.
|
|
158
|
+
* @returns {Promise<RuntimeContext>} RuntimeContext instance.
|
|
155
159
|
* @see [Javonet Guides](https://www.javonet.com/guides/v2/javascript/getting-started/adding-references-to-libraries)
|
|
156
160
|
* @method
|
|
157
161
|
*/
|
|
158
|
-
loadLibrary(libraryPath) {
|
|
162
|
+
async loadLibrary(libraryPath) {
|
|
159
163
|
let localCommand = new import_Command.Command(this.runtimeName, import_CommandType.CommandType.LoadLibrary, [libraryPath]);
|
|
160
164
|
this.#currentCommand = this.#buildCommand(localCommand);
|
|
161
|
-
this.execute();
|
|
165
|
+
await this.execute();
|
|
162
166
|
return this;
|
|
163
167
|
}
|
|
164
168
|
/**
|
|
@@ -171,13 +175,6 @@ class RuntimeContext {
|
|
|
171
175
|
getType(typeName, ...args) {
|
|
172
176
|
let localCommand = new import_Command.Command(this.runtimeName, import_CommandType.CommandType.GetType, [typeName, ...args]);
|
|
173
177
|
this.#currentCommand = null;
|
|
174
|
-
if (this.connectionData.connectionType === import_ConnectionType.ConnectionType.WEB_SOCKET) {
|
|
175
|
-
return new import_InvocationContext.InvocationWsContext(
|
|
176
|
-
this.runtimeName,
|
|
177
|
-
this.connectionData,
|
|
178
|
-
this.#buildCommand(localCommand)
|
|
179
|
-
);
|
|
180
|
-
}
|
|
181
178
|
return new import_InvocationContext.InvocationContext(this.runtimeName, this.connectionData, this.#buildCommand(localCommand));
|
|
182
179
|
}
|
|
183
180
|
/**
|
|
@@ -192,13 +189,6 @@ class RuntimeContext {
|
|
|
192
189
|
cast(...args) {
|
|
193
190
|
let localCommand = new import_Command.Command(this.runtimeName, import_CommandType.CommandType.Cast, args);
|
|
194
191
|
this.#currentCommand = null;
|
|
195
|
-
if (this.connectionData.connectionType === import_ConnectionType.ConnectionType.WEB_SOCKET) {
|
|
196
|
-
return new import_InvocationContext.InvocationWsContext(
|
|
197
|
-
this.runtimeName,
|
|
198
|
-
this.connectionData,
|
|
199
|
-
this.#buildCommand(localCommand)
|
|
200
|
-
);
|
|
201
|
-
}
|
|
202
192
|
return new import_InvocationContext.InvocationContext(this.runtimeName, this.connectionData, this.#buildCommand(localCommand));
|
|
203
193
|
}
|
|
204
194
|
/**
|
|
@@ -213,13 +203,6 @@ class RuntimeContext {
|
|
|
213
203
|
getEnumItem(...args) {
|
|
214
204
|
let localCommand = new import_Command.Command(this.runtimeName, import_CommandType.CommandType.GetEnumItem, args);
|
|
215
205
|
this.#currentCommand = null;
|
|
216
|
-
if (this.connectionData.connectionType === import_ConnectionType.ConnectionType.WEB_SOCKET) {
|
|
217
|
-
return new import_InvocationContext.InvocationWsContext(
|
|
218
|
-
this.runtimeName,
|
|
219
|
-
this.connectionData,
|
|
220
|
-
this.#buildCommand(localCommand)
|
|
221
|
-
);
|
|
222
|
-
}
|
|
223
206
|
return new import_InvocationContext.InvocationContext(this.runtimeName, this.connectionData, this.#buildCommand(localCommand));
|
|
224
207
|
}
|
|
225
208
|
/**
|
|
@@ -234,13 +217,6 @@ class RuntimeContext {
|
|
|
234
217
|
asRef(...args) {
|
|
235
218
|
let localCommand = new import_Command.Command(this.runtimeName, import_CommandType.CommandType.AsRef, args);
|
|
236
219
|
this.#currentCommand = null;
|
|
237
|
-
if (this.connectionData.connectionType === import_ConnectionType.ConnectionType.WEB_SOCKET) {
|
|
238
|
-
return new import_InvocationContext.InvocationWsContext(
|
|
239
|
-
this.runtimeName,
|
|
240
|
-
this.connectionData,
|
|
241
|
-
this.#buildCommand(localCommand)
|
|
242
|
-
);
|
|
243
|
-
}
|
|
244
220
|
return new import_InvocationContext.InvocationContext(this.runtimeName, this.connectionData, this.#buildCommand(localCommand));
|
|
245
221
|
}
|
|
246
222
|
/**
|
|
@@ -255,13 +231,6 @@ class RuntimeContext {
|
|
|
255
231
|
asOut(...args) {
|
|
256
232
|
let localCommand = new import_Command.Command(this.runtimeName, import_CommandType.CommandType.AsOut, args);
|
|
257
233
|
this.#currentCommand = null;
|
|
258
|
-
if (this.connectionData.connectionType === import_ConnectionType.ConnectionType.WEB_SOCKET) {
|
|
259
|
-
return new import_InvocationContext.InvocationWsContext(
|
|
260
|
-
this.runtimeName,
|
|
261
|
-
this.connectionData,
|
|
262
|
-
this.#buildCommand(localCommand)
|
|
263
|
-
);
|
|
264
|
-
}
|
|
265
234
|
return new import_InvocationContext.InvocationContext(this.runtimeName, this.connectionData, this.#buildCommand(localCommand));
|
|
266
235
|
}
|
|
267
236
|
/**
|
|
@@ -274,13 +243,6 @@ class RuntimeContext {
|
|
|
274
243
|
getGlobalField(fieldName) {
|
|
275
244
|
let localCommand = new import_Command.Command(this.runtimeName, import_CommandType.CommandType.GetGlobalField, [fieldName]);
|
|
276
245
|
this.#currentCommand = null;
|
|
277
|
-
if (this.connectionData.connectionType === import_ConnectionType.ConnectionType.WEB_SOCKET) {
|
|
278
|
-
return new import_InvocationContext.InvocationWsContext(
|
|
279
|
-
this.runtimeName,
|
|
280
|
-
this.connectionData,
|
|
281
|
-
this.#buildCommand(localCommand)
|
|
282
|
-
);
|
|
283
|
-
}
|
|
284
246
|
return new import_InvocationContext.InvocationContext(this.runtimeName, this.connectionData, this.#buildCommand(localCommand));
|
|
285
247
|
}
|
|
286
248
|
/**
|
|
@@ -299,13 +261,6 @@ class RuntimeContext {
|
|
|
299
261
|
...args
|
|
300
262
|
]);
|
|
301
263
|
this.#currentCommand = null;
|
|
302
|
-
if (this.connectionData.connectionType === import_ConnectionType.ConnectionType.WEB_SOCKET) {
|
|
303
|
-
return new import_InvocationContext.InvocationWsContext(
|
|
304
|
-
this.runtimeName,
|
|
305
|
-
this.connectionData,
|
|
306
|
-
this.#buildCommand(localCommand)
|
|
307
|
-
);
|
|
308
|
-
}
|
|
309
264
|
return new import_InvocationContext.InvocationContext(this.runtimeName, this.connectionData, this.#buildCommand(localCommand));
|
|
310
265
|
}
|
|
311
266
|
/**
|
|
@@ -342,9 +297,8 @@ class RuntimeContext {
|
|
|
342
297
|
for (let i = 0; i < newArray.length; i++) {
|
|
343
298
|
newArray[i] = "object";
|
|
344
299
|
}
|
|
345
|
-
const args = [import_DelegatesCache.delegatesCacheInstance.addDelegate(payloadItem), import_RuntimeName.RuntimeName.Nodejs]
|
|
346
|
-
|
|
347
|
-
);
|
|
300
|
+
const args = [import_DelegatesCache.delegatesCacheInstance.addDelegate(payloadItem), import_RuntimeName.RuntimeName.Nodejs];
|
|
301
|
+
args.push(...newArray);
|
|
348
302
|
return new import_Command.Command(this.runtimeName, import_CommandType.CommandType.PassDelegate, args);
|
|
349
303
|
} else if (import_TypesHandler.TypesHandler.isPrimitiveOrNullOrUndefined(payloadItem)) {
|
|
350
304
|
return new import_Command.Command(this.runtimeName, import_CommandType.CommandType.Value, [payloadItem]);
|