lidavidm commented on a change in pull request #11818:
URL: https://github.com/apache/arrow/pull/11818#discussion_r759648779
##########
File path: cpp/src/arrow/compute/api_scalar.h
##########
@@ -108,6 +108,32 @@ class ARROW_EXPORT RoundToMultipleOptions : public
FunctionOptions {
RoundMode round_mode;
};
+class ARROW_EXPORT RoundTemporalOptions : public FunctionOptions {
+ public:
+ enum Ambiguous { AMBIGUOUS_RAISE, AMBIGUOUS_EARLIEST, AMBIGUOUS_LATEST };
+ enum Nonexistent { NONEXISTENT_RAISE, NONEXISTENT_EARLIEST,
NONEXISTENT_LATEST };
+
+ explicit RoundTemporalOptions(std::string frequency = "day",
Review comment:
I realize this is just a draft :) that said, should be an enum as well?
##########
File path: cpp/src/arrow/compute/api_scalar.cc
##########
@@ -228,6 +268,12 @@ static auto kRoundOptionsType =
GetFunctionOptionsType<RoundOptions>(
static auto kRoundToMultipleOptionsType =
GetFunctionOptionsType<RoundToMultipleOptions>(
DataMember("multiple", &RoundToMultipleOptions::multiple),
DataMember("round_mode", &RoundToMultipleOptions::round_mode));
+static auto kRoundTemporalOptionsType =
GetFunctionOptionsType<RoundTemporalOptions>(
Review comment:
nit: another contributor just alphabetized these, so maybe try to
preserve that (same goes below).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]