javonet-ruby-sdk 2.4.8 → 2.4.9

Sign up to get free protection for your applications and to get access to all the features.
Files changed (219) hide show
  1. checksums.yaml +4 -4
  2. data/VERSION +1 -1
  3. data/lib/javonet-ruby-sdk/Binaries/Clr/Windows/X64/Javonet.Clr.Utils.dll +0 -0
  4. data/lib/javonet-ruby-sdk/Binaries/Clr/Windows/X64/JavonetClrRuntime.dll +0 -0
  5. data/lib/javonet-ruby-sdk/Binaries/Jvm/Linux/X64/JavonetJvmRuntime.jar +0 -0
  6. data/lib/javonet-ruby-sdk/Binaries/Jvm/MacOs/X64/JavonetJvmRuntime.jar +0 -0
  7. data/lib/javonet-ruby-sdk/Binaries/Jvm/Windows/X64/JavonetJvmRuntime.jar +0 -0
  8. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetActivationService.so +0 -0
  9. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetCppRuntimeNative.so +0 -0
  10. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetGoRuntimeNative.so +0 -0
  11. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetJvmRuntimeNative.so +0 -0
  12. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetNetcoreRuntimeNative.so +0 -0
  13. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetNodejs1816RuntimeNative.so +0 -0
  14. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetNodejsRuntimeNative.so +0 -0
  15. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetPerlRuntimeNative.so +0 -0
  16. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetPythonRuntimeNative.so +0 -0
  17. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetRuby278RuntimeNative.so +0 -0
  18. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetRubyRuntimeNative.so +0 -0
  19. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetTcpClient.so +0 -0
  20. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libJavonetTcpTlsClient.so +0 -0
  21. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libUtils.so +0 -0
  22. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/openssl3/libJavonetActivationService.so +0 -0
  23. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/openssl3/libJavonetTcpTlsClient.so +0 -0
  24. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/openssl3/libUtils.so +0 -0
  25. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/version.txt +1 -1
  26. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetActivationService.dylib +0 -0
  27. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetCppRuntimeNative.dylib +0 -0
  28. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetGoRuntimeNative.dylib +0 -0
  29. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetJvmRuntimeNative.dylib +0 -0
  30. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetNetcoreRuntimeNative.dylib +0 -0
  31. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetNodejs1816RuntimeNative.dylib +0 -0
  32. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetNodejsRuntimeNative.dylib +0 -0
  33. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetPerlRuntimeNative.dylib +0 -0
  34. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetPythonRuntimeNative.dylib +0 -0
  35. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetRuby278RuntimeNative.dylib +0 -0
  36. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetRubyRuntimeNative.dylib +0 -0
  37. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetTcpClient.dylib +0 -0
  38. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libJavonetTcpTlsClient.dylib +0 -0
  39. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libUtils.dylib +0 -0
  40. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/version.txt +1 -1
  41. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetActivationService.dll +0 -0
  42. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetClrRuntimeNative.dll +0 -0
  43. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetCppRuntimeNative.dll +0 -0
  44. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetGoRuntimeNative.dll +0 -0
  45. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetJvmRuntimeNative.dll +0 -0
  46. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetNetcoreRuntimeNative.dll +0 -0
  47. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetNodejs1816RuntimeNative.dll +0 -0
  48. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetNodejsRuntimeNative.dll +0 -0
  49. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetPerlRuntimeNative.dll +0 -0
  50. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetPythonRuntimeNative.dll +0 -0
  51. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetRuby278RuntimeNative.dll +0 -0
  52. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetRubyRuntimeNative.dll +0 -0
  53. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetTcpClient.dll +0 -0
  54. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/JavonetTcpTlsClient.dll +0 -0
  55. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/Utils.dll +0 -0
  56. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/version.txt +1 -1
  57. data/lib/javonet-ruby-sdk/Binaries/Netcore/Linux/X64/Javonet.Netcore.Core.dll +0 -0
  58. data/lib/javonet-ruby-sdk/Binaries/Netcore/Linux/X64/Javonet.Netcore.Utils.dll +0 -0
  59. data/lib/javonet-ruby-sdk/Binaries/Netcore/MacOs/X64/Javonet.Netcore.Core.dll +0 -0
  60. data/lib/javonet-ruby-sdk/Binaries/Netcore/MacOs/X64/Javonet.Netcore.Utils.dll +0 -0
  61. data/lib/javonet-ruby-sdk/Binaries/Netcore/Windows/X64/Javonet.Netcore.Core.dll +0 -0
  62. data/lib/javonet-ruby-sdk/Binaries/Netcore/Windows/X64/Javonet.Netcore.Utils.dll +0 -0
  63. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/ExtUtils/Helpers/Unix.pm +2 -2
  64. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/ExtUtils/Helpers/VMS.pm +2 -2
  65. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/ExtUtils/Helpers/Windows.pm +2 -2
  66. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/ExtUtils/Helpers.pm +10 -8
  67. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/ExtUtils/InstallPaths.pm +9 -7
  68. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/Module/Build/Tiny.pm +2 -2
  69. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/Nice/Try.pm +146 -23
  70. 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
  71. 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
  72. 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
  73. 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
  74. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/auto/Moose/Moose.so +0 -0
  75. 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
  76. 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
  77. 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
  78. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/auto/Want/Want.so +0 -0
  79. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/auto/autobox/autobox.so +0 -0
  80. 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
  81. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/autobox.pm +2 -2
  82. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/autobox.pod +27 -26
  83. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/x86_64-linux-gnu-thread-multi/perllocal.pod +88 -154
  84. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/ExtUtils/Helpers/Unix.pm +2 -2
  85. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/ExtUtils/Helpers/VMS.pm +2 -2
  86. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/ExtUtils/Helpers/Windows.pm +2 -2
  87. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/ExtUtils/Helpers.pm +10 -8
  88. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/ExtUtils/InstallPaths.pm +9 -7
  89. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/Module/Build/Tiny.pm +2 -2
  90. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/Nice/Try.pm +146 -23
  91. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/darwin-thread-multi-2level/auto/Package/Stash/XS/XS.bundle +0 -0
  92. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/darwin-thread-multi-2level/auto/autobox/autobox.bundle +0 -0
  93. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/darwin-thread-multi-2level/autobox.pm +2 -2
  94. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/darwin-thread-multi-2level/autobox.pod +27 -26
  95. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/darwin-thread-multi-2level/perllocal.pod +82 -148
  96. data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/MSWin32-x64-multi-thread/auto/Data/UUID/UUID.xs.dll +0 -0
  97. data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/MSWin32-x64-multi-thread/auto/PPI/XS/XS.xs.dll +0 -0
  98. 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
  99. data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/MSWin32-x64-multi-thread/auto/Want/Want.xs.dll +0 -0
  100. data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/MSWin32-x64-multi-thread/auto/autobox/autobox.xs.dll +0 -0
  101. data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/MSWin32-x64-multi-thread/autobox.pm +2 -2
  102. data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/MSWin32-x64-multi-thread/autobox.pod +27 -26
  103. data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/MSWin32-x64-multi-thread/perllocal.pod +40 -18
  104. data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/Nice/Try.pm +146 -23
  105. data/lib/javonet-ruby-sdk/Binaries/Perl/Windows/X64/deps/lib/perl5/Test/Fatal.pm +477 -0
  106. data/lib/javonet-ruby-sdk/Binaries/Python/Linux/X64/javonet/core/interpreter/Interpreter.py +11 -9
  107. data/lib/javonet-ruby-sdk/Binaries/Python/Linux/X64/javonet/core/protocol/CommandSerializer.py +3 -16
  108. data/lib/javonet-ruby-sdk/Binaries/Python/Linux/X64/javonet/core/receiver/Receiver.py +3 -1
  109. data/lib/javonet-ruby-sdk/Binaries/Python/Linux/X64/javonet/core/referenceCache/ReferencesCache.py +2 -1
  110. data/lib/javonet-ruby-sdk/Binaries/Python/Linux/X64/javonet/core/transmitter/Transmitter.py +2 -14
  111. data/lib/javonet-ruby-sdk/Binaries/Python/Linux/X64/javonet/core/webSocketClient/WebSocketClient.py +32 -0
  112. data/lib/javonet-ruby-sdk/Binaries/Python/Linux/X64/javonet/utils/ConnectionType.py +1 -0
  113. data/lib/javonet-ruby-sdk/Binaries/Python/Linux/X64/javonet/utils/connectionData/IConnectionData.py +18 -0
  114. data/lib/javonet-ruby-sdk/Binaries/Python/Linux/X64/javonet/utils/connectionData/InMemoryConnectionData.py +23 -0
  115. data/lib/javonet-ruby-sdk/Binaries/Python/Linux/X64/javonet/utils/connectionData/TcpConnectionData.py +67 -0
  116. data/lib/javonet-ruby-sdk/Binaries/Python/Linux/X64/javonet/utils/connectionData/WsConnectionData.py +30 -0
  117. data/lib/javonet-ruby-sdk/Binaries/Python/Linux/X64/javonet/utils/connectionData/__init__.py +0 -0
  118. data/lib/javonet-ruby-sdk/Binaries/Python/MacOs/X64/javonet/core/interpreter/Interpreter.py +11 -9
  119. data/lib/javonet-ruby-sdk/Binaries/Python/MacOs/X64/javonet/core/protocol/CommandSerializer.py +3 -16
  120. data/lib/javonet-ruby-sdk/Binaries/Python/MacOs/X64/javonet/core/receiver/Receiver.py +3 -1
  121. data/lib/javonet-ruby-sdk/Binaries/Python/MacOs/X64/javonet/core/referenceCache/ReferencesCache.py +2 -1
  122. data/lib/javonet-ruby-sdk/Binaries/Python/MacOs/X64/javonet/core/transmitter/Transmitter.py +2 -14
  123. data/lib/javonet-ruby-sdk/Binaries/Python/MacOs/X64/javonet/core/webSocketClient/WebSocketClient.py +32 -0
  124. data/lib/javonet-ruby-sdk/Binaries/Python/MacOs/X64/javonet/utils/ConnectionType.py +1 -0
  125. data/lib/javonet-ruby-sdk/Binaries/Python/MacOs/X64/javonet/utils/connectionData/IConnectionData.py +18 -0
  126. data/lib/javonet-ruby-sdk/Binaries/Python/MacOs/X64/javonet/utils/connectionData/InMemoryConnectionData.py +23 -0
  127. data/lib/javonet-ruby-sdk/Binaries/Python/MacOs/X64/javonet/utils/connectionData/TcpConnectionData.py +67 -0
  128. data/lib/javonet-ruby-sdk/Binaries/Python/MacOs/X64/javonet/utils/connectionData/WsConnectionData.py +30 -0
  129. data/lib/javonet-ruby-sdk/Binaries/Python/MacOs/X64/javonet/utils/connectionData/__init__.py +0 -0
  130. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/__pycache__/__init__.cpython-311.pyc +0 -0
  131. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/generator/__pycache__/__init__.cpython-311.pyc +0 -0
  132. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/generator/internal/__pycache__/PythonStringBuilder.cpython-311.pyc +0 -0
  133. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/generator/internal/__pycache__/__init__.cpython-311.pyc +0 -0
  134. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/AbstractCommandHandler.cpython-311.pyc +0 -0
  135. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/AbstractHandler.cpython-311.pyc +0 -0
  136. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/ArrayGetItemHandler.cpython-311.pyc +0 -0
  137. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/ArrayGetRankHandler.cpython-311.pyc +0 -0
  138. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/ArrayGetSizeHandler.cpython-311.pyc +0 -0
  139. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/ArrayHandler.cpython-311.pyc +0 -0
  140. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/ArraySetItemHandler.cpython-311.pyc +0 -0
  141. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/CastingHandler.cpython-311.pyc +0 -0
  142. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/CreateClassInstanceHandler.cpython-311.pyc +0 -0
  143. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/DestructReferenceHandler.cpython-311.pyc +0 -0
  144. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/EnableNamespaceHandler.cpython-311.pyc +0 -0
  145. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/EnableTypeHandler.cpython-311.pyc +0 -0
  146. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/GetEnumItemHandler.cpython-311.pyc +0 -0
  147. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/GetEnumNameHandler.cpython-311.pyc +0 -0
  148. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/GetEnumValueHandler.cpython-311.pyc +0 -0
  149. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/GetInstanceFieldHandler.cpython-311.pyc +0 -0
  150. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/GetStaticFieldHandler.cpython-311.pyc +0 -0
  151. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/GetTypeHandler.cpython-311.pyc +0 -0
  152. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/Handler.cpython-311.pyc +0 -0
  153. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/HandlerDictionary.cpython-311.pyc +0 -0
  154. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/InvokeInstanceMethodHandler.cpython-311.pyc +0 -0
  155. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/InvokeStaticMethodHandler.cpython-311.pyc +0 -0
  156. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/LoadLibraryHandler.cpython-311.pyc +0 -0
  157. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/ResolveInstanceHandler.cpython-311.pyc +0 -0
  158. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/SetInstanceFieldHandler.cpython-311.pyc +0 -0
  159. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/SetStaticFieldHandler.cpython-311.pyc +0 -0
  160. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/ValueHandler.cpython-311.pyc +0 -0
  161. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/handler/__pycache__/__init__.cpython-311.pyc +0 -0
  162. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/interpreter/Interpreter.py +11 -9
  163. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/interpreter/__pycache__/Interpreter.cpython-311.pyc +0 -0
  164. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/interpreter/__pycache__/__init__.cpython-311.pyc +0 -0
  165. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/namespaceCache/__pycache__/NamespaceCache.cpython-311.pyc +0 -0
  166. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/namespaceCache/__pycache__/__init__.cpython-311.pyc +0 -0
  167. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/protocol/CommandSerializer.py +3 -16
  168. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/protocol/__pycache__/CommandDeserializer.cpython-311.pyc +0 -0
  169. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/protocol/__pycache__/CommandSerializer.cpython-311.pyc +0 -0
  170. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/protocol/__pycache__/TypeDeserializer.cpython-311.pyc +0 -0
  171. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/protocol/__pycache__/TypeSerializer.cpython-311.pyc +0 -0
  172. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/protocol/__pycache__/__init__.cpython-311.pyc +0 -0
  173. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/receiver/Receiver.py +3 -1
  174. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/receiver/__pycache__/Receiver.cpython-311.pyc +0 -0
  175. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/receiver/__pycache__/__init__.cpython-311.pyc +0 -0
  176. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/referenceCache/ReferencesCache.py +2 -1
  177. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/referenceCache/__pycache__/ReferencesCache.cpython-311.pyc +0 -0
  178. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/referenceCache/__pycache__/__init__.cpython-311.pyc +0 -0
  179. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/transmitter/Transmitter.py +2 -14
  180. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/typeCache/__pycache__/TypeCache.cpython-311.pyc +0 -0
  181. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/typeCache/__pycache__/__init__.cpython-311.pyc +0 -0
  182. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/core/webSocketClient/WebSocketClient.py +32 -0
  183. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/ConnectionType.py +1 -0
  184. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/__pycache__/Command.cpython-311.pyc +0 -0
  185. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/__pycache__/CommandType.cpython-311.pyc +0 -0
  186. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/__pycache__/ConnectionType.cpython-311.pyc +0 -0
  187. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/__pycache__/ExceptionType.cpython-311.pyc +0 -0
  188. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/__pycache__/RuntimeName.cpython-311.pyc +0 -0
  189. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/__pycache__/StringEncodingMode.cpython-311.pyc +0 -0
  190. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/__pycache__/Type.cpython-311.pyc +0 -0
  191. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/__pycache__/__init__.cpython-311.pyc +0 -0
  192. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/connectionData/IConnectionData.py +18 -0
  193. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/connectionData/InMemoryConnectionData.py +23 -0
  194. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/connectionData/TcpConnectionData.py +67 -0
  195. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/connectionData/WsConnectionData.py +30 -0
  196. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/connectionData/__init__.py +0 -0
  197. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/connectionData/__pycache__/IConnectionData.cpython-311.pyc +0 -0
  198. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/connectionData/__pycache__/InMemoryConnectionData.cpython-311.pyc +0 -0
  199. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/connectionData/__pycache__/__init__.cpython-311.pyc +0 -0
  200. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/exception/__pycache__/ExceptionSerializer.cpython-311.pyc +0 -0
  201. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/exception/__pycache__/__init__.cpython-311.pyc +0 -0
  202. data/lib/javonet-ruby-sdk/Binaries/version.txt +1 -1
  203. metadata +24 -18
  204. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libruby.so.3.1.5 +0 -0
  205. data/lib/javonet-ruby-sdk/Binaries/Native/Linux/X64/libruby.so.3.3.1 +0 -0
  206. data/lib/javonet-ruby-sdk/Binaries/Native/MacOs/X64/libruby.3.3.dylib +0 -0
  207. data/lib/javonet-ruby-sdk/Binaries/Native/Windows/X64/x64-vcruntime140-ruby330.dll +0 -0
  208. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/CPAN/Meta/Requirements/Range.pm +0 -776
  209. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/CPAN/Meta/Requirements.pm +0 -834
  210. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/CPAN/Requirements/Dynamic.pm +0 -384
  211. data/lib/javonet-ruby-sdk/Binaries/Perl/Linux/X64/deps/lib/perl5/ExtUtils/HasCompiler.pm +0 -308
  212. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/CPAN/Meta/Requirements/Range.pm +0 -776
  213. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/CPAN/Meta/Requirements.pm +0 -834
  214. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/CPAN/Requirements/Dynamic.pm +0 -384
  215. data/lib/javonet-ruby-sdk/Binaries/Perl/MacOs/X64/deps/lib/perl5/ExtUtils/HasCompiler.pm +0 -308
  216. data/lib/javonet-ruby-sdk/Binaries/Python/Linux/X64/javonet/utils/TcpConnectionData.py +0 -29
  217. data/lib/javonet-ruby-sdk/Binaries/Python/MacOs/X64/javonet/utils/TcpConnectionData.py +0 -29
  218. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/TcpConnectionData.py +0 -29
  219. data/lib/javonet-ruby-sdk/Binaries/Python/Windows/X64/javonet/utils/__pycache__/TcpConnectionData.cpython-311.pyc +0 -0
