There is a constructor of lucene Field:
Field(String name, String value, Store store, Index index)
For example I can create a new field by:
As mentioned in Lucene FAQ:
What is the different between Stored, Tokenized, Indexed, and Vector?
- Stored = as-is value stored in the Lucene index
- Tokenized = field is analyzed using the specified Analyzer - the tokens emitted are indexed
- Indexed = the text (either as-is with keyword fields, or the tokens from tokenized fields) is made searchable (aka inverted)
- Vectored = term frequency per document is stored in the index in an easily retrievable fashion.
You can just index field content without store it, the field is also searchable, just can't highlight the result, because highlight requires original message content, which should Store.