Commit Graph

162 Commits

Author SHA1 Message Date
Daniel Lemire 9627831b5f some minor fixes 2025-08-05 17:02:13 -04:00
Joseph Olabisi 6c5ada32b9 remove unneccessary string allocation 2025-07-22 21:03:02 +01:00
Joseph Olabisi 1589d15361 fix 2025-07-21 22:34:17 +01:00
Joseph Olabisi c58f5dda2d minor changes 2025-07-21 21:45:31 +01:00
Joseph Olabisi 5753f54f6c fix boundary check and unnecessary string allocation 2025-07-21 21:31:47 +01:00
Joseph Olabisi 29ef75c783 fix bug with array, add boundary check to get_next_key_and_json_path function 2025-07-21 20:58:49 +01:00
Joseph Olabisi c3d45c7758 refactor process_json_path_of_child_element from recursion to loop in order to prevent stack overflow 2025-07-16 20:35:52 +01:00
Joseph Olabisi 3fda1b9c7d minor error handling 2025-07-14 01:35:19 +01:00
Joseph Olabisi fdcea9ad22 refactor and create util for getting key and json path 2025-07-14 01:15:02 +01:00
Joseph Olabisi 3350ce97ba fix logic for wildcards inside arrays 2025-07-14 00:14:56 +01:00
Joseph Olabisi 61ec1fb659 fix bug in object-inl.h 2025-07-12 16:43:38 +01:00
Joseph Olabisi bfc8b89e6b final changes based on feedback - reduce string allocations 2025-07-10 17:10:25 +01:00
Joseph Olabisi 1382432686 address additional feedbacks (copilot) 2025-07-10 14:28:32 +01:00
Joseph Olabisi bebbf830fb address some feedbacks 2025-07-10 13:24:07 +01:00
Joseph Olabisi 120e69f13c cleanup object-inl.h 2025-05-06 14:51:25 +01:00
Joseph Olabisi 14922fa6c4 revert object-inl.h 2025-05-06 14:37:50 +01:00
Joseph Olabisi 8fa2629c84 cleanup array-inl.h 2025-05-06 02:05:58 +01:00
Joseph Olabisi c51c2d2ce9 revert array-inl.h 2025-05-06 01:55:21 +01:00
Joseph Olabisi 1a11e19d07 cleanup 2025-05-03 13:46:11 +01:00
Joseph Olabisi 671a81f4e3 nit 2025-04-27 00:02:23 +01:00
Joseph Olabisi 008d89eb56 corrected logic 2025-04-26 21:01:05 +01:00
Joseph Olabisi 531567ae94 approximately 30% improvement in runtime 2025-04-18 22:52:12 +01:00
Joseph Olabisi 46ae2d250f nit 2025-04-18 22:19:49 +01:00
Joseph Olabisi c35122bcb4 refactor to tail recursion 2025-04-18 21:43:44 +01:00
Joseph Olabisi f380604de5 minor improvements 2025-04-18 21:05:35 +01:00
Joseph Olabisi 00d01ea0f5 use memcmp 2025-04-15 11:22:43 +01:00
Joseph Olabisi c9ccb2d139 rename at_path_new to at_path_with_wildcard 2025-04-08 08:43:46 +01:00
Joseph Olabisi d99072982f handle array INCORRECT_TYPE 2025-04-05 20:52:53 +01:00
Joseph Olabisi 6b7f987cd5 add support for wildcard for arrays 2025-04-05 20:14:00 +01:00
Joseph Olabisi d32cd20ce6 fix key 2025-04-01 09:31:43 +01:00
Joseph Olabisi 2013a46518 done - handling child properties of wildcard result 2025-03-29 18:40:40 +00:00
Joseph Olabisi 6cb1911d3a wip - handling child properties of wildcard result 2025-03-26 10:31:58 +00:00
Joseph Olabisi 9ff7d2ccbe wip 2025-03-25 09:59:22 +00:00
Joseph Olabisi fa4a4ad8f0 wip - nested paths/pointers on wildcard results 2025-03-23 23:02:55 +00:00
Joseph Olabisi de6ad3c60c partially handle keys with wildcard 2025-03-21 22:31:47 +00:00
Joseph Olabisi 78025fdd64 wip brute-force wildcard for json_path 2025-03-11 21:16:26 +00:00
Daniel Lemire 587beae307 prevent int to pointer implicit conversion for operator[](const char *) (#2286) 2024-11-01 18:11:43 -04:00
Daniel Lemire 6cd8a6d776 adding pad function (#2283) 2024-10-29 21:26:01 -04:00
Daniel Lemire 36f5dbcb75 documentation for threading... (#2277)
* documentation for threading...

* remove const

* doc
2024-10-11 12:34:11 -04:00
Daniel Lemire c066b5421b Jsonpath (#2272)
* Add support for JSONPath with '$' prefix and integrate into dom::at_path (#2266)

- Updated `json_path_to_pointer_conversion` to support JSONPath starting with the '$' prefix, while maintaining compatibility with the existing implementation.
- Moved `json_path_to_pointer_conversion` to a separate header file for better modularity and to support JSONPath queries in `dom` mode.
- Implemented `at_path` functionality in `dom` mode to enable querying JSON using JSONPath.
- Added unit tests to validate the new JSONPath support in `dom` mode and ensure compatibility with both standard and existing JSONPath formats.

* two minor fixes

* more tests and documentation

* damn compiler warnings

* more documentation fixes

---------

Co-authored-by: Zhengguo Yang <yangzhgg@gmail.com>
2024-10-08 10:37:59 -04:00
didarpin 58173a6a1f Added the functionality to convert dom::object and dom::array to dom::element. (#2221)
Co-authored-by: didarpin <didarpin@163.com>
2024-07-25 22:26:20 -04:00
Daniel Lemire 66fd28fc00 Marking a few functions as pure (no side-effect) (#2210)
* marking a few trivial functions as pure

* adding other marks

* additional marks

* vs will issue warnings, so don't use [[gnu::pure]] when __clang__ or __GNUC__ is not defined
2024-07-04 16:26:11 -04:00
halx99 5d35e7ca1f Fix compile error on llvm-19 (#2187) 2024-05-30 10:52:38 -04:00
Daniel Lemire ac719827ff fix: solve issue 2181 (#2182) 2024-05-11 20:44:38 -04:00
pnck e2f879751c fix: issue #2154 (#2178) 2024-05-10 00:33:09 -04:00
Daniel Lemire 8519e24f12 issue 2170 (#2172) 2024-04-24 01:41:40 -04:00
Daniel Lemire c4654553dd [skip ci] windows and unicode 2024-03-26 09:31:50 -04:00
Daniel Lemire e510ed2774 Release candidate (3.7.0) (#2136)
* Release candidate (3.7.0)

* some extra comments.
2024-02-23 16:50:55 -05:00
Bo Anderson 33610b59eb Allow some iterators to be used in standard C++ iterator functions (#2106) 2024-02-05 17:52:01 -05:00
Daniel Lemire 23290ae48d retiring deprecated DOM APIs (#2109) 2024-02-04 21:58:48 -05:00