org.compass.annotations
Annotation Type SearchableDynamicMetaData


@Target(value=TYPE)
@Retention(value=RUNTIME)
public @interface SearchableDynamicMetaData

A dynamic meta data evaluation of the given expression using an expression language library.

Author:
kimchy

Required Element Summary
 String converter
          The dynamic converter lookup name.
 String expression
          The expression to be evaluated by the dynamic expression evaluation library.
 String name
          The name of the meta-data.
 
Optional Element Summary
 String analyzer
          Specifies a specialized analyzer lookup name that will be used to analyze the meta-data content.
 float boost
          The boost level for the meta-data.
 ExcludeFromAll excludeFromAll
          Specifies if this meta-data should be excluded from the generated "all" meta-data.
 String format
          The format to apply to the value.
 Index index
          Specifies whether and how a meta-data proeprty should be indexed.
 String nullValue
          A null value to use to store in the index when the property has a null value.
 OmitNorms omitNorms
           
 OmitTf omitTf
          Expert: If set, omit tf from postings of this indexed field.
 boolean override
          If there is already an existing id with the same field/property name defined, will override it.
 Reverse reverse
          Specifies whether and how the meta-data proeprty should value will be revered.
 SpellCheck spellCheck
          Should this propety be included in the spell check index.
 Store store
          Specifies whether and how a meta-data property will be stored.
 TermVector termVector
          Specifies whether and how a meta-data property should have term vectors.
 Class type
          If using a format, the type of the expression result.
 

Element Detail

name

public abstract String name
The name of the meta-data. The name will be the value the contend will be saved under, so it can later be searched using "author:london" (here the name is author).


expression

public abstract String expression
The expression to be evaluated by the dynamic expression evaluation library.


converter

public abstract String converter
The dynamic converter lookup name. Compass built in ones include: jexl, velocity.

boost

public abstract float boost
The boost level for the meta-data. Will cause hits based on this meta-data to rank higher.

Default:
1.0f

store

public abstract Store store
Specifies whether and how a meta-data property will be stored.

Default:
NA

index

public abstract Index index
Specifies whether and how a meta-data proeprty should be indexed.

Default:
NA

termVector

public abstract TermVector termVector
Specifies whether and how a meta-data property should have term vectors.

Default:
NA

omitNorms

public abstract OmitNorms omitNorms
Default:
NA

omitTf

public abstract OmitTf omitTf
Expert: If set, omit tf from postings of this indexed field.

Default:
NA

reverse

public abstract Reverse reverse
Specifies whether and how the meta-data proeprty should value will be revered.

Default:
NO

analyzer

public abstract String analyzer
Specifies a specialized analyzer lookup name that will be used to analyze the meta-data content.

Defaults to Compass default analyzer.

Default:
""

excludeFromAll

public abstract ExcludeFromAll excludeFromAll
Specifies if this meta-data should be excluded from the generated "all" meta-data.

See Also:
SearchableAllMetaData.enable()
Default:
NO

override

public abstract boolean override
If there is already an existing id with the same field/property name defined, will override it.

Default:
true

format

public abstract String format
The format to apply to the value. Only applies to format-able converters (like dates and numbers).

Default:
""

type

public abstract Class type
If using a format, the type of the expression result.

Default:
java.lang.Object.class

nullValue

public abstract String nullValue
A null value to use to store in the index when the property has a null value. Defaults to not storing null values if the globabl setting of compass.mapping.nullvalue is not set. If it set, disabling the null value can be done by setting it to CompassEnvironment.NullValue.DISABLE_NULL_VALUE_FOR_MAPPING value ($disable$).

Default:
""

spellCheck

public abstract SpellCheck spellCheck
Should this propety be included in the spell check index.

Note, most times this is not requried to be configured, since by default, the spell check index uses the "all" property.

Default:
EXCLUDE


Copyright (c) 2004-2009 The Compass Project.