Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| ModeShape Distribution 3.0.0.Alpha5
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.modeshape.jcr.query
Class IndexRules.Builder

    java.lang.Object
      org.modeshape.jcr.query.IndexRules.Builder

Enclosing class:
  IndexRules

    @NotThreadSafe
    public static class IndexRules.Builder

extends Object

A builder of immutable `IndexRules` objects.

Method Summary
`IndexRules.Builder` | `binaryField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, boolean fullTextSearchable)` Define a binary-based field in the indexes.
`IndexRules.Builder` | `booleanField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index)` Define a boolean-based field in the indexes.
`IndexRules` | `build()` Build the indexing rules.
`IndexRules.Builder` | `dateField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index)` Define a date-based field in the indexes.
`IndexRules.Builder` | `dateField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, Long minValue)` Define a date-based field in the indexes.
`IndexRules.Builder` | `dateField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, Long minValue, Long maxValue)` Define a date-based field in the indexes.
`IndexRules.Builder` | `decimalField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, BigDecimal minValue, BigDecimal maxValue)` Define a decimal-based field in the indexes.
`IndexRules.Builder` | `defaultTo(org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, boolean canBeReference, boolean fullTextSearchable)` Define a string-based field as the default.
`IndexRules.Builder` | `doubleField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index)` Define a double-based field in the indexes.
`IndexRules.Builder` | `doubleField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, Double minValue)` Define a double-based field in the indexes.
`IndexRules.Builder` | `doubleField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, Double minValue, Double maxValue)` Define a double-based field in the indexes.
`IndexRules.Builder` | `floatField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index)` Define a float-based field in the indexes.
`IndexRules.Builder` | `floatField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, Float minValue)` Define a float-based field in the indexes.
`IndexRules.Builder` | `floatField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, Float minValue, Float maxValue)` Define a float-based field in the indexes.
`IndexRules.Builder` | `integerField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index)` Define a integer-based field in the indexes.
`IndexRules.Builder` | `integerField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, Integer minValue)` Define a integer-based field in the indexes.
`IndexRules.Builder` | `integerField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, Integer minValue, Integer maxValue)` Define a integer-based field in the indexes.
`IndexRules.Builder` | `longField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index)` Define a long-based field in the indexes.
`IndexRules.Builder` | `longField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, Long minValue)` Define a long-based field in the indexes.
`IndexRules.Builder` | `longField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, Long minValue, Long maxValue)` Define a long-based field in the indexes.
`protected
`<T> IndexRules.Builder`
` | `numericField(Name name, IndexRules.FieldType type, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, T minValue, T maxValue)`
`IndexRules.Builder` | `pathField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index)` Define a path-based field in the indexes.
`IndexRules.Builder` | `referenceField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index)` Define a reference-based field in the indexes.
`IndexRules.Builder` | `skip(Name... namesToIndex)` Mark the properties with the supplied names to be skipped from indexing.
`IndexRules.Builder` | `stringField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, boolean canBeReference, boolean fullTextSearchable)` Define a string-based field in the indexes.
`IndexRules.Builder` | `weakReferenceField(Name name, org.apache.lucene.document.Field.Store store, org.apache.lucene.document.Field.Index index, boolean fullTextSearchable)` Define a weak-reference-based field in the indexes.

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

Method Detail

### skip

    public IndexRules.Builder skip(Name... namesToIndex)

  Mark the properties with the supplied names to be skipped from indexing.

  Parameters:
    `namesToIndex` - the names of the properties that are to be skipped
  Returns:
    this builder for convenience and method chaining; never null

### defaultTo

    public IndexRules.Builder defaultTo(org.apache.lucene.document.Field.Store store,
                                        org.apache.lucene.document.Field.Index index,
                                        boolean canBeReference,
                                        boolean fullTextSearchable)

  Define a string-based field as the default.

  Parameters:
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `canBeReference` - true if this field can contain references; or false if it cannot
    `fullTextSearchable` - true if this field is full-text searchable, or false otherwise
  Returns:
    this builder for convenience and method chaining; never null

