You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@arrow.apache.org by "Ben Kietzman (Jira)" <ji...@apache.org> on 2021/06/09 16:28:00 UTC
[jira] [Created] (ARROW-13025) [C++][Compute] Enhance
FunctionOptions with equality, debug representability, and serializability
Ben Kietzman created ARROW-13025:
------------------------------------
Summary: [C++][Compute] Enhance FunctionOptions with equality, debug representability, and serializability
Key: ARROW-13025
URL: https://issues.apache.org/jira/browse/ARROW-13025
Project: Apache Arrow
Issue Type: Improvement
Components: C++
Reporter: Ben Kietzman
Fix For: 5.0.0
Currently the {{FunctionOptions}} interface is entirely opaque. It would be useful to add
- equality comparability {code}
bool FunctionOptions::Equals(const FunctionOptions& other) const
{code}
- debug representation {code}
std::string FunctionOptions::ToString() const
{code}
- serializability {code}
Status FunctionOptions::Serialize(io::OutputStream*) const
Result<std::unique_ptr<FunctionOptions>>
FunctionOptions::Deserialize(io::InputStream*)
{code} (or similar)
These are already implemented for common instances of {{FunctionOptions}} in expression.cc, since {{Expression}} has the above capabilities and may contain a {{FunctionOptions}}. Making these explicit virtual functions will formalize this ad-hoc
code and expose it for direct unit testing.
As an added bonus, if options can serialize themselves to JSON then that can be used by Python and other bindings to generate wrappers instead of the current hand-written listing of wrapper classes for each {{FunctionOptions}} subclass
--
This message was sent by Atlassian Jira
(v8.3.4#803005)