{"id":22297457,"url":"https://github.com/rustonaut/mail-chars","last_synced_at":"2025-03-25T22:43:46.005Z","repository":{"id":57636078,"uuid":"111104908","full_name":"rustonaut/mail-chars","owner":"rustonaut","description":"provids lookup table based char classification for mail related grammars","archived":false,"fork":false,"pushed_at":"2019-10-11T14:44:46.000Z","size":20,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-03-06T00:08:57.527Z","etag":null,"topics":["mail","mime","rfc2045","rfc5322","rfc6838","rust"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rustonaut.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-11-17T13:12:02.000Z","updated_at":"2022-06-05T19:58:15.000Z","dependencies_parsed_at":"2022-09-26T20:21:38.999Z","dependency_job_id":null,"html_url":"https://github.com/rustonaut/mail-chars","commit_stats":null,"previous_names":["dac-gmbh/mail-chars"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rustonaut%2Fmail-chars","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rustonaut%2Fmail-chars/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rustonaut%2Fmail-chars/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rustonaut%2Fmail-chars/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rustonaut","download_url":"https://codeload.github.com/rustonaut/mail-chars/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245556960,"owners_count":20634889,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["mail","mime","rfc2045","rfc5322","rfc6838","rust"],"created_at":"2024-12-03T17:49:51.480Z","updated_at":"2025-03-25T22:43:45.981Z","avatar_url":"https://github.com/rustonaut.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"mail-chars [![Crates.io](https://img.shields.io/crates/v/mail-chars.svg)](https://crates.io/crates/mail-chars) [![mail-chars](https://docs.rs/mail-chars/badge.svg)](https://docs.rs/mail-chars) [![License](https://img.shields.io/badge/License-MIT%2FApache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0) [![Build Status](https://travis-ci.org/1aim/mail-chars.svg?branch=master)](https://travis-ci.org/1aim/mail-chars)\n==========\nProvides lookup table based char classification for mail related grammar\nparts/charset, i.e. if a given char is valid in atext, ctext, dtext, token etc.\n\nNote that this just covers grammar parts defining sets of chars (like atext,\nctext, ...) but not contextual parts like e.g. quoted-pairs. \n\n```rust\nextern crate mail_chars;\nuse mail_chars::{Charset, rfc5322, rfc2045, CharMatchExt};\n\nfn main() {\n    assert!(Charset::AText.contains('d'));\n    assert!('d'.is(Charset::AText));\n    assert!('d'.is(rfc5322::AText));\n    \n    // `rfc*::*` are just re-exports grouped by RFC.\n    assert_eq!(Charset::Token, rfc2045::Token);\n    \n    // If we want to test for more than on char set we can use lookup.\n    let res = Charset::lookup('.');\n\n    // This has the benefit that there is an `is_ascii` method.\n    assert!(res.is_ascii());\n    assert!(res.is(rfc2045::Token));\n    assert!(res.is(rfc5322::CTextWs));\n    assert!(!res.is(rfc5322::AText));\n}\n```\n\n\nLicense\n=======\nLicensed under either of\n\n * Apache License, Version 2.0, ([LICENSE-APACHE](LICENSE-APACHE) or http://www.apache.org/licenses/LICENSE-2.0)\n * MIT license ([LICENSE-MIT](LICENSE-MIT) or http://opensource.org/licenses/MIT)\n\nat your option.\n\nContribution\n------------\nUnless you explicitly state otherwise, any contribution intentionally submitted\nfor inclusion in the work by you, as defined in the Apache-2.0 license, shall\nbe dual licensed as above, without any additional terms or conditions.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frustonaut%2Fmail-chars","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frustonaut%2Fmail-chars","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frustonaut%2Fmail-chars/lists"}