Package org.arabidopsis.ahocorasick

Examples of org.arabidopsis.ahocorasick.SearchResult


        String text = IOUtils.toString(in, "UTF-8"); // TODO convert AhoCorasick to use InputStream
        Iterator<SearchResult<Match>> searchResults = tree.search(text.toCharArray());
        Vertex sourceVertex = (Vertex) data.getElement();
        List<Vertex> termMentions = new ArrayList<Vertex>();
        while (searchResults.hasNext()) {
            SearchResult searchResult = searchResults.next();
            VisibilityJson visibilityJson = data.getVisibilitySourceJson();
            List<Vertex> newTermMentions = outputResultToTermMention(sourceVertex, searchResult, data.getProperty().getKey(), visibilityJson, data.getVisibility());
            termMentions.addAll(newTermMentions);
            getGraph().flush();
        }
View Full Code Here

TOP

Related Classes of org.arabidopsis.ahocorasick.SearchResult

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.