pub struct FileProcessor;
Expand description
Core file processor
Implementations§
Source§impl FileProcessor
impl FileProcessor
Sourcepub fn process_file(
file_path: &str,
config: &BatlessConfig,
) -> BatlessResult<FileInfo>
pub fn process_file( file_path: &str, config: &BatlessConfig, ) -> BatlessResult<FileInfo>
Process a file according to the given configuration
Sourcepub fn process_stdin(config: &BatlessConfig) -> BatlessResult<FileInfo>
pub fn process_stdin(config: &BatlessConfig) -> BatlessResult<FileInfo>
Process input from stdin
Sourcepub fn detect_encoding(file_path: &str) -> BatlessResult<String>
pub fn detect_encoding(file_path: &str) -> BatlessResult<String>
Detect file encoding
Sourcepub fn validate_file_access(file_path: &str) -> BatlessResult<()>
pub fn validate_file_access(file_path: &str) -> BatlessResult<()>
Validate file accessibility and permissions
Sourcepub fn get_file_size(file_path: &str) -> BatlessResult<u64>
pub fn get_file_size(file_path: &str) -> BatlessResult<u64>
Get file size without reading the entire file
Sourcepub fn is_likely_binary(file_path: &str) -> BatlessResult<bool>
pub fn is_likely_binary(file_path: &str) -> BatlessResult<bool>
Check if a file is likely to be binary
Auto Trait Implementations§
impl Freeze for FileProcessor
impl RefUnwindSafe for FileProcessor
impl Send for FileProcessor
impl Sync for FileProcessor
impl Unpin for FileProcessor
impl UnwindSafe for FileProcessor
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more