- A patch to FieldInfos.java that Doug Cutting suggested at:

http://marc.theaimsgroup.com/?l=lucene-user&m=100253044509125&w=2
  This allows co-existence of indexed and non-indexed fields with the same name.
PR:
Obtained from:
Submitted by:	Guido Casper
Reviewed by:	otis


git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@149730 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Otis Gospodnetic 2002-04-30 15:08:10 +00:00
parent 6fe55d42eb
commit a90504d2b6
1 changed files with 2 additions and 4 deletions

View File

@ -105,10 +105,8 @@ final class FieldInfos {
if (fi == null)
addInternal(name, isIndexed);
else if (fi.isIndexed != isIndexed)
throw new IllegalStateException("field " + name +
(fi.isIndexed ? " must" : " cannot") +
" be an indexed field.");
}
fi.isIndexed = true;
}
private final void addInternal(String name, boolean isIndexed) {
FieldInfo fi = new FieldInfo(name, isIndexed, byNumber.size());