Class SearchContentField
- java.lang.Object
-
- lumis.search.SearchContentField
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Cloneable
- Direct Known Subclasses:
ServiceIdSearchContentField
@Deprecated @StableMinor(version="17.0", sinceVersion="4.0") public class SearchContentField extends java.lang.Object implements java.lang.Cloneable, java.io.Serializable
Deprecated.Since 8.1.0, lumis.search was replaced by lumis.portal.bigdata.Field of aSearchContent
object. It represents a piece of the information to be indexed that has name, value and the following indexing properties:- indexed:
true
means that the field is searchable and must be used to match its ownerSearchContent
when a search query runs. - stored:
true
means that the field must be stored in some way that allow it to be retrieved when a search query matches the ownerSearchContent
. - tokenized:
true
means that the field can be optimized and changed before it is indexed. Usually a indexing tokenization consists in cleaning whitespaces, removing stop words, normalizing character casing among other optimization operations.
There are the following predefined fields, that are characterized by their names and have predefined special meaning to the search context:
Field Description Field name Identifier Identifier of the content being indexed. It can be used later to retrieve the content from search index. This field is indexed, stored and not tokenized. FIELDNAME_ID
Title Title of the content being indexed. Usually is used as the name of the hyperlink in a search results interface. This field is stored, not indexed and not tokenized. FIELDNAME_TITLE
Subtitle Subtitle of the content being indexed. Usually is presented close to the hyperlink in a search results interface, to present additional information of the content. This field is stored, not indexed and not tokenized. FIELDNAME_SUBTITLE
URL URL of the content being indexed. Usually is used as the URL of the hyperlink in a search results interface, consisting in an URL that allows the navigation to the content details. This field is stored, not indexed and not tokenized. FIELDNAME_URL
Text The textual searchable content. This is the only field used by search engines to search for contents based on provided search criteria. This field is indexed, tokenized and not stored. FIELDNAME_TEXT
All information provided in fields is stored by the search engine and retrieved in search results in
SearchHit
objects.Any field that does not match any of the above predefined field is considered a custom field and will have implementation-specific meaning and behavior.
- Since:
- 4.0.4
- Version:
- $Revision$ $Date$
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
FIELDNAME_ID
Deprecated.Name used by identifier fields.static java.lang.String
FIELDNAME_SUBTITLE
Deprecated.Name used by subtitle fields.static java.lang.String
FIELDNAME_TEXT
Deprecated.Name used by text fields.static java.lang.String
FIELDNAME_TITLE
Deprecated.Name used by title fields.static java.lang.String
FIELDNAME_URL
Deprecated.Name used by URL fields.protected boolean
indexed
Deprecated.protected java.lang.String
name
Deprecated.protected boolean
stored
Deprecated.protected boolean
tokenized
Deprecated.protected java.lang.String
value
Deprecated.
-
Constructor Summary
Constructors Constructor Description SearchContentField(java.lang.String name, java.lang.String value, boolean indexed, boolean stored, boolean tokenized)
Deprecated.Constructs aSearchContentField
object.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description SearchContentField
clone()
Deprecated.static SearchContentField
createIdField(java.lang.String value)
Deprecated.Creates anidentifier field
with the given value.static SearchContentField
createSubtitleField(java.lang.String value)
Deprecated.Creates ansubtitle field
with the given value.static SearchContentField
createTextField(java.lang.String value)
Deprecated.Creates antext field
with the given value.static SearchContentField
createTitleField(java.lang.String value)
Deprecated.Creates antitle field
with the given value.static SearchContentField
createUrlField(java.lang.String value)
Deprecated.Creates anURL field
with the given value.java.lang.String
getName()
Deprecated.Returns the field name.java.lang.String
getValue()
Deprecated.Returns the field value.boolean
isIndexed()
Deprecated.Returns the indexed condition of the field.boolean
isStored()
Deprecated.Returns the stored condition of the field.boolean
isTokenized()
Deprecated.Returns the tokenized condition of the field.void
setIndexed(boolean indexed)
Deprecated.Sets the indexed condition of the field.void
setName(java.lang.String name)
Deprecated.Sets the field name.void
setStored(boolean stored)
Deprecated.Sets the stored condition of the field.void
setTokenized(boolean tokenized)
Deprecated.Sets the tokenized condition of the field.void
setValue(java.lang.String value)
Deprecated.Sets the field value.
-
-
-
Field Detail
-
FIELDNAME_ID
public static final java.lang.String FIELDNAME_ID
Deprecated.Name used by identifier fields.An identifier field is the identifier of the content being indexed. It can be used later to retrieve the content from search index.
- Since:
- 4.0.4
- See Also:
- Constant Field Values
-
FIELDNAME_TITLE
public static final java.lang.String FIELDNAME_TITLE
Deprecated.Name used by title fields.A title field is the title of the content being indexed. Usually is used as the name of the hyperlink in a search results interface.
- Since:
- 4.0.4
- See Also:
- Constant Field Values
-
FIELDNAME_SUBTITLE
public static final java.lang.String FIELDNAME_SUBTITLE
Deprecated.Name used by subtitle fields.A subtitle field is the subtitle of the content being indexed. Usually is presented close to the hyperlink in a search results interface, to present additional information of the content.
- Since:
- 4.0.4
- See Also:
- Constant Field Values
-
FIELDNAME_URL
public static final java.lang.String FIELDNAME_URL
Deprecated.Name used by URL fields.An URL field is the URL of the content being indexed. Usually is used as the URL of the hyperlink in a search results interface, consisting in an URL that allows the navigation to the content details.
- Since:
- 4.0.4
- See Also:
- Constant Field Values
-
FIELDNAME_TEXT
public static final java.lang.String FIELDNAME_TEXT
Deprecated.Name used by text fields.A text field is the textual searchable content. This is the only field used by search engines to search for contents based on provided search criteria.
- Since:
- 4.0.4
- See Also:
- Constant Field Values
-
name
protected java.lang.String name
Deprecated.
-
value
protected java.lang.String value
Deprecated.
-
indexed
protected boolean indexed
Deprecated.
-
stored
protected boolean stored
Deprecated.
-
tokenized
protected boolean tokenized
Deprecated.
-
-
Constructor Detail
-
SearchContentField
public SearchContentField(java.lang.String name, java.lang.String value, boolean indexed, boolean stored, boolean tokenized)
Deprecated.Constructs aSearchContentField
object.- Parameters:
name
- field namevalue
- field valueindexed
- true to mark field asstored
-tokenized
-
-
-
Method Detail
-
createIdField
public static SearchContentField createIdField(java.lang.String value)
Deprecated.Creates anidentifier field
with the given value.- Parameters:
value
- field value- Returns:
- created field
- Since:
- 4.0.4
-
createTitleField
public static SearchContentField createTitleField(java.lang.String value)
Deprecated.Creates antitle field
with the given value.- Parameters:
value
- field value- Returns:
- created field
- Since:
- 4.0.4
-
createSubtitleField
public static SearchContentField createSubtitleField(java.lang.String value)
Deprecated.Creates ansubtitle field
with the given value.- Parameters:
value
- field value- Returns:
- created field
- Since:
- 4.0.4
-
createUrlField
public static SearchContentField createUrlField(java.lang.String value)
Deprecated.Creates anURL field
with the given value.- Parameters:
value
- field value- Returns:
- created field
- Since:
- 4.0.4
-
createTextField
public static SearchContentField createTextField(java.lang.String value)
Deprecated.Creates antext field
with the given value.- Parameters:
value
- field value- Returns:
- created field
- Since:
- 4.0.4
-
getName
public java.lang.String getName()
Deprecated.Returns the field name.- Returns:
- the field name
- Since:
- 4.0.4
-
setName
public void setName(java.lang.String name)
Deprecated.Sets the field name.- Parameters:
name
- the field name to set- Since:
- 4.0.4
-
getValue
public java.lang.String getValue()
Deprecated.Returns the field value.- Returns:
- the field value
- Since:
- 4.0.4
-
setValue
public void setValue(java.lang.String value)
Deprecated.Sets the field value.- Parameters:
value
- the field value to set.- Since:
- 4.0.4
-
isIndexed
public boolean isIndexed()
Deprecated.Returns the indexed condition of the field.- Returns:
true
if the field is indexed.- Since:
- 4.0.4
-
setIndexed
public void setIndexed(boolean indexed)
Deprecated.Sets the indexed condition of the field.- Parameters:
indexed
-true
if the field must be indexed.- Since:
- 4.0.4
-
isTokenized
public boolean isTokenized()
Deprecated.Returns the tokenized condition of the field.- Returns:
true
if the field is tokenized.- Since:
- 4.0.4
-
setTokenized
public void setTokenized(boolean tokenized)
Deprecated.Sets the tokenized condition of the field.- Parameters:
tokenized
-true
if the field must be tokenized.- Since:
- 4.0.4
-
isStored
public boolean isStored()
Deprecated.Returns the stored condition of the field.- Returns:
true
if the field is stored.- Since:
- 4.0.4
-
setStored
public void setStored(boolean stored)
Deprecated.Sets the stored condition of the field.- Parameters:
stored
-true
if the field must be stored.- Since:
- 4.0.4
-
clone
public SearchContentField clone()
Deprecated.- Overrides:
clone
in classjava.lang.Object
-
-