Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Rust MARC XML / Breaker / Binary Toolkit
Tools for parsing and generating MARC21 binary, XML, and breaker text.
Example
use Record;
// Read a file of MARC records, modify, and print them.
for record in from_binary_file.expect
Strings & Bytes
For ease of use, the API primarily traffics in &str/String's. Byte counts are enforced where needed, but otherwise the user can generally use Rust strings without concern for bytes and UTF-8 conversions.
Requirements
- Data must be UTF-8 compatible.
- Binary leader/directory metadata must be sane/usable.
In cases where these conditions are not met, routines exit early with explanatory Err()'s.
Byte counts
MARC21 calls for indicators and subfield codes of 1 byte, tags of 3,
and a leader of 24. The constructors and setters (Subfield::new(),
Field::set_ind1(), Record::set_leader(), and the like) refuse other
values with an Err(). The parsers keep what they find, though, so a
record read from XML, binary, or breaker text may hold other values; an
empty indicator reads as blank. to_binary() returns an Err() for a
record holding a value the binary format has no room for, and breaker
text cannot represent such values faithfully either.