wikimovie_preprocessing/ssquad/src/edu/cmu/ml/ssquad/store/DocumentStore.java
private Document createDocument(String content, String id, Properties otherFields, double boost) {
		Document doc = new Document();
		//System.err.println("\n"+id);

		// Stored fields aren't indexed. Indexed fields aren't stored. SMH
		doc.add(new StoredField("content", content));
        TextField contentField = new TextField("text", new StringReader(content));
        contentField.setBoost(((float) boost));
		doc.add(contentField);
		if (id != null) doc.add(new StoredField("id",id));
		if (otherFields != null) {
			for (String field : otherFields.stringPropertyNames()) {
				//System.err.println(field+"\t"+otherFields.getProperty(field));
				doc.add(new TextField(field,new StringReader(otherFields.getProperty(field))));
			}
		}
		return doc;
	}
/**
	 * Make a Document object with an un-indexed title field and an
	 * indexed content field.
	 */
Make a Document object with an un-indexed title field and an
indexed content field.
Make a Document object with an un - indexed title field and an indexed content field .
private Document createDocument(String content, String id, Properties otherFields, double boost) {
		Document doc = new Document();
		doc.add(new StoredField("content", content));
        TextField contentField = new TextField("text", new StringReader(content));
        contentField.setBoost(((float) boost));
		doc.add(contentField);
		if (id != null) doc.add(new StoredField("id",id));
		if (otherFields != null) {
			for (String field : otherFields.stringPropertyNames()) {
				doc.add(new TextField(field,new StringReader(otherFields.getProperty(field))));
			}
		}
		return doc;
	}
private Document createDocument ( String content , String id , Properties otherFields , double boost ) { Document doc = new Document ( ) ; doc . add ( new StoredField ( "content" , content ) ) ; TextField contentField = new TextField ( "text" , new StringReader ( content ) ) ; contentField . setBoost ( ( ( float ) boost ) ) ; doc . add ( contentField ) ; if ( id != null ) doc . add ( new StoredField ( "id" , id ) ) ; if ( otherFields != null ) { for ( String field : otherFields . stringPropertyNames ( ) ) { doc . add ( new TextField ( field , new StringReader ( otherFields . getProperty ( field ) ) ) ) ; } } return doc ; }
Make a Document object with an un-indexed title field and an
 indexed content field.
Make a Document object with an un - indexed title field and an indexed content field .
//System.err.println("\n"+id); // Stored fields aren't indexed. Indexed fields aren't stored. SMH //System.err.println(field+"\t"+otherFields.getProperty(field));