| Crates.io | class-rs |
| lib.rs | class-rs |
| version | 0.4.0 |
| created_at | 2025-01-04 02:13:15.151976+00 |
| updated_at | 2025-03-01 01:03:44.587194+00 |
| description | Reads/writes a .class file into/from an almost 1-to-1 matching struct |
| homepage | |
| repository | https://github.com/minirop/class-rs |
| max_upload_size | |
| id | 1503571 |
| size | 142,441 |
Reads a .class file into an almost 1-to-1 matching struct or generates a .class file from said structure.
⚠️ Constant::Utf8 are using Rust's String type and not the JVM's modified UTF-8. If you have a string that makes that crate panic, open an issue.
let mut jvm = JVMClass::new();
let mut file = std::fs::File::open("Test.class").unwrap();
jvm.load(&mut file).unwrap();
let mut fs = std::fs::File::create("Test2.class").unwrap();
jvm.store(&mut fs).unwrap();