Trait sophia::serializers::WriteSerializer
source · pub trait WriteSerializer<W: Write>: TripleSink<Outcome = ()> + Sized {
type Config;
fn new(write: W, config: Self::Config) -> Self;
fn write<T>(
&mut self,
source: T
) -> Result<(), WhereFrom<T::Error, Self::Error>>
where
T: TripleSource,
{ ... }
fn write_graph<G>(
&mut self,
graph: &mut G
) -> Result<(), WhereFrom<G::Error, Self::Error>>
where
G: Graph,
{ ... }
fn write_triple<T>(&mut self, t: &T) -> Result<(), Self::Error>
where
T: Triple,
{ ... }
}
Expand description
An extension of the TripleSink
trait,
dedicated to serialization to IO streams.
Required Associated Types
Required Methods
Provided Methods
sourcefn write<T>(&mut self, source: T) -> Result<(), WhereFrom<T::Error, Self::Error>>where
T: TripleSource,
fn write<T>(&mut self, source: T) -> Result<(), WhereFrom<T::Error, Self::Error>>where
T: TripleSource,
Serialize the triples from the given source.