public class SearchIndexerDataLocationBean extends Object implements SearchIndexerDataLocation, JaxbObject
SearchIndexerDataLocation as JAXB-ready
Java-Bean.| Modifier and Type | Field and Description |
|---|---|
private boolean |
absoluteUris |
private String |
baseUri |
private String |
encoding |
private FilterRuleChain<String> |
filter |
private String |
localtionUri |
private SearchIndexerSourceBean |
source |
private String |
updateStrategyVariant |
private StringTransformerChain |
uriTransformer |
UPDATE_STRATEGY_VCS_VARIANT_BAZAAR, UPDATE_STRATEGY_VCS_VARIANT_CVS, UPDATE_STRATEGY_VCS_VARIANT_GIT, UPDATE_STRATEGY_VCS_VARIANT_MERCURIAL, UPDATE_STRATEGY_VCS_VARIANT_PERFORCE, UPDATE_STRATEGY_VCS_VARIANT_SVN, UPDATE_STRATEGY_VCS_VARIANT_TFS, UPDATE_STRATEGY_VCS_VARIANT_VSS| Constructor and Description |
|---|
SearchIndexerDataLocationBean()
The constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
afterUnmarshal(Unmarshaller unmarshaller,
Object parent)
This method is automatically invoked by JAXB after un-marshaling this bean.
|
String |
getBaseUri()
This method gets the base-URI used to build the
search-entry-URI for the
location itself. |
String |
getEncoding()
This method gets the encoding of the resources in this location.
|
FilterRuleChain<String> |
getFilter()
|
String |
getLocationUri()
This method gets the location (typically an URL) with the data that should
be part of the search index.
|
SearchIndexerSource |
getSource()
This method gets the
Source associated with
this directory. |
String |
getUpdateStrategyVariant()
This method determines the optional variant of the
update-strategy. |
StringTransformerChain |
getUriTransformer()
This method gets the
Transformer used to
convert the (relative) URI of a
resource to the indexed
URI. |
boolean |
isAbsoluteUris()
This method determines if
search-entry-URIs should
be set to the absolute location. |
void |
setAbsoluteUris(boolean absoluteUris) |
void |
setBaseUri(String baseUri) |
void |
setEncoding(String encoding) |
void |
setFilter(FilterRuleChain<String> filter) |
void |
setLocaltionUri(String path) |
void |
setSource(SearchIndexerSourceBean source) |
void |
setUpdateStrategyVariant(String updateStrategyVariant)
This method sets the
update-strategy-variant. |
void |
setUriTransformer(StringTransformerChain uriTransformer) |
private String localtionUri
getLocationUri()private transient SearchIndexerSourceBean source
getSource()private String encoding
getEncoding()private String baseUri
getBaseUri()private boolean absoluteUris
isAbsoluteUris()private FilterRuleChain<String> filter
getFilter()private StringTransformerChain uriTransformer
getUriTransformer()private String updateStrategyVariant
getUpdateStrategyVariant()public SearchIndexerDataLocationBean()
public String getLocationUri()
filter. getLocationUri in interface SearchIndexerDataLocationpublic void setLocaltionUri(String path)
path - is the path to setpublic SearchIndexerSource getSource()
Source associated with
this directory.getSource in interface SearchIndexerDataLocationSearchIndexerSource.public void setSource(SearchIndexerSourceBean source)
source - is the source to setpublic String getEncoding()
getEncoding in interface SearchIndexerDataLocationnull for automatic
unicode detection.public void setEncoding(String encoding)
encoding - is the encoding to setpublic String getBaseUri()
search-entry-URI for the
location itself. locations of the same
source you can use this attribute. E.g. when
source is "svn" and you
have one location that
points to where you checked out "trunk/documents"
of a subversion repository then the base-URI may be
"documents". Analog you may also have another
location with a base-URI of "development/code". Therefore
SearchSource.getUrlPrefix() may be something like
"http://svn.foo.bar/trunk/".getBaseUri in interface SearchIndexerDataLocationpublic void setBaseUri(String baseUri)
baseUri - is the baseUri to setpublic boolean isAbsoluteUris()
search-entry-URIs should
be set to the absolute location. This can make
sense if you want to index a web-site via an HTTP-location but also some related sites linked from there. In all other cases
this should be false.isAbsoluteUris in interface SearchIndexerDataLocationtrue if the absolute URIs should be stored in the
search-index, false if the URIs should be relative to
location with respect to the
base-URI.SearchIndexerDataLocation.getBaseUri()public void setAbsoluteUris(boolean absoluteUris)
absoluteUris - is the absoluteUris to setpublic FilterRuleChain<String> getFilter()
SearchIndexerDataLocationFilter that decides which resource-URIs should
be accepted for indexing. files AND folders.
If a folder is NOT accepted then this entire
folder is NOT crawled any further and therefore its
children are NOT indexed. All
files that are crawled
and accepted will be
added to the search-index.getFilter in interface SearchIndexerDataLocationpublic void setFilter(FilterRuleChain<String> filter)
filter - is the filter to setpublic StringTransformerChain getUriTransformer()
Transformer used to
convert the (relative) URI of a
resource to the indexed
URI. By default the transformer will keep the URI untouched. However the
Transformer can rewrite the URI if it differs from the path to
access the file online. E.g. the relevant files in the data directory of a
twiki/foswiki installation have the extension .txt while their URLs do NOT
contain this extension.getUriTransformer in interface SearchIndexerDataLocationTransformer.public void setUriTransformer(StringTransformerChain uriTransformer)
uriTransformer - is the uriTransformer to setpublic String getUpdateStrategyVariant()
update-strategy. update-strategy
of the according SearchIndexerSource is
SearchIndexerSource.UPDATE_STRATEGY_VCS, then this variant can
determine the actual VCS to use (see
UPDATE_STRATEGY_VCS_VARIANT_* constants like
SearchIndexerDataLocation.UPDATE_STRATEGY_VCS_VARIANT_SVN). However if not set (
null) the VCS will be auto detected (by looking for folders
like .svn, .hg, .git, etc.)getUpdateStrategyVariant in interface SearchIndexerDataLocationupdate-strategy or null for default.public void setUpdateStrategyVariant(String updateStrategyVariant)
update-strategy-variant.updateStrategyVariant - is the new value to set.public void afterUnmarshal(Unmarshaller unmarshaller, Object parent)
afterUnmarshal in interface JaxbObjectunmarshaller - is the Unmarshaller.parent - is the java-object representing the parent node in XML.Copyright © 2001–2016 mmm-Team. All rights reserved.