1Lucy::Analysis::InversiUosne(r3)Contributed Perl DocumenLtuactyi:o:nAnalysis::Inversion(3)
2
3
4
6 Lucy::Analysis::Inversion - A collection of Tokens.
7
9 my $result = Lucy::Analysis::Inversion->new;
10
11 while (my $token = $inversion->next) {
12 $result->append($token);
13 }
14
16 An Inversion is a collection of Token objects which you can add to,
17 then iterate over.
18
20 new
21 my $inversion = Lucy::Analysis::Inversion->new(
22 $seed, # optional
23 );
24
25 Create a new Inversion.
26
27 • seed - An initial Token to start things off, which may be undef.
28
30 append
31 $inversion->append($token);
32
33 Tack a token onto the end of the Inversion.
34
35 • token - A Token.
36
37 next
38 my $token = $inversion->next();
39
40 Return the next token in the Inversion until out of tokens.
41
42 reset
43 $inversion->reset();
44
45 Reset the InversionXs iterator, so that the next call to next() returns
46 the first Token in the inversion.
47
49 Lucy::Analysis::Inversion isa Clownfish::Obj.
50
51
52
53perl v5.34.0 2021-07-22 Lucy::Analysis::Inversion(3)