@@ -0,0 +1,23 @@
1
+ from javonet.utils.ConnectionType import ConnectionType
2
+ from javonet.utils.connectionData.IConnectionData import IConnectionData
3
+
4
+
5
+ class InMemoryConnectionData(IConnectionData):
6
+ @property
7
+ def connection_type(self):
8
+ return ConnectionType.InMemory
9
+
10
+ @property
11
+ def hostname(self):
12
+ return ""
13
+
14
+ def serialize_connection_data(self):
15
+ return [self.connection_type.value, 0, 0, 0, 0, 0, 0]
16
+
17
+ def __eq__(self, other):
18
+ return isinstance(other, InMemoryConnectionData)
19
+
20
+ def __hash__(self):
21
+ hash_code = 593727026
22
+ hash_code = hash_code * -1521134295 + hash(self.connection_type)
23
+ return hash_code
@@ -0,0 +1,67 @@
1
+ import hashlib
2
+ import socket
3
+
4
+ from javonet.utils.ConnectionType import ConnectionType
5
+ from javonet.utils.connectionData.IConnectionData import IConnectionData
6
+
7
+
8
+ class TcpConnectionData(IConnectionData):
9
+
10
+ def __init__(self, hostname: str, port: int):
11
+ self._hostname = hostname
12
+ self._port = port
13
+ self._ip_address = ""
14
+ if self._hostname == "localhost":
15
+ self._ip_address = "127.0.0.1"
16
+ else:
17
+ try:
18
+ self._ip_address = socket.gethostbyname(self._hostname)
19
+ except socket.gaierror:
20
+ self._ip_address = ""
21
+
22
+ @property
23
+ def connection_type(self):
24
+ return ConnectionType.Tcp
25
+
26
+ @property
27
+ def hostname(self):
28
+ return self._hostname
29
+
30
+ @property
31
+ def ip_address(self):
32
+ return self._ip_address
33
+
34
+ @property
35
+ def port(self):
36
+ return self._port
37
+
38
+ def serialize_connection_data(self):
39
+ address_bytes = self.__get_address_bytes()
40
+ port_bytes = self.__get_pot_bytes()
41
+ return [self.connection_type.value] + address_bytes + port_bytes
42
+
43
+ def __get_address_bytes(self):
44
+ return [int(x) for x in self._ip_address.split(".")]
45
+
46
+ def __get_pot_bytes(self):
47
+ return [self._port & 0xFF, self._port >> 8]
48
+
49
+ def __eq__(self, other):
50
+ if isinstance(other, TcpConnectionData):
51
+ return self._ip_address == other.ip_address and self._port == other.port
52
+ return False
53
+
54
+ def __hash__(self):
55
+ return int(hashlib.sha1(f"{self._ip_address}{self._port}".encode()).hexdigest(), 16)
56
+
57
+ @hostname.setter
58
+ def hostname(self, value):
59
+ self._hostname = value
60
+
61
+ @port.setter
62
+ def port(self, value):
63
+ self._port = value
64
+
65
+ @ip_address.setter
66
+ def ip_address(self, value):
67
+ self._ip_address = value
@@ -0,0 +1,30 @@
1
+ import hashlib
2
+
3
+ from javonet.utils.ConnectionType import ConnectionType
4
+ from javonet.utils.connectionData.IConnectionData import IConnectionData
5
+
6
+
7
+ class WsConnectionData(IConnectionData):
8
+
9
+ def __init__(self, hostname: str):
10
+ self._hostname = hostname
11
+ @property
12
+ def connection_type(self):
13
+ return ConnectionType.WebSocket
14
+
15
+ @property
16
+ def hostname(self):
17
+ return self._hostname
18
+
19
+ def serialize_connection_data(self):
20
+ return [self.connection_type.value, 0, 0, 0, 0, 0, 0]
21
+
22
+ def __eq__(self, other):
23
+ return isinstance(other, WsConnectionData) and self._hostname == other.hostname
24
+
25
+ def __hash__(self):
26
+ return int(hashlib.sha1(f"{self.hostname}".encode()).hexdigest(), 16)
27
+
28
+ @hostname.setter
29
+ def hostname(self, value):
30
+ self._hostname = value
@@ -3,30 +3,32 @@ from javonet.core.protocol.CommandDeserializer import CommandDeserializer
3
3
  from javonet.core.protocol.CommandSerializer import CommandSerializer
