Skip to content

Instantly share code, notes, and snippets.

@need4spd
Created November 27, 2012 06:57
Show Gist options
  • Save need4spd/4152822 to your computer and use it in GitHub Desktop.
Save need4spd/4152822 to your computer and use it in GitHub Desktop.
Create Field instance in Lucene 4.0
FieldType fieldType = new FieldType();
fieldType.setIndexed(true);
fieldType.setStored(true);
fieldType.setTokenized(true);
fieldType.setIndexOptions(IndexOptions.DOCS_ONLY);
Field field = new Field("ids", ids[i], fieldType); //int type
IntField intField = new IntField("price", prices[i], fieldType);
@need4spd
Copy link
Author

루씬 4.0에서 필드 instance생성

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment