Skip to main content

Module display

Module display 

Source
Expand description

Functions for printing array values as human-readable strings.

This is often used for debugging or logging purposes.

See the pretty crate for additional functions for record batch pretty printing.

Re-exportsยง

use std::fmt::Debug; ๐Ÿ”’
use std::fmt::Debug; ๐Ÿ”’
use std::fmt::Display; ๐Ÿ”’
use std::fmt::Formatter; ๐Ÿ”’
use std::fmt::Write; ๐Ÿ”’
use std::hash::Hash; ๐Ÿ”’
use std::hash::Hash; ๐Ÿ”’
use std::hash::Hasher; ๐Ÿ”’
use std::ops::Range; ๐Ÿ”’
use arrow_array::timezone::Tz; ๐Ÿ”’
use arrow_buffer::ArrowNativeType; ๐Ÿ”’
use arrow_data::decimal::write_decimal; ๐Ÿ”’
use chrono::format::Item; ๐Ÿ”’
use chrono::format::StrftimeItems; ๐Ÿ”’
use chrono::NaiveDate; ๐Ÿ”’
use chrono::NaiveDateTime; ๐Ÿ”’
use chrono::Offset; ๐Ÿ”’
use chrono::SecondsFormat; ๐Ÿ”’
use chrono::TimeZone; ๐Ÿ”’
use chrono::Utc; ๐Ÿ”’
use lexical_core::FormattedSize; ๐Ÿ”’
use arrow_array::cast::*; ๐Ÿ”’
use arrow_array::temporal_conversions::*; ๐Ÿ”’
use arrow_array::types::*; ๐Ÿ”’
use arrow_array::*; ๐Ÿ”’
use arrow_schema::*; ๐Ÿ”’

Macrosยง

decimal_display ๐Ÿ”’
duration_display ๐Ÿ”’
Derive DisplayIndexState for PrimitiveArray<$t>
duration_fmt ๐Ÿ”’
duration_option_display ๐Ÿ”’
Similar to duration_display but $convert returns an Option
primitive_display ๐Ÿ”’
primitive_display_float ๐Ÿ”’
temporal_display ๐Ÿ”’
timestamp_display ๐Ÿ”’

Structsยง

ArrayFormat ๐Ÿ”’
ArrayFormatter
A string formatter for an [Array]
CompiledItems ๐Ÿ”’
FormatOptions
Options for formatting arrays
MillisecondsFormatter ๐Ÿ”’
NanosecondsFormatter ๐Ÿ”’
ValueFormatter
Implements Display for a specific array value

Enumsยง

CompiledTimeFormat ๐Ÿ”’
DurationFormat
Format for displaying durations
FormatError
Either an [ArrowError] or std::fmt::Error

Traitsยง

ArrayFormatterFactory
Allows creating a new ArrayFormatter for a given [Array] and an optional [Field].
DisplayIndex
Display but accepting an index
DisplayIndexState ๐Ÿ”’
DisplayIndex with additional state

Functionsยง

array_format ๐Ÿ”’
array_value_to_string
Get the value at the given row in an array as a String.
date32_to_date ๐Ÿ”’
lexical_to_string
Converts numeric type to a String
make_array_formatter ๐Ÿ”’
Used to create a new ArrayFormatter from the given array, while also checking whether there is an override available in the ArrayFormatterFactory.
make_default_display_index ๐Ÿ”’
write_list ๐Ÿ”’
write_timestamp ๐Ÿ”’

Type Aliasesยง

FieldDisplay ๐Ÿ”’
Pairs an ArrayFormatter with its field name
FormatResult
The result of formatting an array element via DisplayIndex::write.
TimeFormat ๐Ÿ”’