progval commented on code in PR #5863:
URL: https://github.com/apache/arrow-rs/pull/5863#discussion_r1634462067
##########
parquet/src/file/properties.rs:
##########
@@ -299,7 +299,7 @@ impl WriterProperties {
.unwrap_or(DEFAULT_DICTIONARY_ENABLED)
}
- /// Returns `true` if statistics are enabled for a column.
+ /// Returns the type of statistics written for a column.
Review Comment:
```suggestion
/// Returns which statistics are written for a column.
```
seems more accurate, as there are two different types of statistics and they
are not mutually exclusive
##########
parquet/src/file/properties.rs:
##########
@@ -575,37 +608,42 @@ impl WriterPropertiesBuilder {
self.column_properties.entry(col).or_default()
}
- /// Sets encoding for a column.
- /// Takes precedence over globally defined settings.
+ /// Sets encoding for a specific column.
+ ///
+ /// Takes precedence over [`Self::set_encoding`].
///
/// If dictionary is not enabled, this is treated as a primary encoding
for this
/// column. In case when dictionary is enabled for this column, either
through
/// global defaults or explicitly, this value is considered to be a
fallback
/// encoding for this column.
///
- /// Panics if user tries to set dictionary encoding here, regardless of
dictionary
+ /// # Panics
+ /// If user tries to set dictionary encoding here, regardless of dictionary
/// encoding flag being set.
pub fn set_column_encoding(mut self, col: ColumnPath, value: Encoding) ->
Self {
self.get_mut_props(col).set_encoding(value);
self
}
- /// Sets compression codec for a column.
- /// Takes precedence over globally defined settings.
+ /// Sets compression codec for a specific column.
+ ///
+ /// Takes precedence over [`Self::set_compression`].
pub fn set_column_compression(mut self, col: ColumnPath, value:
Compression) -> Self {
self.get_mut_props(col).set_compression(value);
self
}
- /// Sets flag to enable/disable dictionary encoding for a column.
- /// Takes precedence over globally defined settings.
+ /// Sets flag to enable/disable dictionary encoding for a specific column.
+ ///
+ /// Takes precedence over [`Self::set_dictionary_enabled`].
pub fn set_column_dictionary_enabled(mut self, col: ColumnPath, value:
bool) -> Self {
self.get_mut_props(col).set_dictionary_enabled(value);
self
}
- /// Sets flag to enable/disable statistics for a column.
- /// Takes precedence over globally defined settings.
+ /// Sets flag to enable/disable statistics for a specific column.
+ ///
+ /// Takes precedence over [`Self::set_statistics_enabled`].
Review Comment:
```suggestion
/// Sets statistics level for a specific column.
///
/// Takes precedence over [`Self::set_statistics_enabled`].
```
to be consistent with `set_statistics_enabled`'s phrasing
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]