emixcore 0.6.0

Shared error handling, debug configuration, and foundational traits for EssentialMix.
Documentation
  • Coverage
  • 0%
    0 out of 40 items documented0 out of 7 items with examples
  • Size
  • Source code size: 12.61 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 584.54 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 13s Average build duration of successful builds.
  • all releases: 13s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • asm2025/essentialMix-rs
    1 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • asm2025

emixcore

emixcore provides the shared error type, debug configuration toggle, and core traits that the other EssentialMix crates build upon.

Highlights

  • Error wraps workspace-specific failures while implementing std::error::Error.
  • Result<T> aliases std::result::Result<T, Error>.
  • set_debug / is_debug flip a global once-initialized flag used by helper crates.
  • system::num_cpus() respects the debug flag to make deterministic unit tests easier (returns 1 CPU when debug mode is active).
  • CallbackHandler<T> is a lightweight observer trait for progress reporting.

Quick Example

use emixcore::{set_debug, system, CallbackHandler};

struct Logger;

impl CallbackHandler<u64> for Logger {
    fn starting(&self) { println!("Starting"); }
    fn update(&self, progress: u64) { println!("Progress: {progress}%"); }
    fn completed(&self) { println!("Done"); }
}

fn main() {
    set_debug(true);
    assert_eq!(system::num_cpus(), 1);
}

Consult src/errors.rs for the detailed error taxonomy and tests/ for real-world integration coverage.