### stringField

    public IndexRules.Builder stringField(Name name,
                                          org.apache.lucene.document.Field.Store store,
                                          org.apache.lucene.document.Field.Index index,
                                          boolean canBeReference,
                                          boolean fullTextSearchable)

  Define a string-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `canBeReference` - true if this field can contain references; or false if it cannot
    `fullTextSearchable` - true if this field is full-text searchable, or false otherwise
  Returns:
    this builder for convenience and method chaining; never null

### binaryField

    public IndexRules.Builder binaryField(Name name,
                                          org.apache.lucene.document.Field.Store store,
                                          org.apache.lucene.document.Field.Index index,
                                          boolean fullTextSearchable)

  Define a binary-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `fullTextSearchable` - true if this field is full-text searchable, or false otherwise
  Returns:
    this builder for convenience and method chaining; never null

### pathField

    public IndexRules.Builder pathField(Name name,
                                        org.apache.lucene.document.Field.Store store,
                                        org.apache.lucene.document.Field.Index index)

  Define a path-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
  Returns:
    this builder for convenience and method chaining; never null

### referenceField

    public IndexRules.Builder referenceField(Name name,
                                             org.apache.lucene.document.Field.Store store,
                                             org.apache.lucene.document.Field.Index index)

  Define a reference-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
  Returns:
    this builder for convenience and method chaining; never null

### weakReferenceField

    public IndexRules.Builder weakReferenceField(Name name,
                                                 org.apache.lucene.document.Field.Store store,
                                                 org.apache.lucene.document.Field.Index index,
                                                 boolean fullTextSearchable)

  Define a weak-reference-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `fullTextSearchable` - true if this field is full-text searchable, or false otherwise
  Returns:
    this builder for convenience and method chaining; never null

### numericField

    protected <T> IndexRules.Builder numericField(Name name,
                                                  IndexRules.FieldType type,
                                                  org.apache.lucene.document.Field.Store store,
                                                  org.apache.lucene.document.Field.Index index,
                                                  T minValue,
                                                  T maxValue)

### booleanField

    public IndexRules.Builder booleanField(Name name,
                                           org.apache.lucene.document.Field.Store store,
                                           org.apache.lucene.document.Field.Index index)

  Define a boolean-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
  Returns:
    this builder for convenience and method chaining; never null

### integerField

    public IndexRules.Builder integerField(Name name,
                                           org.apache.lucene.document.Field.Store store,
                                           org.apache.lucene.document.Field.Index index,
                                           Integer minValue,
                                           Integer maxValue)

  Define a integer-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `minValue` - the minimum value for this field, or null if there is no minimum value
    `maxValue` - the maximum value for this field, or null if there is no maximum value
  Returns:
    this builder for convenience and method chaining; never null

### longField

    public IndexRules.Builder longField(Name name,
                                        org.apache.lucene.document.Field.Store store,
                                        org.apache.lucene.document.Field.Index index,
                                        Long minValue,
                                        Long maxValue)

  Define a long-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `minValue` - the minimum value for this field, or null if there is no minimum value
    `maxValue` - the maximum value for this field, or null if there is no maximum value
  Returns:
    this builder for convenience and method chaining; never null

### decimalField

    public IndexRules.Builder decimalField(Name name,
                                           org.apache.lucene.document.Field.Store store,
                                           org.apache.lucene.document.Field.Index index,
                                           BigDecimal minValue,
                                           BigDecimal maxValue)

  Define a decimal-based field in the indexes. This method will overwrite any existing definition in this builder.

  Decimal fields can contain an exceedingly large range of values, and because Lucene is not capable of performing range queries using BigDecimal values, decimal fields are stored as lexicographically-sortable strings.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `minValue` - the minimum value for this field, or null if there is no minimum value
    `maxValue` - the maximum value for this field, or null if there is no maximum value
  Returns:
    this builder for convenience and method chaining; never null

### dateField

    public IndexRules.Builder dateField(Name name,
                                        org.apache.lucene.document.Field.Store store,
                                        org.apache.lucene.document.Field.Index index,
                                        Long minValue,
                                        Long maxValue)

  Define a date-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `minValue` - the minimum value for this field, or null if there is no minimum value
    `maxValue` - the maximum value for this field, or null if there is no maximum value
  Returns:
    this builder for convenience and method chaining; never null