4
4
  from javonet.utils.ConnectionType import ConnectionType
5
5
  from javonet.utils.RuntimeName import RuntimeName
6
- from javonet.utils.TcpConnectionData import TcpConnectionData
7
-
6
+ from javonet.utils.connectionData.IConnectionData import IConnectionData
8
7
 
9
8
  class Interpreter:
10
- response = None
11
9
 
12
- def execute(self, command, connection_type, tcp_connection_data: TcpConnectionData):
10
+ def execute(self, command, connection_data: IConnectionData):
13
11
  command_serializer = CommandSerializer()
14
- serialized_command = command_serializer.serialize(command, connection_type, tcp_connection_data)
15
- if (command.runtime_name == RuntimeName.python) & (connection_type == ConnectionType.InMemory):
12
+ serialized_command = command_serializer.serialize(command, connection_data)
13
+ response = None
14
+ if connection_data.connection_type == ConnectionType.WebSocket:
15
+ from javonet.core.webSocketClient.WebSocketClient import WebSocketClient
16
+ response = WebSocketClient().send_message(connection_data, serialized_command)
17
+ elif (command.runtime_name == RuntimeName.python) & (connection_data.connection_type == ConnectionType.InMemory):
16
18
  from javonet.core.receiver.Receiver import Receiver
