Crates.io | organisationsnummer |
lib.rs | organisationsnummer |
version | 1.0.1 |
source | src |
created_at | 2023-02-26 17:14:28.512802 |
updated_at | 2024-02-20 21:03:55.495047 |
description | Validate Swedish organization numbers |
homepage | https://organisationsnummer.dev |
repository | https://github.com/organisationsnummer/rust |
max_upload_size | |
id | 795334 |
size | 48,040 |
Validate Swedish organization numbers with Rust. Follows version 1.1 of the specification.
use organisationsnummer::Organisationsnummer;
fn main() {
match Organisationsnummer::new("202100-5489") {
Ok(org) => println!("{}: {}", org.format().long(), org.valid()),
Err(e) => panic!("Error: {}", e),
}
}
Fore more details, see examples and/or run
$ cargo run --example organisationsnummer <organisationsnummer>
MIT