ristretto_classloader 0.6.0

A library for loading Java classes.
Documentation

Ristretto ClassLoader

ci Documentation Code Coverage Benchmarks Latest version License Semantic Versioning

Getting Started

Implementation of a JVM Class Loader that is used to load Java classes.

Examples

use ristretto_classloader::{ClassLoader, ClassPath, Result};
use std::sync::Arc;

#[tokio::main]
async fn main() -> Result<()> {
    let class_path = ClassPath::from("classes").await?;
    let class_loader = Arc::new(ClassLoader::new("example", class_path));
    let class = ClassLoader::load_class(&class_loader, "HelloWorld").await?;
    println!("{class:?}");
    Ok(())
}

Feature flags

The following features are available:

Name Description Default?
url Enables url class path entries No

Safety

These crates use #![forbid(unsafe_code)] to ensure everything is implemented in 100% safe Rust.

License

Licensed under either of

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.