17
19
  response = Receiver().SendCommand(serialized_command, len(serialized_command))
18
20
  else:
19
21
  from javonet.core.transmitter.Transmitter import Transmitter
20
22
  response = Transmitter.send_command(serialized_command)
21
- command_deserializer = CommandDeserializer(response, len(response))
22
23
 
24
+ command_deserializer = CommandDeserializer(response, len(response))
23
25
  return command_deserializer.deserialize()
24
26
 
25
- def process(self, byte_array, byte_array_len):
27
+ def process(self, byte_array, byte_array_len, connection_data: IConnectionData):
26
28
  command_deserializer = CommandDeserializer(byte_array, byte_array_len)
27
29
  received_command = command_deserializer.deserialize()
28
30
  python_handler = Handler()
29
31
  command_serializer = CommandSerializer()
30
32
  response_command = python_handler.handle_command(received_command)
31
- encoded_response = command_serializer.serialize(response_command, 0, "0.0.0.0:0")
33
+ encoded_response = command_serializer.serialize(response_command, connection_data)
32
34
  return encoded_response
@@ -1,36 +1,23 @@
1
- import struct
2
1
  from collections import deque
3
2
  from typing import Deque
4
3
 
5
4
  from javonet.core.protocol.TypeSerializer import TypeSerializer
