org.hibernate.search.backend.spi

## Class SingularTermDeletionQuery

- java.lang.Object
- - org.hibernate.search.backend.spi.SingularTermDeletionQuery

- All Implemented Interfaces:
    DeletionQuery

      public final class SingularTermDeletionQuery
      extends Object
      implements DeletionQuery

  DeleteByQuery equivalent to `TermQuery`
  Author:
    Martin Braun, Guillaume Smet
  Experimental

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `SingularTermDeletionQuery.Type`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static int` | `QUERY_KEY`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `SingularTermDeletionQuery(String fieldName, double value)`
    `SingularTermDeletionQuery(String fieldName, float value)`
    `SingularTermDeletionQuery(String fieldName, int value)`
    `SingularTermDeletionQuery(String fieldName, long value)`
    `SingularTermDeletionQuery(String fieldName, Object value, SingularTermDeletionQuery.Type type)`
    `SingularTermDeletionQuery(String fieldName, String value)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `equals(Object obj)`
    `static SingularTermDeletionQuery` | `fromString(String[] string)`
    `String` | `getFieldName()`
    `int` | `getQueryKey()` used to identify the type of query faster (no need for instanceof checks)
    `SingularTermDeletionQuery.Type` | `getType()`
    `Object` | `getValue()`
    `int` | `hashCode()`
    `String[]` | `serialize()` We are serializing to a String array here instead of a byte array since we don't want implementors to use the standard Java Serialization API by mistake
    `Query` | `toLuceneQuery(DocumentBuilderIndexedEntity documentBuilder)` converts this DeletionQuery to a Lucene Query
    `String` | `toString()`

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

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

- - ### Field Detail

    - #### QUERY_KEY

          public static final int QUERY_KEY

      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### SingularTermDeletionQuery

          public SingularTermDeletionQuery(String fieldName,
                                           String value)

    - #### SingularTermDeletionQuery

          public SingularTermDeletionQuery(String fieldName,
                                           int value)

    - #### SingularTermDeletionQuery

          public SingularTermDeletionQuery(String fieldName,
                                           long value)

    - #### SingularTermDeletionQuery

          public SingularTermDeletionQuery(String fieldName,
                                           float value)

    - #### SingularTermDeletionQuery

          public SingularTermDeletionQuery(String fieldName,
                                           double value)

    - #### SingularTermDeletionQuery

          public SingularTermDeletionQuery(String fieldName,
                                           Object value,
                                           SingularTermDeletionQuery.Type type)

  - ### Method Detail

    - #### getFieldName

          public String getFieldName()

    - #### getValue

          public Object getValue()

    - #### getType

          public SingularTermDeletionQuery.Type getType()

    - #### getQueryKey

          public int getQueryKey()

      Description copied from interface: `DeletionQuery`
      used to identify the type of query faster (no need for instanceof checks)
      Specified by:
        `getQueryKey` in interface `DeletionQuery`
      Returns:
        the unique query key

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

    - #### toLuceneQuery

          public Query toLuceneQuery(DocumentBuilderIndexedEntity documentBuilder)

      Description copied from interface: `DeletionQuery`
      converts this DeletionQuery to a Lucene Query
      Specified by:
        `toLuceneQuery` in interface `DeletionQuery`
      Parameters:
        `documentBuilder` - the document builder of this entity
      Returns:
        the deletion query as Lucene `Query`

    - #### serialize

          public String[] serialize()

      Description copied from interface: `DeletionQuery`
      We are serializing to a String array here instead of a byte array since we don't want implementors to use the standard Java Serialization API by mistake
      Specified by:
        `serialize` in interface `DeletionQuery`
      Returns:
        a String[] representation of this DeletionQuery

    - #### fromString

          public static SingularTermDeletionQuery fromString(String[] string)

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Object`

    - #### equals

          public boolean equals(Object obj)

      Overrides:
        `equals` in class `Object`

Copyright © 2006-2017 Red Hat, Inc. All Rights Reserved