[−][src]Function ed_join::verification::verify
pub fn verify(
x: Vec<PosQGram>,
line_id: usize,
line_content: &str,
y: &mut PosQGramArray,
candidate_id: usize,
candidate_content: &str,
inverted: &InvertedIndex,
q: usize,
tau: usize
) -> Option<(usize, Vec<(usize, usize)>)>
Given a string and a set of possible candidates for matching, verify whether each of the candidate is valid by various filters, and eventually output all matched candidates and corresponding edit distance.
Parameters
x
andy
: Theinner
of a PosQGramArray, based on a line ofdoc_x
ordoc_y
, respectivelyline_id
andcandidate_id
: Line number ofx
andy
, respectivelyline_content
andcandidate_content
: String representation ofx
andy
, respectivelyinverted
: The inverted index.q
: A positive integer as the tuning parameter for length of q-grams.tau
: A positive integer as the tuning parameter for threshold for matching.
Return
Verified matched paris from the candidates set.