zanmato1984 commented on code in PR #44394:
URL: https://github.com/apache/arrow/pull/44394#discussion_r1879209887


##########
cpp/src/arrow/compute/api_vector.h:
##########
@@ -257,6 +257,38 @@ class ARROW_EXPORT ListFlattenOptions : public 
FunctionOptions {
   bool recursive = false;
 };
 
+/// \brief Options for inverse_permutation function
+class ARROW_EXPORT InversePermutationOptions : public FunctionOptions {
+ public:
+  explicit InversePermutationOptions(int64_t max_index = -1,
+                                     std::shared_ptr<DataType> output_type = 
NULLPTR);
+  static constexpr char const kTypeName[] = "InversePermutationOptions";
+  static InversePermutationOptions Defaults() { return 
InversePermutationOptions(); }
+
+  /// \brief The max value in the input indices to process. Any indices that 
are greater
+  /// than this value will be ignored. If negative, this value will be set to 
the length
+  /// of the input indices minus 1.
+  int64_t max_index = -1;
+  /// \brief The type of the output inverse permutation. If null, the output 
will be of
+  /// the same type as the input indices, otherwise must be integer types. An 
invalid
+  /// error will be reported if this type is not able to store the length of 
the input
+  /// indices.
+  std::shared_ptr<DataType> output_type = NULLPTR;
+};
+
+/// \brief Options for scatter function
+class ARROW_EXPORT ScatterOptions : public FunctionOptions {
+ public:
+  explicit ScatterOptions(int64_t max_index = -1);
+  static constexpr char const kTypeName[] = "ScatterOptions";
+  static ScatterOptions Defaults() { return ScatterOptions(); }
+
+  /// \brief The max value in the input indices to process. Any values with 
indices that
+  /// are greater than this value will be ignored. If negative, this value 
will be set to
+  /// the length of the input minus 1.
+  int64_t max_index = -1;

Review Comment:
   Hmm, it was exactly `output_length` until I modified it according to 
@felipecrv 's suggestion. See 
https://github.com/apache/arrow/pull/44394#discussion_r1823608408



-- 
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: github-unsubscr...@arrow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to