Migrate 25 crates to monorepo.

miette
mime
mio
mls-rs-codec
mls-rs-codec-derive
mls-rs-core
mockall
named-lock
nom
no-panic
num_cpus
num-integer
num-traits
oorandom
os_str_bytes
p9
p9_wire_format_derive
parking_lot
parking_lot_core
pathdiff
pdl-runtime
pest
pest_derive
pest_generator
pest_meta

Bug: 339424309
Test: treehugger
Change-Id: If273bc7efcd82a1492aafd167ab4520235c05c8b
2 files changed
tree: 652d027ccf2b62b84f6b5416a61fb5ff04a83153
  1. benches/
  2. src/
  3. Android.bp
  4. Cargo.toml
  5. Cargo.toml.orig
  6. CONTRIBUTING.md
  7. LICENSE-APACHE
  8. LICENSE-MIT
  9. METADATA
  10. MODULE_LICENSE_APACHE2
  11. OWNERS
  12. README.md
README.md

mime

Build Status crates.io docs.rs

Support MIME (Media Types) as strong types in Rust.

Documentation

Usage

extern crate mime;

// common types are constants
let text = mime::TEXT_PLAIN;

// deconstruct Mimes to match on them
match (text.type_(), text.subtype()) {
    (mime::TEXT, mime::PLAIN) => {
        // plain text!
    },
    (mime::TEXT, _) => {
        // structured text!
    },
    _ => {
        // not text!
    }
}