6
5
  from javonet.utils.Command import Command
7
- from javonet.utils.ConnectionType import ConnectionType
8
6
  from javonet.utils.RuntimeName import RuntimeName
9
- from javonet.utils.TcpConnectionData import TcpConnectionData
7
+ from javonet.utils.connectionData.IConnectionData import IConnectionData
10
8
 
11
9
 
12
10
  class CommandSerializer:
13
11
  byte_buffer = []
14
12
 
15
- def serialize(self, root_command, connection_type, tcp_connection_data: TcpConnectionData, runtime_version=0):
13
+ def serialize(self, root_command: Command, connection_data: IConnectionData, runtime_version=0):
16
14
  queue: Deque[Command] = deque()
17
15
  queue.append(root_command)
18
16
  self.insert_into_buffer([root_command.runtime_name.value, runtime_version])
19
- if connection_type == ConnectionType.Tcp:
20
- self.insert_into_buffer([ConnectionType.Tcp.value])
21
- self.insert_into_buffer(self.serialize_tcp(tcp_connection_data))
22
- else:
23
- self.insert_into_buffer([ConnectionType.InMemory.value])
24
- self.insert_into_buffer([0, 0, 0, 0, 0, 0])
17
+ self.insert_into_buffer(connection_data.serialize_connection_data())
25
18
  self.insert_into_buffer([RuntimeName.python.value, root_command.command_type.value])
