<commit_before>import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.net.URL;
import java.net.URLConnection;

/**
 * Created by Cheong on 2/11/2017.
 */
public class HelloWorld {

    public static void main(String[] args) {
        getUrlSource url = new getUrlSource();
    }
    private static String getUrlSource(String url) throws IOException {
        URL yahoo = new URL(url);
        URLConnection yc = yahoo.openConnection();
        BufferedReader in = new BufferedReader(new InputStreamReader(
                yc.getInputStream(), "UTF-8"));
        String inputLine;
        StringBuilder a = new StringBuilder();
        while ((inputLine = in.readLine()) != null)
            a.append(inputLine);
        in.close();

        return a.toString();
    }
}<commit_msg>네이버 뉴스 코드 받아오는 부분 구현<commit_after>import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.net.URL;
import java.net.URLConnection;

/**
 * Created by Cheong on 2/11/2017.
 */
public class HelloWorld {

    /**
     * 메인 함수
     * @param args
     */
    public static void main(String[] args) throws Exception {

        String htmlCode;

        htmlCode = getUrlSource("http://news.naver.com/");

        System.out.println(htmlCode);
    }

    /**
     * html 소스 받아오는 코드
     * http://stackoverflow.com/questions/8616781/how-to-get-a-web-pages-source-code-from-java
     * @param url 소스 받아올 웹주소
     * @return html 코드
     * @throws IOException
     */
    private static String getUrlSource(String url) throws IOException {
        URL yahoo = new URL(url);
        URLConnection yc = yahoo.openConnection();
        BufferedReader in = new BufferedReader(new InputStreamReader(
                yc.getInputStream(), "euc-kr")); // 인코딩을 euc-kr로 변경
        String inputLine;
        StringBuilder a = new StringBuilder();
        while ((inputLine = in.readLine()) != null)
            a.append(inputLine);
        in.close();

        return a.toString();
    }
}
{'fraction_non_alphanumeric': 0.11632453567937438, 'fraction_numerical': 0.010752688172043012, 'mean_word_length': 2.499145299145299, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6772441', 'n_tokens_mistral': 653, 'n_tokens_neox': 668, 'n_words': 154}