]>
Commit | Line | Data |
---|---|---|
74581229 EK |
1 | package no.uio.ifi.refaktor.extractors.collectors; |
2 | ||
e0fe6563 EK |
3 | import no.uio.ifi.refaktor.prefix.Prefix; |
4 | import no.uio.ifi.refaktor.prefix.PrefixSet; | |
1f62df73 | 5 | import no.uio.ifi.refaktor.utils.DocumentTextSelection; |
74581229 | 6 | |
520985c2 | 7 | public class PrefixesCollector extends AbstractPrefixCollector { |
74581229 | 8 | |
520985c2 | 9 | private final PrefixSet prefixes; |
74581229 | 10 | |
1f62df73 | 11 | public PrefixesCollector(DocumentTextSelection selection) { |
74581229 EK |
12 | super(selection); |
13 | this.prefixes = new PrefixSet(); | |
14 | } | |
15 | ||
16 | protected void registerPrefix(Prefix prefix) { | |
520985c2 | 17 | prefixes.registerAllSubPrefixesOf(prefix); |
74581229 EK |
18 | } |
19 | ||
20 | public PrefixSet getPrefixes() { | |
21 | return prefixes; | |
22 | } | |
23 | } |