Skip to content

Commit

Permalink
add rustdoc
Browse files Browse the repository at this point in the history
  • Loading branch information
jimexist committed Nov 16, 2022
1 parent acd26ce commit 7ee3aa2
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions parquet/src/bloom_filter/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ impl Sbbf {
Self(data)
}

/// Write the bitset in serialized form to the writer.
pub fn write_bitset<W: Write>(&self, mut writer: W) -> Result<(), ParquetError> {
for block in &self.0 {
for word in block {
Expand All @@ -145,6 +146,7 @@ impl Sbbf {
Ok(())
}

/// Create and populate [`BloomFilterHeader`] from this bitset for writing to serialized form
pub fn header(&self) -> BloomFilterHeader {
BloomFilterHeader {
// 8 i32 per block, 4 bytes per i32
Expand All @@ -155,6 +157,7 @@ impl Sbbf {
}
}

/// Read a new bloom filter from the given offset in the given reader.
pub fn read_from_column_chunk<R: ChunkReader>(
column_metadata: &ColumnChunkMetaData,
reader: Arc<R>,
Expand Down

0 comments on commit 7ee3aa2

Please sign in to comment.