bcur 0.1.0

A Rust implementation of Uniform Resources
Documentation

bcur

A Rust implementation of Uniform Resources (URs).

URs encode binary payloads as URI-friendly strings for QR codes and unreliable channels, using bytewords and fountain codes for multi-part transfer.

Status (0.1)

Transport only: bytewords + fountain + multi-part UR + DecoderLimits.
Typed dCBOR is a 0.2 feature stub; bytemoji is planned.

Features

Feature Default Description
std yes Host / std builds
dcbor no Typed dCBOR layer (stub until 0.2; implies std)
bytemoji no Bytemoji helpers (planned)

no_std + alloc: --no-default-features.

Quick start

use bcur::{Decoder, Encoder};

let data = b"Ten chars!".repeat(10);
let mut encoder = Encoder::bytes(&data, 5).unwrap();
let mut decoder = Decoder::default();
while !decoder.complete() {
    let part = encoder.next_part().unwrap();
    decoder.receive(&part).unwrap();
}
assert_eq!(decoder.message().unwrap().as_deref(), Some(data.as_slice()));

License

MIT OR Apache-2.0