org.apache.lucene.search

## Class BooleanClause

- java.lang.Object
- - org.apache.lucene.search.BooleanClause

    public final class BooleanClause
    extends Object

A clause in a BooleanQuery.

### Nested Class Summary

Nested Classes
`static class` `BooleanClause.Occur` Specifies how clauses are to occur in matching documents.

### Constructor Summary

Constructors
Constructor and Description
`BooleanClause(Query query, BooleanClause.Occur occur)` Constructs a BooleanClause.

### Method Summary

All Methods Instance Methods Concrete Methods
`boolean` `equals(Object o)` Returns true if `o` is equal to this.
`BooleanClause.Occur` `getOccur()`
`Query` `getQuery()`
`int` `hashCode()` Returns a hash code value for this object.
`boolean` `isProhibited()`
`boolean` `isRequired()`
`boolean` `isScoring()`
`String` `toString()`

### Methods inherited from class java.lang.Object

`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

### Constructor Detail

#### BooleanClause

    public BooleanClause(Query query,
                         BooleanClause.Occur occur)

Constructs a BooleanClause.

### Method Detail

#### getOccur

    public BooleanClause.Occur getOccur()

#### getQuery

    public Query getQuery()

#### isProhibited

    public boolean isProhibited()

#### isRequired

    public boolean isRequired()

#### isScoring

    public boolean isScoring()

#### equals

    public boolean equals(Object o)

Returns true if `o` is equal to this.

Overrides:
  `equals` in class `Object`

#### hashCode

    public int hashCode()

Returns a hash code value for this object.

Overrides:
  `hashCode` in class `Object`

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`