protected void LoadTxtDoc(String filename) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(new FileInputStream(filename), "UTF-8"));
			StringBuffer buffer = new StringBuffer(1024);
			String line;

			while ((line = reader.readLine()) != null) {
				buffer.append(line);
			}
			reader.close();
			
			int yLabel = filename.contains("pos") ? 1:0;
			
			//Collect the number of documents in one class as its document id.
			_Doc doc = new _Doc(m_corpus.getSize(), buffer.toString(), yLabel);

			if(this.m_stnDetector!=null)
				AnalyzeDocWithStnSplit(doc);
			else
				AnalyzeDoc(doc);			
			
		} catch(IOException e){
			System.err.format("[Error]Failed to open file %s!!", filename);
			e.printStackTrace();
		}
	}