#![allow(dead_code)]
use std::path::Path;
use anyhow::Result;
#[path = "io/bytes.rs"]
mod bytes;
#[path = "io/read.rs"]
mod read;
#[path = "io/tags.rs"]
mod tags;
pub fn read_head(path: &Path, max_bytes: usize) -> Result<Vec<u8>> {
read::read_head(path, max_bytes)
}
pub fn read_head_tail(path: &Path, max_bytes: usize) -> Result<Vec<u8>> {
read::read_head_tail(path, max_bytes)
}
pub fn read_lines(path: &Path, max_lines: usize, max_bytes: usize) -> Result<Vec<String>> {
read::read_lines(path, max_lines, max_bytes)
}
pub fn read_text_capped(path: &Path, max_bytes: usize) -> Result<String> {
read::read_text_capped(path, max_bytes)
}
pub fn is_text_like(bytes: &[u8]) -> bool {
bytes::is_text_like(bytes)
}
pub fn hash_bytes(bytes: &[u8]) -> String {
bytes::hash_bytes(bytes)
}
pub fn hash_file(path: &Path, max_bytes: usize) -> Result<String> {
bytes::hash_file(path, max_bytes)
}
pub fn count_tags(text: &str, tag_names: &[&str]) -> Vec<(String, usize)> {
tags::count_tags(text, tag_names)
}
pub(crate) fn count_delimited_tags(text: &str, tag_names: &[&str]) -> Vec<(String, usize)> {
tags::count_delimited_tags(text, tag_names)
}
pub fn entropy_bits_per_byte(bytes: &[u8]) -> f32 {
bytes::entropy_bits_per_byte(bytes)
}