qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fad...@apache.org
Subject svn commit: r1595519 [1/3] - in /qpid/proton/branches/fadams-javascript-binding: examples/messenger/javascript/ proton-c/bindings/javascript/ tests/javascript/
Date Sat, 17 May 2014 17:24:17 GMT
Author: fadams
Date: Sat May 17 17:24:16 2014
New Revision: 1595519

URL: http://svn.apache.org/r1595519
Log:
Implemented the remainder of the codec methods and ported the codec unit test suite to test
it all

Added:
    qpid/proton/branches/fadams-javascript-binding/tests/javascript/
    qpid/proton/branches/fadams-javascript-binding/tests/javascript/codec.js   (with props)
    qpid/proton/branches/fadams-javascript-binding/tests/javascript/unittest.js   (with props)
Removed:
    qpid/proton/branches/fadams-javascript-binding/proton-c/bindings/javascript/data-test.js
Modified:
    qpid/proton/branches/fadams-javascript-binding/examples/messenger/javascript/spout.js
    qpid/proton/branches/fadams-javascript-binding/proton-c/bindings/javascript/CMakeLists.txt
    qpid/proton/branches/fadams-javascript-binding/proton-c/bindings/javascript/binding.js

Modified: qpid/proton/branches/fadams-javascript-binding/examples/messenger/javascript/spout.js
URL: http://svn.apache.org/viewvc/qpid/proton/branches/fadams-javascript-binding/examples/messenger/javascript/spout.js?rev=1595519&r1=1595518&r2=1595519&view=diff
==============================================================================
--- qpid/proton/branches/fadams-javascript-binding/examples/messenger/javascript/spout.js
(original)
+++ qpid/proton/branches/fadams-javascript-binding/examples/messenger/javascript/spout.js
Sat May 17 17:24:16 2014
@@ -59,7 +59,6 @@ console.log("exiting");
         }
     };
 
-
     messenger.setOutgoingWindow(1024);
 
     messenger.setNetworkCallback(_process);
@@ -67,10 +66,27 @@ console.log("exiting");
 
     message.setAddress(address);
     message.setSubject(subject);
+
     //message.body = msgtext;
-    //message.body = new proton.Data.UUID();
+    //message.body = new proton.Data.Uuid();
     //message.body = new proton.Data.Symbol("My Symbol");
     //message.body = new proton.Data.Binary("Monkey Bathпогромзхцвбнм");
+    //message.body = new proton.Data.Described("persian", "feline mammals");
+
+    //message.body = new Date();
+
+    //message.body = new proton.Data.Array('INT', [1, 3, 5, 7], "odd numbers");
+
+    //message.body = new proton.Data.Array('UINT', [1, 3, 5, 7], "odd");
+    //message.body = new proton.Data.Array('ULONG', [1, 3, 5, 7], "odd");
+    //message.body = new proton.Data.Array('FLOAT', [1, 3, 5, 7], "odd");
+    //message.body = new proton.Data.Array('STRING', ["1", "3", "5", "7"], "odd");
+
+    //message.body = new Uint8Array([1, 3, 5, 7]);
+
+    //message.body = new proton.Data.Array('UINT', new Uint8Array([1, 3, 5, 7]), "odd");
+
+    //message.body = new proton.Data.Array('UUID', [new proton.Data.Uuid(), new proton.Data.Uuid(),
new proton.Data.Uuid(), new proton.Data.Uuid()], "unique");
 
     /*message.body = new proton.Data.Binary(4);
     var buffer = message.body.getBuffer();
@@ -78,24 +94,28 @@ console.log("exiting");
     buffer[1] = 77;
     buffer[2] = 81;
     buffer[3] = 80;*/
+    message.body = new proton.Data.Binary([65, 77, 81, 80]);
 
-
+    //message.body = null;
     //message.body = true;
+    //message.body = 66..char();
     //message.body = "   \"127.0\"  ";
 
     //message.body = 2147483647; // int
     //message.body = -2147483649; // long
     //message.body = 12147483649; // long
-
-
-    message.body = (121474.836490).asFloat(); // float TODO check me
-    //message.body = 12147483649.0.asFloat(); // float TODO check me
-    //message.body = (4294967296).asUnsignedInteger();
-    //message.body = (255).asUnsignedByte();
-
+    //message.body = (12147483649).long(); // long
+    //message.body = (-12147483649).ulong(); // long
+    //message.body = (17223372036854778000).ulong(); // ulong
+
+    //message.body = (121474.836490).float(); // float TODO check me
+    //message.body = 12147483649.0.float(); // float TODO check me
+    //message.body = (4294967296).uint();
+    //message.body = (255).ubyte();
 
     //message.body = ['Rod', 'Jane', 'Freddy'];
     //message.body = ['Rod', 'Jane', 'Freddy', {cat: true, donkey: 'hee haw'}];
