@@ -23,14 +23,18 @@ use crate::{Field, FieldRef, Fields, UnionFields};
23
23
/// The set of datatypes that are supported by this implementation of Apache Arrow.
24
24
///
25
25
/// The Arrow specification on data types includes some more types.
26
- /// See also [`Schema.fbs`](https://github.com/apache/arrow/blob/master /format/Schema.fbs)
26
+ /// See also [`Schema.fbs`](https://github.com/apache/arrow/blob/main /format/Schema.fbs)
27
27
/// for Arrow's specification.
28
28
///
29
29
/// The variants of this enum include primitive fixed size types as well as parametric or
30
30
/// nested types.
31
- /// Currently the Rust implementation supports the following nested types:
31
+ /// Currently the Rust implementation supports the following nested types:
32
32
/// - `List<T>`
33
+ /// - `LargeList<T>`
34
+ /// - `FixedSizeList<T>`
33
35
/// - `Struct<T, U, V, ...>`
36
+ /// - `Union<T, U, V, ...>`
37
+ /// - `Map<K, V>`
34
38
///
35
39
/// Nested types can themselves be nested within other arrays.
36
40
/// For more information on these types please see
@@ -68,7 +72,7 @@ pub enum DataType {
68
72
///
69
73
/// Time is measured as a Unix epoch, counting the seconds from
70
74
/// 00:00:00.000 on 1 January 1970, excluding leap seconds,
71
- /// as a 64-bit integer.
75
+ /// as a signed 64-bit integer.
72
76
///
73
77
/// The time zone is a string indicating the name of a time zone, one of:
74
78
///
@@ -140,15 +144,17 @@ pub enum DataType {
140
144
/// DataType::Timestamp(TimeUnit::Second, Some("string".to_string().into()));
141
145
/// ```
142
146
Timestamp ( TimeUnit , Option < Arc < str > > ) ,
143
- /// A 32-bit date representing the elapsed time since UNIX epoch (1970-01-01)
147
+ /// A signed 32-bit date representing the elapsed time since UNIX epoch (1970-01-01)
144
148
/// in days (32 bits).
145
149
Date32 ,
146
- /// A 64-bit date representing the elapsed time since UNIX epoch (1970-01-01)
150
+ /// A signed 64-bit date representing the elapsed time since UNIX epoch (1970-01-01)
147
151
/// in milliseconds (64 bits). Values are evenly divisible by 86400000.
148
152
Date64 ,
149
- /// A 32-bit time representing the elapsed time since midnight in the unit of `TimeUnit`.
153
+ /// A signed 32-bit time representing the elapsed time since midnight in the unit of `TimeUnit`.
154
+ /// Must be either seconds or milliseconds.
150
155
Time32 ( TimeUnit ) ,
151
- /// A 64-bit time representing the elapsed time since midnight in the unit of `TimeUnit`.
156
+ /// A signed 64-bit time representing the elapsed time since midnight in the unit of `TimeUnit`.
157
+ /// Must be either microseconds or nanoseconds.
152
158
Time64 ( TimeUnit ) ,
153
159
/// Measure of elapsed time in either seconds, milliseconds, microseconds or nanoseconds.
154
160
Duration ( TimeUnit ) ,
@@ -159,35 +165,35 @@ pub enum DataType {
159
165
/// Opaque binary data of variable length.
160
166
///
161
167
/// A single Binary array can store up to [`i32::MAX`] bytes
162
- /// of binary data in total
168
+ /// of binary data in total.
163
169
Binary ,
164
170
/// Opaque binary data of fixed size.
165
171
/// Enum parameter specifies the number of bytes per value.
166
172
FixedSizeBinary ( i32 ) ,
167
173
/// Opaque binary data of variable length and 64-bit offsets.
168
174
///
169
175
/// A single LargeBinary array can store up to [`i64::MAX`] bytes
170
- /// of binary data in total
176
+ /// of binary data in total.
171
177
LargeBinary ,
172
- /// A variable-length string in Unicode with UTF-8 encoding
178
+ /// A variable-length string in Unicode with UTF-8 encoding.
173
179
///
174
180
/// A single Utf8 array can store up to [`i32::MAX`] bytes
175
- /// of string data in total
181
+ /// of string data in total.
176
182
Utf8 ,
177
183
/// A variable-length string in Unicode with UFT-8 encoding and 64-bit offsets.
178
184
///
179
185
/// A single LargeUtf8 array can store up to [`i64::MAX`] bytes
180
- /// of string data in total
186
+ /// of string data in total.
181
187
LargeUtf8 ,
182
188
/// A list of some logical data type with variable length.
183
189
///
184
- /// A single List array can store up to [`i32::MAX`] elements in total
190
+ /// A single List array can store up to [`i32::MAX`] elements in total.
185
191
List ( FieldRef ) ,
186
192
/// A list of some logical data type with fixed length.
187
193
FixedSizeList ( FieldRef , i32 ) ,
188
194
/// A list of some logical data type with variable length and 64-bit offsets.
189
195
///
190
- /// A single LargeList array can store up to [`i64::MAX`] elements in total
196
+ /// A single LargeList array can store up to [`i64::MAX`] elements in total.
191
197
LargeList ( FieldRef ) ,
192
198
/// A nested datatype that contains a number of sub-fields.
193
199
Struct ( Fields ) ,
0 commit comments