Specifies a searchable component on property or field of the
Searchable class.
A searchable component is a class field/property that reference another class, which
content need to be embedded into the content of its
Searchable class. It will
results in searches performed on the component class to return the component field/property
searchable class.
The referenced class must have searchable definitions, defined either using annotations
or other means (like xml).
Compass will try to automatically identify the searchable class mapping definitions that
map to the component class. If the mappings can not be automatically identified, the
SearchableComponent.refAlias() should be used to reference the alias that has the searchable class
mapping definition.
The searchable component can annotate a
java.util.Collection type field/property,
supporting either
java.util.List or
java.util.Set . The searchable component
will try and automatically identify the element type using generics, but if the collection
is not defined with generics,
SearchableComponent.refAlias() should be used to reference the component
searchable class mapping definitions.
The searchable component can annotate an array as well, with the array element type used for
referenced searchable class mapping definitions.
author: kimchy See Also: Searchable See Also: SearchableReference |