mirror of
https://github.com/starovoid/rxing.git
synced 2026-07-26 04:12:34 +00:00
add single pars result option
This commit is contained in:
@@ -122,6 +122,13 @@ pub fn parse_result_with_parsers(
|
|||||||
parseRXingResult(the_rxing_result)
|
parseRXingResult(the_rxing_result)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn parse_result_with_parser<F: Fn(&RXingResult) -> Option<ParsedClientResult>>(
|
||||||
|
the_rxing_result: &RXingResult,
|
||||||
|
parser: F,
|
||||||
|
) -> Option<ParsedClientResult> {
|
||||||
|
parser(the_rxing_result)
|
||||||
|
}
|
||||||
|
|
||||||
pub fn parseRXingResult(the_rxing_result: &RXingResult) -> ParsedClientResult {
|
pub fn parseRXingResult(the_rxing_result: &RXingResult) -> ParsedClientResult {
|
||||||
let PARSERS: [&ParserFunction; 20] = [
|
let PARSERS: [&ParserFunction; 20] = [
|
||||||
&BookmarkDoCoMoResultParser::parse,
|
&BookmarkDoCoMoResultParser::parse,
|
||||||
|
|||||||
Reference in New Issue
Block a user