mirror of https://github.com/apache/lucene.git
make toString() output slightly more logical (compressed only refers to stored fields)
git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@150574 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
01e3ab0d13
commit
251d0f5a54
|
@ -542,8 +542,13 @@ public final class Field implements Serializable {
|
|||
/** Prints a Field for human consumption. */
|
||||
public final String toString() {
|
||||
StringBuffer result = new StringBuffer();
|
||||
if (isStored)
|
||||
if (isStored) {
|
||||
result.append("stored");
|
||||
if (isCompressed)
|
||||
result.append("/compressed");
|
||||
else
|
||||
result.append("/uncompressed");
|
||||
}
|
||||
if (isIndexed) {
|
||||
if (result.length() > 0)
|
||||
result.append(",");
|
||||
|
@ -575,12 +580,6 @@ public final class Field implements Serializable {
|
|||
result.append("binary");
|
||||
}
|
||||
|
||||
if (isCompressed) {
|
||||
if (result.length() > 0)
|
||||
result.append(",");
|
||||
result.append("compressed");
|
||||
}
|
||||
|
||||
result.append('<');
|
||||
result.append(name);
|
||||
result.append(':');
|
||||
|
|
Loading…
Reference in New Issue