Commits


Kevin Gurney authored and GitHub committed 3262debb107
GH-37252: [MATLAB] Add `arrow.type.DateUnit` enumeration class (#37280) ### Rationale for this change In support of adding `arrow.type.Date32Type` and `arrow.type.Date64Type`, this pull request adds a `arrow.type.DateUnit` enumeration class mirroring the `arrow.type.TimeUnit` enumeration class. `arrow.type.DateUnit` will have two values: `Day` and `Millisecond`. ### What changes are included in this PR? 1. Added a new enumeration class `arrow.type.DateUnit` which mirrors the `arrow.type.TimeUnit` enumeration class. **Example**: ```matlab >> day = arrow.type.DateUnit.Day day = DateUnit enumeration Day >> millisecond = arrow.type.DateUnit.Millisecond millisecond = DateUnit enumeration Millisecond ``` ### Are these changes tested? Yes. 1. Added a new test class `tDateUnit` for `arrow.type.DateUnit` tests. 2. Updated code for `tTimeUnit` for consistency with `tDateUnit`. ### Are there any user-facing changes? Yes. 1. There is now a new user-facing `arrow.type.DateUnit` enumeration class. ### Future Directions 1. Add an `arrow.internal.validate.temporal.dateUnit` helper function that mirrors `arrow.internal.validate.temporal.timeUnit`. 2. #37229 3. #37230 * Closes: #37252 Lead-authored-by: Kevin Gurney <kgurney@mathworks.com> Co-authored-by: Sarah Gilmore <sgilmore@mathworks.com> Signed-off-by: Kevin Gurney <kgurney@mathworks.com>