pub struct InputStream<'input> { /* private fields */ }Expand description
Default rust target input stream.
Since Rust uses UTF-8 format which does not support indexing by char,
InputStream<&str> has slightly different index behavior in compare to java runtime when there are
non-ASCII unicode characters.
If you need it to generate exactly the same indexes as Java runtime, you have to use CodePoint8/16/32BitCharStream,
which does not use rusts native str type, so it would do additional conversions and allocations along the way.
Implementations§
Trait Implementations§
Source§impl<'input> CharStream<'input> for InputStream<'input>
impl<'input> CharStream<'input> for InputStream<'input>
Source§impl<'input> Debug for InputStream<'input>
impl<'input> Debug for InputStream<'input>
Source§impl IntStream for InputStream<'_>
impl IntStream for InputStream<'_>
Source§fn consume(&mut self)
fn consume(&mut self)
Consumes the current symbol in the stream.
Advances this stream to the next element. Read more
Source§fn mark(&mut self) -> isize
fn mark(&mut self) -> isize
After this call subsequent calls to seek must succeed if seek index is greater than mark index Read more
Source§fn seek(&mut self, index: isize)
fn seek(&mut self, index: isize)
Put stream back in state it was when it was in
index position Read moreSource§fn get_source_name(&self) -> String
fn get_source_name(&self) -> String
Returns name of the source this stream operates over if any
Auto Trait Implementations§
impl<'input> Freeze for InputStream<'input>
impl<'input> RefUnwindSafe for InputStream<'input>
impl<'input> Send for InputStream<'input>
impl<'input> Sync for InputStream<'input>
impl<'input> Unpin for InputStream<'input>
impl<'input> UnwindSafe for InputStream<'input>
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