code: @Override
    public synchronized void init(PlayerConfig config) {
      super.init(config);
      String dictFileName = config.get(DICTIONARY_FILE_NAME_KEY);
      if (dictFileName == null || "".equals(dictFileName.trim())) {
        throw new IllegalArgumentException(this.getClass().getName() + " expects configuration property "
            + DICTIONARY_FILE_NAME_KEY);
      }
      File f = new File(dictFileName);
      if (!f.exists() || f.isDirectory()) {
        throw new IllegalArgumentException("Property " + DICTIONARY_FILE_NAME_KEY
            + " should designate existing dictionary file!");
      }
      BufferedReader bufferedReader = null;
      try {
        bufferedReader = new BufferedReader(new FileReader(f));
        while (true) {
          String phrase = bufferedReader.readLine();
          if (phrase != null) {
            DICTIONARY.add(phrase.trim());
          } else {
            break;
          }
        }
      } catch (IOException ioe) {
        throw new IllegalArgumentException("File " + f.getName() + " under key " + DICTIONARY_FILE_NAME_KEY
            + " not readable!");
      } finally {
        try {
          if (bufferedReader != null)
          bufferedReader.close();
        } catch (IOException ioe) {
          throw new RuntimeException(ioe);
        }
      }
    }
docs: (non-Javadoc)
  
  @see com.sematext.ag.source.FiniteEventSource#init(com.sematext.ag.PlayerConfig)