+    //message.body = {cat: true, donkey: 'hee haw'};
 
     tracker = messenger.put(message);
 

Modified: qpid/proton/branches/fadams-javascript-binding/proton-c/bindings/javascript/CMakeLists.txt
URL: http://svn.apache.org/viewvc/qpid/proton/branches/fadams-javascript-binding/proton-c/bindings/javascript/CMakeLists.txt?rev=1595519&r1=1595518&r2=1595519&view=diff
==============================================================================
--- qpid/proton/branches/fadams-javascript-binding/proton-c/bindings/javascript/CMakeLists.txt
(original)
+++ qpid/proton/branches/fadams-javascript-binding/proton-c/bindings/javascript/CMakeLists.txt
Sat May 17 17:24:16 2014
@@ -222,7 +222,7 @@ set_target_properties(
   # This build is optimised and minified
   #LINK_FLAGS "-s \"EXPORT_NAME='proton'\" -s \"WEBSOCKET_SUBPROTOCOL='AMQPWSB10'\" -O2 --closure
1 --pre-js
 
-  LINK_FLAGS "-s \"EXPORT_NAME='proton'\" -s \"WEBSOCKET_SUBPROTOCOL='AMQPWSB10'\" -O2 --closure
1 --pre-js ${CMAKE_CURRENT_SOURCE_DIR}/binding-open.js --pre-js ${CMAKE_CURRENT_SOURCE_DIR}/binding.js
--post-js ${CMAKE_CURRENT_SOURCE_DIR}/binding-close.js --js-library ${CMAKE_CURRENT_SOURCE_DIR}/my-library.js
-s DEFAULT_LIBRARY_FUNCS_TO_INCLUDE=\"[]\" -s EXPORTED_FUNCTIONS=\"['_test', '_uuid_generate',
'_pn_bytes', '_pn_error_text', '_pn_code', '_pn_messenger', '_pn_messenger_name', '_pn_messenger_set_blocking',
'_pn_messenger_free', '_pn_messenger_errno', '_pn_messenger_error', '_pn_messenger_get_outgoing_window',
'_pn_messenger_set_outgoing_window', '_pn_messenger_get_incoming_window', '_pn_messenger_set_incoming_window',
'_pn_messenger_start', '_pn_messenger_stop', '_pn_messenger_stopped', '_pn_messenger_subscribe',
'_pn_messenger_put', '_pn_messenger_status', '_pn_messenger_buffered', '_pn_messenger_settle',
'_pn_messenger_outgoing_tracker', '_pn_messenger_work', '_pn_messenger_r
 ecv', '_pn_messenger_receiving', '_pn_messenger_get', '_pn_messenger_incoming_tracker', '_pn_messenger_incoming_subscription',
'_pn_messenger_accept', '_pn_messenger_reject', '_pn_messenger_outgoing', '_pn_messenger_incoming',
 '_pn_messenger_route', '_pn_messenger_rewrite', '_pn_subscription_get_context', '_pn_subscription_set_context',
'_pn_subscription_address', '_pn_message', '_pn_message_free', '_pn_message_get_address',
'_pn_message_errno', '_pn_message_error', '_pn_message_set_address', '_pn_message_get_subject',
'_pn_message_set_subject', '_pn_message_instructions', '_pn_message_annotations', '_pn_message_properties',
'_pn_message_body', '_pn_data', '_pn_data_free', '_pn_data_error', '_pn_data_errno', '_pn_data_clear',
'_pn_data_rewind', '_pn_data_next', '_pn_data_prev', '_pn_data_enter', '_pn_data_exit', '_pn_data_lookup',
'_pn_data_narrow', '_pn_data_widen', '_pn_data_type', '_pn_data_encode', '_pn_data_decode',
'_pn_data_put_list', '_pn_data_put_map', '_pn_data_put_array'
 , '_pn_data_put_described', '_pn_data_put_null', '_pn_data_put_bool', '_pn_data_put_ubyte',
'_pn_data_put_byte', '_pn_data_put_ushort', '_pn_data_put_short', '_pn_data_put_uint', '_pn_data_put_int',
'_pn_data_put_char', '_pn_data_put_ulong', '_pn_data_put_long', '_pn_data_put_timestamp',
'_pn_data_put_float', '_pn_data_put_double', '_pn_data_put_decimal32', '_pn_data_put_decimal64',
'_pn_data_put_decimal128', '_pn_data_put_uuid', '_pn_data_put_binary', '_pn_data_put_string',
'_pn_data_put_symbol', '_pn_data_get_list', '_pn_data_get_map', '_pn_data_get_array', '_pn_data_is_described',
'_pn_data_is_null', '_pn_data_get_bool', '_pn_data_get_ubyte', '_pn_data_get_byte', '_pn_data_get_ushort',
'_pn_data_get_short', '_pn_data_get_uint', '_pn_data_get_int', '_pn_data_get_char', '_pn_data_get_ulong',
'_pn_data_get_long', '_pn_data_get_timestamp', '_pn_data_get_float', '_pn_data_get_double',
'_pn_data_get_decimal32', '_pn_data_get_decimal64', '_pn_data_get_decimal128', '_pn_data_get_uuid',
'
 _pn_data_get_binary', '_pn_data_get_string', '_pn_data_get_symbol', '_pn_data_copy', '_pn_data_format',
'_pn_data_dump']\""
+  LINK_FLAGS "-s \"EXPORT_NAME='proton'\" -s \"WEBSOCKET_SUBPROTOCOL='AMQPWSB10'\" -O2 --closure
1 --pre-js ${CMAKE_CURRENT_SOURCE_DIR}/binding-open.js --pre-js ${CMAKE_CURRENT_SOURCE_DIR}/binding.js
--post-js ${CMAKE_CURRENT_SOURCE_DIR}/binding-close.js --js-library ${CMAKE_CURRENT_SOURCE_DIR}/my-library.js
-s DEFAULT_LIBRARY_FUNCS_TO_INCLUDE=\"[]\" -s EXPORTED_FUNCTIONS=\"['_test', '_uuid_generate',
'_pn_bytes', '_pn_error_text', '_pn_code', '_pn_messenger', '_pn_messenger_name', '_pn_messenger_set_blocking',
'_pn_messenger_free', '_pn_messenger_errno', '_pn_messenger_error', '_pn_messenger_get_outgoing_window',
'_pn_messenger_set_outgoing_window', '_pn_messenger_get_incoming_window', '_pn_messenger_set_incoming_window',
'_pn_messenger_start', '_pn_messenger_stop', '_pn_messenger_stopped', '_pn_messenger_subscribe',
'_pn_messenger_put', '_pn_messenger_status', '_pn_messenger_buffered', '_pn_messenger_settle',
'_pn_messenger_outgoing_tracker', '_pn_messenger_work', '_pn_messenger_r
 ecv', '_pn_messenger_receiving', '_pn_messenger_get', '_pn_messenger_incoming_tracker', '_pn_messenger_incoming_subscription',
