aboutsummaryrefslogtreecommitdiff
path: root/jerry-ext/arg/arg-transform-functions.c
AgeCommit message (Collapse)Author
2021-12-06Rework the public API (#4829)Dániel Bátyai
Related to #4186. Some notable changes: - The term 'Error' now strictly refers to native Error objects defined in the ECMA standard, which are ordinary objects. All other uses of 'error' or 'error reference' where the term refers to a thrown value is now called 'exception'. - Simplified the naming scheme of many String API functions. These functions will now also take an 'encoding' argument to specify the desired encoding in which to operate. - Removed the substring-copy-to-buffer functions. These functions behaved awkwardly, as they use character index to specify the start/end positions, and were mostly used incorrectly with byte offsets instead. The functionality can still be replicated with other functions if necessary. - String-to-buffer functions will no longer fail if the buffer is not sufficiently large, the string will instead be cropped. - Fixed the usage of the '_sz' prefix in many API functions. The term 'sz' means zero-terminated string in hungarian notation, this was used incorrectly in many cases. - Renamed most of the public API functions to have shorter, more on-point names, rather than the often too long descriptive names. Functions are now also grouped by the type of value they operate on, where this makes sense. JerryScript-DCO-1.0-Signed-off-by: Dániel Bátyai dbatyai@inf.u-szeged.hu
2021-11-05Replace vera++ with clang-format (#4518)Robert Fancsik
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik robert.fancsik@h-lab.eu
2021-06-24Remove jerry_get_boolean_value (#4685)Gergo Csizi
JerryScript-DCO-1.0-Signed-off-by: Gergo Csizi csgergo92@gmail.com
2021-01-11Replace isnan with inequality check to avoid conversion warning in older ↵Akos Kiss
Clang (#4438) JerryScript-DCO-1.0-Signed-off-by: Akos Kiss akiss@inf.u-szeged.hu
2019-07-17Optional arguments should advance the iterator in ↵Robert Fancsik
jerryx_arg_transform_optional (#2962) This patch fixes #2288 JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu
2019-04-16Allow the JS objects to have more than one native pointer data (#2814)Robert Fancsik
Currently JS objects can only have one native pointer data which could be a limitation in special cases. This patch allows to register multiple native infos, which can be accessed/associated with the corresponding `jerry_object_native_info_t`. JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu
2019-01-21Use union to convert between jerryx_arg_int_option_t and uintptr_t (#2718)Akos Kiss
This fixes potential out-of-bounds reads in jerry-ext when dealing with integer argument mappings. Fixes #2713 JerryScript-DCO-1.0-Signed-off-by: Akos Kiss akiss@inf.u-szeged.hu
2018-05-03Rename the jerry_value_has_error_flag function. (#2290)Istvan Miklos
Rename the function to represent it's real functionality. JerryScript-DCO-1.0-Signed-off-by: Istvan Miklos imiklos2@inf.u-szeged.hu
2018-01-08[jerryx/arg]add jerryx_arg_utf8_string (#2133)Zidong Jiang
JerryScript-DCO-1.0-Signed-off-by: Zidong Jiang zidong.jiang@intel.com
2017-10-30jerryx: add jerryx_arg_array (#2052)Zidong Jiang
Related issue: #2046 JerryScript-DCO-1.0-Signed-off-by: Zidong Jiang zidong.jiang@intel.com
2017-08-17[jerryx-arg]Check NaN in jerryx_arg_intZidong Jiang
JerryScript-DCO-1.0-Signed-off-by: Zidong Jiang zidong.jiang@intel.com
2017-07-14Fix empty string issue in ext/args (#1921)Zidong Jiang
Now the js string "" can be converted to C array by jerryx_arg_string JerryScript-DCO-1.0-Signed-off-by: Zidong Jiang zidong.jiang@intel.com
2017-07-04Fix build warning in jerry-ext/arg on tizenrt-artik05xSanggyu Lee
tizenrt-arttik05x treats warning as error for uninitialized use. This patch fixes the error in jerry-ext/arg by initializing to zero. JerryScript-DCO-1.0-Signed-off-by: Sanggyu Lee sg5.lee@samsung.com
2017-06-21add transform functions for integer in jerryx/arg (#1883)Zidong Jiang
JerryScript-DCO-1.0-Signed-off-by: Zidong Jiang zidong.jiang@intel.com
2017-06-19add transform_object_properties in jerryx/arg (#1879)Zidong Jiang
Add a function in jerryx/arg. jerryx_arg_transform_object_properties, it will validate the properties of a JS object, and convert those properties into native type. JerryScript-DCO-1.0-Signed-off-by: Zidong Jiang zidong.jiang@intel.com
2017-05-22jerryx_arg: add '\0' when transforming string (#1827)Zidong Jiang
Related issue: #1824 JerryScript-DCO-1.0-Signed-off-by: Zidong Jiang zidong.jiang@intel.com
2017-05-04A tool in jerry-ext: arg transformer for binding (#1740)Zidong Jiang
It provides some APIs for binding developers, so that they can validate the type of the js argument and convert/assign them to the native argument. Related Issue: #1716 JerryScript-DCO-1.0-Signed-off-by: Martijn The martijn.the@intel.com JerryScript-DCO-1.0-Signed-off-by: Zidong Jiang zidong.jiang@intel.com