feat(flow-php/array-dot): Path value object for dot paths - #2625
Merged
Merged
Conversation
- parse paths once into typed Path/Step, escapes for every grammar character - array_dot_set/rename change only the addressed key - array_get() resolves nullsafe types and escaped keys - array_get_collection() reads literal keys - array_expand() over a null list gives no rows - structure_get(), structure_get_collection(), structure_get_collection_first() aliases
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## 1.x #2625 +/- ##
============================================
+ Coverage 84.33% 84.37% +0.04%
- Complexity 29801 29844 +43
============================================
Files 1988 1992 +4
Lines 86474 86544 +70
============================================
+ Hits 72927 73024 +97
+ Misses 13547 13520 -27 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Change Log
Added
flow-php/array-dot-Pathvalue object withKey,WildcardandMultimatchstepsflow-php/array-dot-Path|stringaccepted by everyarray_dot_*functionflow-php/etl-structure_get(),structure_get_collection(),structure_get_collection_first()DSL aliasesFixed
flow-php/etl-array_get()schema for nullsafe and escaped path segmentsflow-php/array-dot- escapes after a wildcard and inside a multimatchflow-php/array-dot-array_dot_set()keeps sibling and integer keysflow-php/array-dot-array_dot_rename()to the same name no longer deletes the keyflow-php/array-dot- nullsafe multimatch over an empty array readsnullChanged
flow-php/array-dot-\escapes every path grammar characterflow-php/array-dot-array_dot_rename()refuses a path not ending with a keyflow-php/etl-array_get_collection()reads its keys as literal keysflow-php/etl-array_expand()over a null list gives no rowsflow-php/etl-array_get()throwsInvalidArgumentExceptionfor a malformed pathRemoved
Deprecated
flow-php/array-dot-array_dot_steps(), usePath::fromString()Security