public SentimentWords() throws IOException {
        File posWordsFile = new File("positive-words.txt");
        BufferedReader posReader = new BufferedReader(new FileReader(
                posWordsFile));
        File negWordsFile = new File("negative-words.txt");
        BufferedReader negReader = new BufferedReader(new FileReader(
                negWordsFile));
        positiveWords = new HashSet<String>();
        negativeWords = new HashSet<String>();

        for (String posWord; (posWord = posReader.readLine()) != null;) {
            positiveWords.add(posWord.trim());
        }

        for (String negWord; (negWord = negReader.readLine()) != null;) {
            negativeWords.add(negWord.trim());
        }

        posReader.close();
        negReader.close();
    }