paulc
c4c9e994f0
Renamed DebugGoOn to DebugCrit so it better matches its purpose.
...
Swapped order of DebugCall and DebugNote so DebugCall is less visible.
Changed default debug level to DebugNote.
Modified a few inadequate uses of DebugCrit.
git-svn-id: http://yate.null.ro/svn/yate/trunk@6250 acf43c95-373e-0410-b603-e72c3f656dc1
2017-08-01 13:08:23 +00:00
andrei
255bd0161a
Added support for Semaphore in JS.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6248 acf43c95-373e-0410-b603-e72c3f656dc1
2017-08-01 06:20:58 +00:00
paulc
9e5c186299
Added support for setting "debug level N+" or "debug level N-"
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6226 acf43c95-373e-0410-b603-e72c3f656dc1
2017-06-05 12:33:38 +00:00
oana
9e8a1602c1
Added Message.copyParams() method to Javascript support.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6219 acf43c95-373e-0410-b603-e72c3f656dc1
2017-05-22 12:37:22 +00:00
oana
828911a1d7
Do not attempt to build an JS XML object from another object when the expected parameter should be a string.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6215 acf43c95-373e-0410-b603-e72c3f656dc1
2017-05-08 09:04:33 +00:00
oana
23b9e4a09c
Build JS Message objects with properly set prototypes.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6214 acf43c95-373e-0410-b603-e72c3f656dc1
2017-05-08 09:03:05 +00:00
andrei
42d5ab7c01
Fixed deadlock while destroying JsEngineWorker.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6212 acf43c95-373e-0410-b603-e72c3f656dc1
2017-05-03 08:39:48 +00:00
andrei
f44fef8bfc
Added option to get the age of a message.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6211 acf43c95-373e-0410-b603-e72c3f656dc1
2017-04-27 12:30:45 +00:00
paulc
d836aca12b
Added JS Engine method to retrieve exiting state from a script.
...
Moved engine.halt handler that unloads global JS scripts to priority 120.
git-svn-id: http://yate.null.ro/svn/yate/trunk@6210 acf43c95-373e-0410-b603-e72c3f656dc1
2017-04-27 10:31:07 +00:00
oana
f180ed599d
Extend JS Message constructor to copy parameters from a given object.
...
Fix function that was copying properties to message to not copy objects, null or undefined.
git-svn-id: http://yate.null.ro/svn/yate/trunk@6209 acf43c95-373e-0410-b603-e72c3f656dc1
2017-04-26 15:53:15 +00:00
andrei
511a5d36ca
Fixed deadlock at JS script instance destruction.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6208 acf43c95-373e-0410-b603-e72c3f656dc1
2017-04-26 10:40:04 +00:00
paulc
54e9ebf2e5
Added support for using JS method msgTime(newTime) to alter creation time of a message.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6207 acf43c95-373e-0410-b603-e72c3f656dc1
2017-04-21 14:06:16 +00:00
paulc
0ce48000ee
Keep the JS global object locked while cleaning up its attributes.
...
This fixes a race condition crash in scripts destruction.
git-svn-id: http://yate.null.ro/svn/yate/trunk@6174 acf43c95-373e-0410-b603-e72c3f656dc1
2017-01-24 18:53:16 +00:00
paulc
887e0cd860
Fixed a JS deadlock caused by uninstalling a message handler from itself (even indirectly).
...
This required exposing some internal methods of MessageHandler.
git-svn-id: http://yate.null.ro/svn/yate/trunk@6173 acf43c95-373e-0410-b603-e72c3f656dc1
2017-01-23 19:53:55 +00:00
paulc
c088d3ef2e
Added methods getParam and setParam to Javascript Message object.
...
These allow manipulating parameters whose name clashes with a method.
git-svn-id: http://yate.null.ro/svn/yate/trunk@6170 acf43c95-373e-0410-b603-e72c3f656dc1
2017-01-20 15:16:19 +00:00
paulc
cfccac463c
Added Engine methods for retrieving uptime from Javascript.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6169 acf43c95-373e-0410-b603-e72c3f656dc1
2017-01-20 13:28:58 +00:00
paulc
e5a8a16f1d
Added setting to automatically enter congested mode over a queue size threshold.
...
Added access to Engine's call accept state from Javascript and regexroute.
Optimized MessageDispatcher::messageCount() using the enqueue / dequeue counters.
git-svn-id: http://yate.null.ro/svn/yate/trunk@6163 acf43c95-373e-0410-b603-e72c3f656dc1
2017-01-09 15:04:04 +00:00
paulc
870d7b38b9
Fixed a rather harmless shutdown time memory leak.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6147 acf43c95-373e-0410-b603-e72c3f656dc1
2016-11-07 18:20:07 +00:00
paulc
f37f408a2f
Made maximum loadable JS file size configurable.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6116 acf43c95-373e-0410-b603-e72c3f656dc1
2016-05-18 13:31:47 +00:00
marian
647e6c4da7
Added function used to obtain XML attributes. Extended setAttribute() to allow setting multiple attributes.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6091 acf43c95-373e-0410-b603-e72c3f656dc1
2016-02-15 15:06:10 +00:00
marian
80e46badff
JsXML: properly check namespace parameter pointer before using it.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6090 acf43c95-373e-0410-b603-e72c3f656dc1
2016-02-15 12:44:43 +00:00
paulc
3aeb6687d5
Fixed a GCC 6 build error: C++11 requires a space between literal and string macro.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6084 acf43c95-373e-0410-b603-e72c3f656dc1
2016-01-20 10:23:35 +00:00
paulc
79dbe9f241
Added API method for checking if the Engine has finished starting up, expose it to JS.
...
Added separate javascript.conf section that loads scripts after the engine.start message.
git-svn-id: http://yate.null.ro/svn/yate/trunk@6081 acf43c95-373e-0410-b603-e72c3f656dc1
2016-01-04 12:49:52 +00:00
paulc
f96cdb4110
Allow setting extra parameters in JS Channel.hangup()
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6068 acf43c95-373e-0410-b603-e72c3f656dc1
2015-11-24 15:38:35 +00:00
paulc
835d7b6bfd
Put the disconnect reason in the proper message parameter.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6065 acf43c95-373e-0410-b603-e72c3f656dc1
2015-11-17 13:31:15 +00:00
paulc
8526e7f01f
Added onPostExecute hook that gets called by channel scripts when call.execute returns.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6063 acf43c95-373e-0410-b603-e72c3f656dc1
2015-11-12 21:29:55 +00:00
paulc
f02df8cdb0
Make sure a JsAssist is not created for outbound call legs.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6062 acf43c95-373e-0410-b603-e72c3f656dc1
2015-11-12 21:15:26 +00:00
paulc
6f3f09ddbe
Added support for specifying the mode to mkdir.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6061 acf43c95-373e-0410-b603-e72c3f656dc1
2015-11-11 17:58:05 +00:00
paulc
35079bdae6
Convert binary database message results to hexadecimal strings.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6058 acf43c95-373e-0410-b603-e72c3f656dc1
2015-10-29 08:33:09 +00:00
paulc
e0f16e2941
Escape same control characters as ExpEvaluator::getEscape() when stringifying JSON.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6049 acf43c95-373e-0410-b603-e72c3f656dc1
2015-09-30 08:42:47 +00:00
paulc
0b38ac3adc
Consider undefined and null as missing name or namespace for finding XML childs.
...
Refuse to create an XML child with an empty or null tag.
Added constants for XML put methods.
git-svn-id: http://yate.null.ro/svn/yate/trunk@6032 acf43c95-373e-0410-b603-e72c3f656dc1
2015-09-09 13:05:34 +00:00
paulc
79f5b70ca5
Added static Engine.replaceParams() that replaces object properties in a ${template} string.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6030 acf43c95-373e-0410-b603-e72c3f656dc1
2015-09-04 20:04:02 +00:00
paulc
2c94c52e35
Added support for copy constructing a JS XML.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6027 acf43c95-373e-0410-b603-e72c3f656dc1
2015-08-31 11:05:58 +00:00
paulc
dde5f5ca6f
Added a version of the JS XML constructor that takes element name and optional text.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6026 acf43c95-373e-0410-b603-e72c3f656dc1
2015-08-31 08:09:15 +00:00
paulc
3bd65c1cc6
Add a JS Engine.name property so scripts can know how they were started.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6024 acf43c95-373e-0410-b603-e72c3f656dc1
2015-08-27 10:58:42 +00:00
paulc
307a7c09ef
Added support for JS getIntValue() min/max/clamp parameters.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6023 acf43c95-373e-0410-b603-e72c3f656dc1
2015-08-27 10:56:06 +00:00
marian
b18d902a69
Added addValue() method to ConfigFile.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6022 acf43c95-373e-0410-b603-e72c3f656dc1
2015-08-25 10:18:26 +00:00
marian
66c6ee12ff
Added clearSection() method to ConfigFile. Added addValue() method to ConfigSection.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6021 acf43c95-373e-0410-b603-e72c3f656dc1
2015-08-25 09:37:59 +00:00
paulc
5b980e2793
Added prototypes to parsed JSON objects and arrays.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6020 acf43c95-373e-0410-b603-e72c3f656dc1
2015-08-21 13:07:19 +00:00
paulc
4a5c2f835f
Added JS method to restart the Yate engine (only if allow_abort is configured).
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6019 acf43c95-373e-0410-b603-e72c3f656dc1
2015-08-18 16:09:40 +00:00
paulc
5f6d1e7e8d
Refuse to JSON.stringify functions, return undefined for undefined and functions.
...
Completely remove from JSON object properties that are functions or undefined.
git-svn-id: http://yate.null.ro/svn/yate/trunk@5938 acf43c95-373e-0410-b603-e72c3f656dc1
2015-02-10 12:43:05 +00:00
paulc
0953ee36d5
Added NIST FIPS 186-2 change notice 1 Pseudo Random Function with 160 bits SHA-1.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@5936 acf43c95-373e-0410-b603-e72c3f656dc1
2015-02-05 17:58:39 +00:00
oana
7e7477a2e6
Do not keep reajusting the relative path of a dinamically loaded script.
...
Avoids unloading and reloading of the script at YATE reinit/javascript reload even if the script didn't change.
git-svn-id: http://yate.null.ro/svn/yate/trunk@5934 acf43c95-373e-0410-b603-e72c3f656dc1
2015-01-30 13:39:52 +00:00
paulc
7f38064c6d
Added getInt64Value to NamedList and Configuration classes.
...
Added getIntValue and getBoolValue to Javascript ConfigFile and ConfigSection.
git-svn-id: http://yate.null.ro/svn/yate/trunk@5930 acf43c95-373e-0410-b603-e72c3f656dc1
2014-12-22 11:56:16 +00:00
paulc
7f834fd8b8
Added engine and Javascript methods for packing and unpacking IP addresses.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@5929 acf43c95-373e-0410-b603-e72c3f656dc1
2014-12-18 15:11:42 +00:00
paulc
48103e3e1b
Preserve correct path when reloading JS scripts that were loaded on demand.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@5926 acf43c95-373e-0410-b603-e72c3f656dc1
2014-12-09 11:33:04 +00:00
paulc
e160c8595b
Allow retrieving a pointer to native objects in JS Message, ConfigFile and XML.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@5921 acf43c95-373e-0410-b603-e72c3f656dc1
2014-10-29 16:32:20 +00:00
paulc
063b8f7707
Added optional parameter to XML.xmlText() to indent with spaces.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@5920 acf43c95-373e-0410-b603-e72c3f656dc1
2014-10-29 16:30:02 +00:00
paulc
da44cbe85c
Removed a harmless extra pair of brackets.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@5919 acf43c95-373e-0410-b603-e72c3f656dc1
2014-10-29 16:27:35 +00:00
oana
af150f67f0
Add option to dinamically load JS scripts through engine.command.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@5917 acf43c95-373e-0410-b603-e72c3f656dc1
2014-10-16 12:39:59 +00:00