pub struct XMLWriter<W: Write> { /* private fields */ }
Expand description
Write as OSM XML file format
Trait Implementations§
Source§impl<W: Write> OSMWriter<W> for XMLWriter<W>
impl<W: Write> OSMWriter<W> for XMLWriter<W>
fn set_header( &mut self, (key, value): (&str, &str), ) -> Result<(), OSMWriteError>
Source§fn is_open(&self) -> bool
fn is_open(&self) -> bool
Return true iff this writer is not closed.
If open you should be able to continue to write objects to it. If closed you cannot write
any more OSM objects to it.
Source§fn close(&mut self) -> Result<(), OSMWriteError>
fn close(&mut self) -> Result<(), OSMWriteError>
Close this writer, cannot write any more objects.
Some fileformats have certain ‘end of file’ things. After you write those, you cannot write
any more OSM objects. e.g. an XML file format will require that you close your root XML
tag.
After calling this method, you cannot add any more OSM objects to this writer, and
is_open
will return false
.Source§fn write_obj(&mut self, obj: &impl OSMObj) -> Result<(), OSMWriteError>
fn write_obj(&mut self, obj: &impl OSMObj) -> Result<(), OSMWriteError>
Write an OSM object to this.
Source§fn into_inner(self) -> W
fn into_inner(self) -> W
Convert back to the underlying writer object
Auto Trait Implementations§
impl<W> Freeze for XMLWriter<W>where
W: Freeze,
impl<W> RefUnwindSafe for XMLWriter<W>where
W: RefUnwindSafe,
impl<W> Send for XMLWriter<W>where
W: Send,
impl<W> Sync for XMLWriter<W>where
W: Sync,
impl<W> Unpin for XMLWriter<W>where
W: Unpin,
impl<W> UnwindSafe for XMLWriter<W>where
W: 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