Struct marc::Record
[−]
[src]
pub struct Record<'a> { // some fields omitted }
Parsed MARC Record.
It could be borrowed if it was parsed from a buffer or it could be owned if it was read from an
io::Read
implementor.
Methods
impl<'a> Record<'a>
[src]
fn parse<'x>(input: &'x [u8]) -> Result<Record<'x>>
Will try to parse record from a buffer.
Will borrow an input
for the lifetime of a produced record.
fn read<T: Read>(input: &mut T) -> Result<Option<Record<'static>>>
Will try to read a Record
from an io::Read
implementor.
Will produce owned version of Record
.
fn field<T: Into<Tag>>(&self, tag: T) -> Vec<Field>
Will return fields with tag == Tag
fn fields<'r>(&'r self) -> Fields<'r>
Will return iterator over fields of a record
fn as_ref(&self) -> &[u8]
View into a data of a record.