pub struct Parser { /* private fields */ }
Expand description
An asynchronous Parser
to process addresses.
§Example
use japanese_address_parser::parser::Parser;
async fn example() {
let parser : Parser = Default::default();
let result = parser.parse("東京都新宿区西新宿2-8-1").await;
println!("{:?}", result);
}
Implementations§
Source§impl Parser
impl Parser
Sourcepub async fn parse(&self, address: &str) -> ParseResult
pub async fn parse(&self, address: &str) -> ParseResult
Parses the given address
asynchronously.
Sourcepub fn parse_blocking(&self, address: &str) -> ParseResult
pub fn parse_blocking(&self, address: &str) -> ParseResult
Parses the given address
synchronously.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Parser
impl RefUnwindSafe for Parser
impl Send for Parser
impl Sync for Parser
impl Unpin for Parser
impl UnwindSafe for Parser
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