26
19
  return self.serialize_recursively(queue)
27
20
 
28
- @staticmethod
29
- def serialize_tcp(tcp_connection_data):
30
- if tcp_connection_data is None:
31
- raise Exception("tcp_connection_data is not provided")
32
- return tcp_connection_data.get_address_bytes() + tcp_connection_data.get_pot_bytes()
33
-
34
21
  @staticmethod
35
22
  def serialize_primitive(payload_item):
36
23
  if payload_item is None:
@@ -1,13 +1,15 @@
1
1
  from javonet.core.interpreter.Interpreter import Interpreter
2
+ from javonet.utils.connectionData.InMemoryConnectionData import InMemoryConnectionData
2
3
 
3
4
 
4
5
  class Receiver:
5
6
 
6
7
  def __init__(self):
7
8
  self.python_interpreter = Interpreter()
9
+ self.connection_data = InMemoryConnectionData()
8
10
 
9
11
  def SendCommand(self, messageByteArray, messageByteArrayLen):
10
- return bytearray(self.python_interpreter.process(messageByteArray, len(messageByteArray)))
12
+ return bytearray(self.python_interpreter.process(messageByteArray, len(messageByteArray), self.connection_data))
11
13
 
12
14
  def HeartBeat(self, messageByteArray, messageByteArrayLen):
13
15
  response_byte_array = bytearray(2)
@@ -2,6 +2,7 @@ import uuid
2
2
  import threading
3
3
  from javonet.utils.CommandType import CommandType
4
4
 
5
+
5
6
  class ReferencesCache(object):
6
7
  _instance = None
7
8
  references_cache = dict()
@@ -35,4 +36,4 @@ class ReferencesCache(object):
35
36
  del self.references_cache[reference_guid]
36
37
  return 0
37
38
  except KeyError:
38
- raise Exception("Object not found in references")
39
+ raise Exception("Object not found in references")
@@ -8,20 +8,8 @@ class Transmitter:
8
8
  return TransmitterWrapper.send_command(message)
9
9
 
10
10
  @staticmethod
11
- def __activate(license_key="", proxy_host="", proxy_user_name="", proxy_user_password=""):
12
- return TransmitterWrapper.activate(license_key, proxy_host, proxy_user_name, proxy_user_password)
13
-
14
- @staticmethod
15
- def activate_with_license_file():
16
- return Transmitter.__activate()
17
-
18
- @staticmethod
19
- def activate_with_credentials(license_key):
20
- return Transmitter.__activate(license_key)
21
-
22
- @staticmethod
23
- def activate_with_credentials_and_proxy(license_key, proxy_host, proxy_user_name, proxy_user_password):
24
- return Transmitter.__activate(license_key, proxy_host, proxy_user_name, proxy_user_password)
11
+ def activate(license_key=""):
12
+ return TransmitterWrapper.activate(license_key, "", "", "")
25
13
 
26
14
  @staticmethod
27
15
  def set_config_source(source_path):
