Module utilfn

Module utilfn 

Source
Expand description

Utility functions ported from Go’s pkg/util/utilfn/utilfn.go.

Includes null encoding/decoding, hashing, binary detection, star matching, slice operations, string helpers, and atomic file operations.

Re-exports§

pub use hash::quick_hash_string;
pub use hash::sha1_hash;
pub use nullenc::decode_string_array;
pub use nullenc::decode_string_map;
pub use nullenc::encode_string_array;
pub use nullenc::encode_string_map;
pub use nullenc::encoded_string_array_get_first_val;
pub use nullenc::encoded_string_array_has_first_val;
pub use nullenc::null_decode_str;
pub use nullenc::null_encode_str;
pub use strutil::add_elem_uniq;
pub use strutil::atomic_rename_copy;
pub use strutil::atoi_no_err;
pub use strutil::combine_str_arrays;
pub use strutil::ellipsis_str;
pub use strutil::filter_valid_arch;
pub use strutil::get_first_line;
pub use strutil::get_line_col_from_offset;
pub use strutil::has_binary_data;
pub use strutil::indent_string;
pub use strutil::is_binary_content;
pub use strutil::longest_prefix;
pub use strutil::move_to_front;
pub use strutil::random_hex_string;
pub use strutil::remove_elem;
pub use strutil::shell_hex_escape;
pub use strutil::slice_idx;
pub use strutil::star_match_string;
pub use strutil::truncate_string;
pub use strutil::write_file_if_different;
pub use strutil::StrWithPos;
pub use strutil::NO_STR_POS;

Modules§

hash
nullenc
strutil