marian
4a3740daf9
XML element replaceParams() is now available in javascript.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6306 acf43c95-373e-0410-b603-e72c3f656dc1
2018-04-10 11:08:25 +00:00
marian
8b17aa8edb
Engine::init() is now available in javascript.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6300 acf43c95-373e-0410-b603-e72c3f656dc1
2018-03-12 14:10:45 +00:00
oana
65bc140298
Add method to clear parameter(s) to JS Message API.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6298 acf43c95-373e-0410-b603-e72c3f656dc1
2018-02-12 14:42:45 +00:00
oana
e6a765dc35
Allow using JS Message object for Engine.replaceParams() implementation.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6297 acf43c95-373e-0410-b603-e72c3f656dc1
2018-02-12 12:07:25 +00:00
oana
be0ce880da
Add DNS.dscp() method to validate given DSCP values from Javascript.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6281 acf43c95-373e-0410-b603-e72c3f656dc1
2017-11-17 15:57:31 +00:00
paulc
78c93b5462
Added support for recursively dispatching a handled message.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6275 acf43c95-373e-0410-b603-e72c3f656dc1
2017-11-01 16:37:48 +00:00
oana
ffd790e56b
Add count() method to Javascript implementation of HashList.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6269 acf43c95-373e-0410-b603-e72c3f656dc1
2017-09-29 14:52:33 +00:00
marian
19b8dc9fe4
Fixed bug: avoid dumping ExpFunction when JSON stringifying an object.
...
git-svn-id: http://yate.null.ro/svn/yate/trunk@6267 acf43c95-373e-0410-b603-e72c3f656dc1
2017-09-19 13:56:24 +00:00
paulc
7497ff0d05
Don't attempt to DNS resolve empty, null or undefined names.
...
Added helper functions to check if an operator is missing or empty.
git-svn-id: http://yate.null.ro/svn/yate/trunk@6266 acf43c95-373e-0410-b603-e72c3f656dc1
2017-09-18 13:03:30 +00:00
oana
6f58478394
Added support for a native implementation of a Javascript HashList.
...
When generating iterator for JsObjects avoid checking that were not setting duplicates in the iterator. JsObject does not allow setting duplicates.
git-svn-id: http://yate.null.ro/svn/yate/trunk@6264 acf43c95-373e-0410-b603-e72c3f656dc1
2017-09-18 12:14:44 +00:00
andrei
d557427582
BugFix. Clear JsContext parameters before destructor is reached.
...
Clear ScriptRun stack and async tasks, before destroying the script context.
Fixed JsSemaphore prototype.
git-svn-id: http://yate.null.ro/svn/yate/trunk@6252 acf43c95-373e-0410-b603-e72c3f656dc1
2017-08-02 13:48:40 +00:00
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