Overview | Package | Class | Use | Tree | Deprecated | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.lucene.util
Class InfoStream

    java.lang.Object
      org.apache.lucene.util.InfoStream

All Implemented Interfaces:
  Closeable, Cloneable

Direct Known Subclasses:
  PrintStreamInfoStream

    public abstract class InfoStream

extends Object
implements Closeable, Cloneable

Debugging API for Lucene classes such as `IndexWriter` and `SegmentInfos`.

NOTE: Enabling infostreams may cause performance degradation in some components.

NOTE: This API is for internal purposes only and might change in incompatible ways in the next release.

Field Summary
`static InfoStream` | `NO_OUTPUT` Instance of InfoStream that does no logging at all.

Constructor Summary
`InfoStream()`

Method Summary
`InfoStream` | `clone()`
`static InfoStream` | `getDefault()` The default `InfoStream` used by a newly instantiated classes.
`abstract boolean` | `isEnabled(String component)` returns true if messages are enabled and should be posted to `message(java.lang.String, java.lang.String)`.
`abstract void` | `message(String component, String message)` prints a message
`static void` | `setDefault(InfoStream infoStream)` Sets the default `InfoStream` used by a newly instantiated classes.

Methods inherited from class java.lang.Object
`equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface java.io.Closeable
`close`

Field Detail

### NO_OUTPUT

    public static final InfoStream NO_OUTPUT

  Instance of InfoStream that does no logging at all.

Constructor Detail

### InfoStream

    public InfoStream()

Method Detail

### message

    public abstract void message(String component,
                                 String message)

  prints a message

### isEnabled

    public abstract boolean isEnabled(String component)

  returns true if messages are enabled and should be posted to `message(java.lang.String, java.lang.String)`.

### getDefault

    public static InfoStream getDefault()

  The default `InfoStream` used by a newly instantiated classes.

  See Also:
    `setDefault(org.apache.lucene.util.InfoStream)`

### setDefault

    public static void setDefault(InfoStream infoStream)

  Sets the default `InfoStream` used by a newly instantiated classes. It cannot be `null`, to disable logging use `NO_OUTPUT`.

  See Also:
    `getDefault()`

### clone

    public InfoStream clone()

  Overrides:
    `clone` in class `Object`

Overview | Package | Class | Use | Tree | Deprecated | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000-2013 Apache Software Foundation. All Rights Reserved.