'_pn_messenger_accept', '_pn_messenger_reject', '_pn_messenger_outgoing', '_pn_messenger_incoming',
 '_pn_messenger_route', '_pn_messenger_rewrite', '_pn_subscription_get_context', '_pn_subscription_set_context',
'_pn_subscription_address', '_pn_message', '_pn_message_free', '_pn_message_get_address',
'_pn_message_errno', '_pn_message_error', '_pn_message_set_address', '_pn_message_get_subject',
'_pn_message_set_subject', '_pn_message_instructions', '_pn_message_annotations', '_pn_message_properties',
'_pn_message_body', '_pn_data', '_pn_data_free', '_pn_data_error', '_pn_data_errno', '_pn_data_clear',
'_pn_data_rewind', '_pn_data_next', '_pn_data_prev', '_pn_data_enter', '_pn_data_exit', '_pn_data_lookup',
'_pn_data_narrow', '_pn_data_widen', '_pn_data_type', '_pn_data_encode', '_pn_data_decode',
'_pn_data_put_list', '_pn_data_put_map', '_pn_data_put_array'
 , '_pn_data_put_described', '_pn_data_put_null', '_pn_data_put_bool', '_pn_data_put_ubyte',
'_pn_data_put_byte', '_pn_data_put_ushort', '_pn_data_put_short', '_pn_data_put_uint', '_pn_data_put_int',
'_pn_data_put_char', '_pn_data_put_ulong', '_pn_data_put_long', '_pn_data_put_timestamp',
'_pn_data_put_float', '_pn_data_put_double', '_pn_data_put_decimal32', '_pn_data_put_decimal64',
'_pn_data_put_decimal128', '_pn_data_put_uuid', '_pn_data_put_binary', '_pn_data_put_string',
'_pn_data_put_symbol', '_pn_data_get_list', '_pn_data_get_map', '_pn_data_get_array', '_pn_data_is_array_described',
'_pn_data_get_array_type', '_pn_data_is_described', '_pn_data_is_null', '_pn_data_get_bool',
'_pn_data_get_ubyte', '_pn_data_get_byte', '_pn_data_get_ushort', '_pn_data_get_short', '_pn_data_get_uint',
'_pn_data_get_int', '_pn_data_get_char', '_pn_data_get_ulong', '_pn_data_get_long', '_pn_data_get_timestamp',
'_pn_data_get_float', '_pn_data_get_double', '_pn_data_get_decimal32', '_pn_data_get_dec
 imal64', '_pn_data_get_decimal128', '_pn_data_get_uuid', '_pn_data_get_binary', '_pn_data_get_string',
'_pn_data_get_symbol', '_pn_data_copy', '_pn_data_format', '_pn_data_dump']\""
   )
 
 # This command packages up the compiled proton.js into a node.js package called



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org


Mime
View raw message