László Langó
65542549af
Add conversion API functions
...
JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
2016-06-16 14:13:06 +02:00
László Langó
8e8504244b
Update jerry API
...
* Fix error handling (related issue: #1141 )
* Move output paramters to the end of the arguments lists
JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
2016-06-16 13:43:33 +02:00
László Langó
a816ab8bb0
Use 'ecma_value_t' in API too
...
JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
2016-06-14 14:44:02 +02:00
László Langó
824d39c2a2
Update API functions
...
* Rename 'jerry_api_' prefix to 'jerry_'
* Fix minor style issues
* Group the API functions and add comment to each group
* Move engine behaviour related funtions to 'jerry.h'
JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
2016-06-08 12:48:47 +02:00
Akos Kiss
3a8d3b3bcc
Unifiy the comments of preprocessor conditionals
...
JerryScript-DCO-1.0-Signed-off-by: Akos Kiss akiss@inf.u-szeged.hu
2016-04-18 19:20:49 +02:00
François Baldassari
7b047d4b20
Add acquire_value API to simplify caller code
...
JerryScript-DCO-1.0-Signed-off-by: François Baldassari francois@pebble.com
2016-03-11 09:57:40 -08:00
Akos Kiss
25b0750756
Fix problems arising from incorrect use of various size types
...
E.g.,
* `ssize_t` was used where `lit_utf8_size_t` or `jerry_api_size_t`
would have been correct,
* `lit_utf8_size_t` was used where `ecma_length_t` would have been
correct.
Note, the patch also includes internal and public API changes:
* `ecma_string_to_utf8_string` does not return negative value if
output buffer is not large enough to contain the string; the
buffer is expected to be large enough. (`ecma_string_get_size`
can be used to retrieve the required size.)
* `jerry_api_string_to_char_buffer` adapts the same logic (and
`jerry_api_get_string_size` can be used to determine the
required size of the buffer).
Related issue: #942
JerryScript-DCO-1.0-Signed-off-by: Akos Kiss akiss@inf.u-szeged.hu
2016-03-08 15:22:07 +01:00
László Langó
a187e6d60c
Print error messages to be more informative
...
JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
2016-03-07 12:02:05 +01:00
László Langó
a0bedaa43d
Remove EXTERN_C macros and use block based solution
...
Related issue: #900
JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
2016-02-19 15:45:14 +01:00
Robert Sipka
80811c8332
Warning fixes.
...
ISO C99 doesn’t support unnamed structs/unions.
Comparison of distinct pointer types lacks a cast.
Dereferencing type-punned pointer will break strict-aliasing rules.
Type of bit-field ‘ext’ is a GCC extension.
JerryScript-DCO-1.0-Signed-off-by: Robert Sipka rsipka.uszeged@partner.samsung.com
2016-02-16 13:56:07 +01:00
László Langó
b1acf1a562
Style fix: align pointer dereference operator to right
...
JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
2016-02-05 13:06:34 +01:00
István Kádár
636ded489f
JerryScript api improvemts accordign to jerry_api_value_t struct.
...
JerryScript-DCO-1.0-Signed-off-by: István Kádár ikadar@inf.u-szeged.hu
2016-01-13 18:45:52 +03:00
Ilyong Cho
1c21e16c7b
Adding Jerry api for triggering gc.
...
JerryScript-DCO-1.0-Signed-off-by: Ilyong Cho ily.cho@samsung.com
2015-12-02 12:26:07 +03:00
pius.lee
ece246ef9e
Add foreach function for inquiry properties into obj
...
JerryScript-DCO-1.0-Signed-off-by: pius.lee pius.lee@samsung.com
2015-12-02 12:20:12 +03:00
Ruben Ayrapetyan
b7c93f170d
Remove argument names in function prototypes, declared in headers; fix '*' alignment in headers.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-09-28 18:27:10 +03:00
Andrey Shitov
311cc65b33
Implement snapshot functionality.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-09-09 18:07:24 +03:00
chunseok lee
d31eb3c4cb
Jerry API for array creation and manipulation
...
1. jerry_api_create_array_object : create array object of given size
2. jerry_api_set_array_index_value : set value at given index
3. jerry_api_get_array_index_value : get value at given index
JerryScript-DCO-1.0-Signed-off-by: chunseok lee chunseok.lee@samsung.com
2015-08-11 15:02:56 +09:00
Andrey Shitov
fd9ff8e3bd
Add core unicode functionality.
...
Add utf-8 processing routines.
Change ecma_char_t from char/uint16_t to uint16_t.
Apply all utf-8 processing routines.
Change char to jerry_api_char in API functions' declarations.
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-06-29 23:27:58 +03:00
Andrey Shitov
c4b0cd2196
Change ecma_length_t and jerry_api_length_t from uint16_t to uint32_t.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-06-29 23:27:58 +03:00
Ruben Ayrapetyan
06dffdec8f
Remove exit completion value type.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-06-29 10:24:18 +03:00
SaeHie Park
723924f36f
New External Magic String API to save heap memory
...
JerryScript-DCO-1.0-Signed-off-by: SaeHie Park saehie.park@samsung.com
2015-06-09 07:50:43 +09:00
Ilyong Cho
0c058747f1
Implemented jerry_api_create_error()
...
JerryScript-DCO-1.0-Signed-off-by: Ilyong Cho ily.cho@samsung.com
2015-05-20 19:59:46 +09:00
Andrey Shitov
9763a93df3
Add new coding style rules and fix appeared issues.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-05-14 14:44:57 +03:00
SaeHie Park
da86a52fe9
Fix object free callback.
...
- remove jerry_set_object_free_callback()
- change jerry_api_set_object_native_handle() with object_free_callback
- related issue: https://github.com/Samsung/jerryscript/issues/17
JerryScript-DCO-1.0-Signed-off-by: SaeHie Park saehie.park@samsung.com
2015-05-10 17:55:26 +09:00
SaeHie Park
5ec3e2f59a
Native callback in embedding jerry when object is to be freed.
...
JerryScript-DCO-1.0-Signed-off-by: SaeHie Park saehie.park@samsung.com
2015-05-04 19:59:58 +09:00
Ruben Ayrapetyan
cde7805356
Interface jerry_api_eval for performing eval operation.
2015-04-18 21:48:57 +03:00
Ruben Ayrapetyan
18079fb4d3
Implementing API for invocation of a function object as a constructor.
2015-04-10 09:55:04 +03:00
Ruben Ayrapetyan
469ef4e622
Implementing API for associating native handle (uintptr_t) values with JS objects.
2015-04-07 13:01:01 +03:00
Ruben Ayrapetyan
6594a7359b
Supporting return values in functions of plugins.
2015-04-07 12:42:55 +03:00
Ruben Ayrapetyan
83730cd6bb
Implementing dispatcher for calling native handlers associated with external function objects; implementing interface for unified storage of native pointers in ecma objects.
2015-04-03 23:38:52 +03:00
Ilyong Cho
23ade8f4ff
wip: Implementing external function api
2015-04-03 18:11:21 +09:00
Ruben Ayrapetyan
eb3686a49d
Adding jerry_api_is_constructor interface that check if specified object is a function object that implement [[Construct]] method; changing jerry_api_is_function to recognize bound and built-in functions; optimizing jerry_api_call_function.
2015-04-01 12:39:29 +03:00
Ilyong Cho
3c2009d331
Adding Jerry api for calling function with specific this binding.
2015-04-01 11:06:20 +09:00
Ruben Ayrapetyan
33cfaa73b3
Implementation of unimplemented Jerry API parts; adding Jerry API unit test based on test prepared by Ilyong.
2015-03-30 20:54:55 +03:00
Ilyong Cho
cf5e158510
Implement some Jerry API / jerry_api_call_function() and jerry_api_get_object_field_value()
2015-03-30 16:04:49 +09:00
Ruben Ayrapetyan
9746b2fd76
Jerry API for calling functions C -> Jerry, creating objects, reading / writing object's properties (currently, only interface declaration, without implementation).
2015-03-27 18:05:27 +03:00