### floatField

    public IndexRules.Builder floatField(Name name,
                                         org.apache.lucene.document.Field.Store store,
                                         org.apache.lucene.document.Field.Index index,
                                         Float minValue,
                                         Float maxValue)

  Define a float-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `minValue` - the minimum value for this field, or null if there is no minimum value
    `maxValue` - the maximum value for this field, or null if there is no maximum value
  Returns:
    this builder for convenience and method chaining; never null

### doubleField

    public IndexRules.Builder doubleField(Name name,
                                          org.apache.lucene.document.Field.Store store,
                                          org.apache.lucene.document.Field.Index index,
                                          Double minValue,
                                          Double maxValue)

  Define a double-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `minValue` - the minimum value for this field, or null if there is no minimum value
    `maxValue` - the maximum value for this field, or null if there is no maximum value
  Returns:
    this builder for convenience and method chaining; never null

### integerField

    public IndexRules.Builder integerField(Name name,
                                           org.apache.lucene.document.Field.Store store,
                                           org.apache.lucene.document.Field.Index index,
                                           Integer minValue)

  Define a integer-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `minValue` - the minimum value for this field, or null if there is no minimum value
  Returns:
    this builder for convenience and method chaining; never null

### longField

    public IndexRules.Builder longField(Name name,
                                        org.apache.lucene.document.Field.Store store,
                                        org.apache.lucene.document.Field.Index index,
                                        Long minValue)

  Define a long-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `minValue` - the minimum value for this field, or null if there is no minimum value
  Returns:
    this builder for convenience and method chaining; never null

### dateField

    public IndexRules.Builder dateField(Name name,
                                        org.apache.lucene.document.Field.Store store,
                                        org.apache.lucene.document.Field.Index index,
                                        Long minValue)

  Define a date-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `minValue` - the minimum value for this field, or null if there is no minimum value
  Returns:
    this builder for convenience and method chaining; never null

### floatField

    public IndexRules.Builder floatField(Name name,
                                         org.apache.lucene.document.Field.Store store,
                                         org.apache.lucene.document.Field.Index index,
                                         Float minValue)

  Define a float-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `minValue` - the minimum value for this field, or null if there is no minimum value
  Returns:
    this builder for convenience and method chaining; never null

### doubleField

    public IndexRules.Builder doubleField(Name name,
                                          org.apache.lucene.document.Field.Store store,
                                          org.apache.lucene.document.Field.Index index,
                                          Double minValue)

  Define a double-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
    `minValue` - the minimum value for this field, or null if there is no minimum value
  Returns:
    this builder for convenience and method chaining; never null

### integerField

    public IndexRules.Builder integerField(Name name,
                                           org.apache.lucene.document.Field.Store store,
                                           org.apache.lucene.document.Field.Index index)

  Define a integer-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
  Returns:
    this builder for convenience and method chaining; never null

### longField

    public IndexRules.Builder longField(Name name,
                                        org.apache.lucene.document.Field.Store store,
                                        org.apache.lucene.document.Field.Index index)

  Define a long-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
  Returns:
    this builder for convenience and method chaining; never null

### dateField

    public IndexRules.Builder dateField(Name name,
                                        org.apache.lucene.document.Field.Store store,
                                        org.apache.lucene.document.Field.Index index)

  Define a date-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
  Returns:
    this builder for convenience and method chaining; never null

### floatField

    public IndexRules.Builder floatField(Name name,
                                         org.apache.lucene.document.Field.Store store,
                                         org.apache.lucene.document.Field.Index index)

  Define a float-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
  Returns:
    this builder for convenience and method chaining; never null

### doubleField

    public IndexRules.Builder doubleField(Name name,
                                          org.apache.lucene.document.Field.Store store,
                                          org.apache.lucene.document.Field.Index index)

  Define a double-based field in the indexes. This method will overwrite any existing definition in this builder.

  Parameters:
    `name` - the name of the field
    `store` - the storage setting, or null if the field should be `stored`
    `index` - the index setting, or null if the field should be indexed but `not analyzed`
  Returns:
    this builder for convenience and method chaining; never null

### build

    public IndexRules build()

  Build the indexing rules.

  Returns:
    the immutable indexing rules.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| ModeShape Distribution 3.0.0.Alpha5
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2008-2012 JBoss, a division of Red Hat. All Rights Reserved.