Skip to content

[Rust] impl AsRef for StringBuilder/BinaryBuilder #27629

@asfimport

Description

@asfimport

The current implementation of Arrow forces the users to pass a reference to the append_value methods of StringBuilder/BinaryBuilder. Whereas it is passed by value for other types of builders.  This patch suggests adding impl AsRef<[u8]> rather than the current &[u8] parameter.

Some background for this issue: I have a Rust derive macro which converts the specified struct to Arrow data. This macro assumes everything is passed by value to Arrow, hence the dilemma. 

Reporter: Max Meldrum

Externally tracked issue: #9570

PRs and other links:

Note: This issue was originally created as ARROW-11777. Please see the migration documentation for further details.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions