@@ -0,0 +1,1588 @@
+package com.github.vedenin.useful_links.classificator;%0A%0Aimport com.github.vedenin.useful_links.containers.ProjectContainer;%0Aimport com.github.vedenin.useful_links.crawlers.JavaUsefulProjects;%0Aimport com.google.common.collect.HashMultimap;%0Aimport com.google.common.collect.Multimap;%0A%0Aimport java.io.IOException;%0Aimport java.util.HashMap;%0Aimport java.util.Map;%0A%0A/**%0A * Get words from project about subjects%0A *%0A * Created by vedenin on 14.05.16.%0A */%0Apublic class WordCollector %7B%0A    public static void main(String%5B%5D args) throws IOException %7B%0A        JavaUsefulProjects crawler = new JavaUsefulProjects();%0A        WordCollector collector = new WordCollector();%0A        Map%3CString, ProjectContainer%3E projects = crawler.getProjects(%22https://github.com/Vedenin/useful-java-links/blob/master/readme.md%22);%0A        Multimap%3CString, String%3E markers = collector.getMarkers(projects);%0A%0A        projects.values().stream().forEach(System.out::println);%0A    %7D%0A%0A    public Multimap%3CString, String%3E getMarkers(Map%3CString, ProjectContainer%3E projects) %7B%0A        Multimap%3CString, String%3E result = HashMultimap.create();%0A        for(ProjectContainer project: projects.values())%7B%0A            String text = project.description;%0A            String textWithoutNonChar = text.replaceAll(%22%5B%5Ea-zA-Z0-9%5D%22,%22 %22);%0A            String%5B%5D words = textWithoutNonChar.split(%22 %22);%0A            String category = project.category;%0A            for(String word: words) %7B%0A                if(!word.isEmpty()) %7B%0A                    result.put(word, category);%0A                %7D%0A            %7D%0A%0A        %7D%0A        return result;%0A    %7D%0A%7D%0A

Add WordCollector