pub struct Row<T> {
pub key: String,
pub record: T,
}
Expand description
Struct representing a row of the OpenLibrary dump file.
The row extracts the key and record, deserializing the record from JSON to the appropriate type.
Fields§
§key: String
§record: T
Trait Implementations§
Source§impl<T: DeserializeOwned> FromStr for Row<T>
impl<T: DeserializeOwned> FromStr for Row<T>
Source§impl ObjectWriter<Row<OLAuthorSource>> for AuthorProcessor
impl ObjectWriter<Row<OLAuthorSource>> for AuthorProcessor
Source§fn write_object(&mut self, row: Row<OLAuthorSource>) -> Result<()>
fn write_object(&mut self, row: Row<OLAuthorSource>) -> Result<()>
Write one object.
Source§fn write_all_objects<I>(&mut self, objects: I) -> Result<usize>where
I: Iterator<Item = T>,
fn write_all_objects<I>(&mut self, objects: I) -> Result<usize>where
I: Iterator<Item = T>,
Write an iterator full of objects.
Source§impl ObjectWriter<Row<OLEditionRecord>> for EditionProcessor
impl ObjectWriter<Row<OLEditionRecord>> for EditionProcessor
Source§fn write_object(&mut self, row: Row<OLEditionRecord>) -> Result<()>
fn write_object(&mut self, row: Row<OLEditionRecord>) -> Result<()>
Write one object.
Source§fn write_all_objects<I>(&mut self, objects: I) -> Result<usize>where
I: Iterator<Item = T>,
fn write_all_objects<I>(&mut self, objects: I) -> Result<usize>where
I: Iterator<Item = T>,
Write an iterator full of objects.
Source§impl ObjectWriter<Row<OLWorkRecord>> for WorkProcessor
impl ObjectWriter<Row<OLWorkRecord>> for WorkProcessor
Source§fn write_object(&mut self, row: Row<OLWorkRecord>) -> Result<()>
fn write_object(&mut self, row: Row<OLWorkRecord>) -> Result<()>
Write one object.
Source§fn write_all_objects<I>(&mut self, objects: I) -> Result<usize>where
I: Iterator<Item = T>,
fn write_all_objects<I>(&mut self, objects: I) -> Result<usize>where
I: Iterator<Item = T>,
Write an iterator full of objects.
Auto Trait Implementations§
impl<T> Freeze for Row<T>where
T: Freeze,
impl<T> RefUnwindSafe for Row<T>where
T: RefUnwindSafe,
impl<T> Send for Row<T>where
T: Send,
impl<T> Sync for Row<T>where
T: Sync,
impl<T> Unpin for Row<T>where
T: Unpin,
impl<T> UnwindSafe for Row<T>where
T: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more