@@ -0,0 +1,32 @@
1
+ import asyncio
2
+ import struct
3
+ from websockets.sync.client import connect
4
+
5
+ from javonet.utils.connectionData.WsConnectionData import WsConnectionData
6
+
7
+
8
+ class WebSocketClient:
9
+ _instance = None
10
+ clients = dict()
11
+
12
+ def __new__(cls):
13
+ if cls._instance is None:
14
+ cls._instance = super(WebSocketClient, cls).__new__(cls)
15
+ return cls._instance
16
+
17
+ def add_or_get_client(self, connection_data: WsConnectionData):
18
+ if connection_data.hostname in self.clients:
19
+ return self.clients[connection_data.hostname]
20
+ else:
21
+ self.clients[connection_data.hostname] = connect(connection_data.hostname)
22
+ return self.clients[connection_data.hostname]
23
+
24
+ def send_message(self, connection_data: WsConnectionData, serialized_command):
25
+ byte_array = struct.pack("B" * len(serialized_command), *serialized_command)
26
+ return self.send(connection_data, byte_array)
27
+
28
+ def send(self, connection_data: WsConnectionData, byte_array):
29
+ websocket = self.add_or_get_client(connection_data)
30
+ websocket.send(byte_array)
31
+ response = websocket.recv()
32
+ return response
@@ -4,3 +4,4 @@ from enum import Enum
4
4
  class ConnectionType(Enum):
5
5
  InMemory = 0
6
6
  Tcp = 1
7
+ WebSocket = 2
@@ -0,0 +1,18 @@
1
+ from abc import ABC, abstractmethod
2
+ from javonet.utils.ConnectionType import ConnectionType
3
+
4
+
5
+ class IConnectionData(ABC):
6
+ @property
7
+ @abstractmethod
8
+ def connection_type(self):
9
+ pass
10
+
11
+ @property
12
+ @abstractmethod
13
+ def hostname(self):
14
+ pass
15
+
16
+ @abstractmethod
17
+ def serialize_connection_data(self):
18
+ pass
@@ -0,0 +1,23 @@
1
+ from javonet.utils.ConnectionType import ConnectionType
2
+ from javonet.utils.connectionData.IConnectionData import IConnectionData
3
+
4
+
5
+ class InMemoryConnectionData(IConnectionData):
6
+ @property
7
+ def connection_type(self):
8
+ return ConnectionType.InMemory
9
+
10
+ @property
11
+ def hostname(self):
12
+ return ""
13
+
14
+ def serialize_connection_data(self):
15
+ return [self.connection_type.value, 0, 0, 0, 0, 0, 0]
16
+
17
+ def __eq__(self, other):
18
+ return isinstance(other, InMemoryConnectionData)
19
+
20
+ def __hash__(self):
21
+ hash_code = 593727026
22
+ hash_code = hash_code * -1521134295 + hash(self.connection_type)
23
+ return hash_code
@@ -0,0 +1,67 @@
1
+ import hashlib
2
+ import socket
3
+
4
+ from javonet.utils.ConnectionType import ConnectionType
5
+ from javonet.utils.connectionData.IConnectionData import IConnectionData
6
+
7
+
8
+ class TcpConnectionData(IConnectionData):
9
+
10
+ def __init__(self, hostname: str, port: int):
11
+ self._hostname = hostname
12
+ self._port = port
13
+ self._ip_address = ""
14
+ if self._hostname == "localhost":
15
+ self._ip_address = "127.0.0.1"
16
+ else:
17
+ try:
18
+ self._ip_address = socket.gethostbyname(self._hostname)
19
+ except socket.gaierror:
20
+ self._ip_address = ""
21
+
22
+ @property
23
+ def connection_type(self):
24
+ return ConnectionType.Tcp
25
+
26
+ @property
27
+ def hostname(self):
28
+ return self._hostname
29
+
30
+ @property
31
+ def ip_address(self):
32
+ return self._ip_address
33
+
34
+ @property
35
+ def port(self):
36
+ return self._port
37
+
38
+ def serialize_connection_data(self):
39
+ address_bytes = self.__get_address_bytes()
40
+ port_bytes = self.__get_pot_bytes()
41
+ return [self.connection_type.value] + address_bytes + port_bytes
42
+
43
+ def __get_address_bytes(self):
44
+ return [int(x) for x in self._ip_address.split(".")]
45
+
46
+ def __get_pot_bytes(self):
47
+ return [self._port & 0xFF, self._port >> 8]
48
+
49
+ def __eq__(self, other):
50
+ if isinstance(other, TcpConnectionData):
51
+ return self._ip_address == other.ip_address and self._port == other.port
52
+ return False
53
+
54
+ def __hash__(self):
55
+ return int(hashlib.sha1(f"{self._ip_address}{self._port}".encode()).hexdigest(), 16)
56
+
57
+ @hostname.setter
58
+ def hostname(self, value):
59
+ self._hostname = value
60
+
61
+ @port.setter
62
+ def port(self, value):
63
+ self._port = value
64
+
65
+ @ip_address.setter
66
+ def ip_address(self, value):
67
+ self._ip_address = value
@@ -0,0 +1,30 @@
1
+ import hashlib
2
+
3
+ from javonet.utils.ConnectionType import ConnectionType
4
+ from javonet.utils.connectionData.IConnectionData import IConnectionData
5
+
6
+
7
+ class WsConnectionData(IConnectionData):
8
+
9
+ def __init__(self, hostname: str):
10
+ self._hostname = hostname
11
+ @property
12
+ def connection_type(self):
13
+ return ConnectionType.WebSocket
14
+
15
+ @property
16
+ def hostname(self):
17
+ return self._hostname
18
+
19
+ def serialize_connection_data(self):
20
+ return [self.connection_type.value, 0, 0, 0, 0, 0, 0]
21
+
22
+ def __eq__(self, other):
23
+ return isinstance(other, WsConnectionData) and self._hostname == other.hostname
24
+
25
+ def __hash__(self):
26
+ return int(hashlib.sha1(f"{self.hostname}".encode()).hexdigest(), 16)
27
+
28
+ @hostname.setter
29
+ def hostname(self, value):
30
+ self._hostname = value
@@ -3,30 +3,32 @@ from javonet.core.protocol.CommandDeserializer import CommandDeserializer
3
3
  from javonet.core.protocol.CommandSerializer import CommandSerializer
4
4
  from javonet.utils.ConnectionType import ConnectionType
5
5
  from javonet.utils.RuntimeName import RuntimeName
6
- from javonet.utils.TcpConnectionData import TcpConnectionData
7
-
6
+ from javonet.utils.connectionData.IConnectionData import IConnectionData
8
7
 
9
8
  class Interpreter:
10
- response = None
11
9
 
12
- def execute(self, command, connection_type, tcp_connection_data: TcpConnectionData):
10
+ def execute(self, command, connection_data: IConnectionData):
13
11
  command_serializer = CommandSerializer()
14
- serialized_command = command_serializer.serialize(command, connection_type, tcp_connection_data)
15
- if (command.runtime_name == RuntimeName.python) & (connection_type == ConnectionType.InMemory):
12
+ serialized_command = command_serializer.serialize(command, connection_data)
13
+ response = None
14
+ if connection_data.connection_type == ConnectionType.WebSocket:
15
+ from javonet.core.webSocketClient.WebSocketClient import WebSocketClient
16
+ response = WebSocketClient().send_message(connection_data, serialized_command)
17
+ elif (command.runtime_name == RuntimeName.python) & (connection_data.connection_type == ConnectionType.InMemory):
16
18
  from javonet.core.receiver.Receiver import Receiver
17
19
  response = Receiver().SendCommand(serialized_command, len(serialized_command))
18
20
  else:
19
21
  from javonet.core.transmitter.Transmitter import Transmitter
20
22
  response = Transmitter.send_command(serialized_command)
21
- command_deserializer = CommandDeserializer(response, len(response))
22
23
 
24
+ command_deserializer = CommandDeserializer(response, len(response))
23
25
  return command_deserializer.deserialize()
24
26
 
25
- def process(self, byte_array, byte_array_len):
27
+ def process(self, byte_array, byte_array_len, connection_data: IConnectionData):
26
28
  command_deserializer = CommandDeserializer(byte_array, byte_array_len)
27
29
  received_command = command_deserializer.deserialize()
28
30
  python_handler = Handler()
29
31
  command_serializer = CommandSerializer()
30
32
  response_command = python_handler.handle_command(received_command)
31
- encoded_response = command_serializer.serialize(response_command, 0, "0.0.0.0:0")
33
+ encoded_response = command_serializer.serialize(response_command, connection_data)
32
34
  return encoded_response
@@ -1,36 +1,23 @@
1
- import struct
2
1
  from collections import deque
3
2
  from typing import Deque
4
3
 
5
4
  from javonet.core.protocol.TypeSerializer import TypeSerializer
6
5
  from javonet.utils.Command import Command
7
- from javonet.utils.ConnectionType import ConnectionType
8
6
  from javonet.utils.RuntimeName import RuntimeName
9
- from javonet.utils.TcpConnectionData import TcpConnectionData
7
+ from javonet.utils.connectionData.IConnectionData import IConnectionData
10
8
 
11
9
 
12
10
  class CommandSerializer:
13
11
  byte_buffer = []
14
12
 
15
- def serialize(self, root_command, connection_type, tcp_connection_data: TcpConnectionData, runtime_version=0):
13
+ def serialize(self, root_command: Command, connection_data: IConnectionData, runtime_version=0):
16
14
  queue: Deque[Command] = deque()
17
15
  queue.append(root_command)
18
16
  self.insert_into_buffer([root_command.runtime_name.value, runtime_version])
19
- if connection_type == ConnectionType.Tcp:
20
- self.insert_into_buffer([ConnectionType.Tcp.value])
21
- self.insert_into_buffer(self.serialize_tcp(tcp_connection_data))
22
- else:
23
- self.insert_into_buffer([ConnectionType.InMemory.value])
24
- self.insert_into_buffer([0, 0, 0, 0, 0, 0])
17
+ self.insert_into_buffer(connection_data.serialize_connection_data())
25
18
  self.insert_into_buffer([RuntimeName.python.value, root_command.command_type.value])
26
19
  return self.serialize_recursively(queue)
27
20
 
28
- @staticmethod
29
- def serialize_tcp(tcp_connection_data):
30
- if tcp_connection_data is None:
31
- raise Exception("tcp_connection_data is not provided")
32
- return tcp_connection_data.get_address_bytes() + tcp_connection_data.get_pot_bytes()
33
-
34
21
  @staticmethod
35
22
  def serialize_primitive(payload_item):
36
23
  if payload_item is None: