@Immutable public class IndexChangeAdapters extends Object
IndexChangeAdapter
instances, which support both single and multi-valued properties.Modifier and Type | Method and Description |
---|---|
static IndexChangeAdapter |
forEnumeratedProperty(ExecutionContext context,
ChangeSetAdapter.NodeTypePredicate matcher,
String workspaceName,
Name propertyName,
ProvidedIndex<?> index)
Create an
IndexChangeAdapter implementation that handles a enumerated properties, either single or multi-valued. |
static IndexChangeAdapter |
forMixinTypes(ExecutionContext context,
ChangeSetAdapter.NodeTypePredicate matcher,
String workspaceName,
ProvidedIndex<?> index)
Create an
IndexChangeAdapter implementation that handles the "jcr:mixinTypes" property. |
static IndexChangeAdapter |
forMultipleColumns(ExecutionContext context,
ChangeSetAdapter.NodeTypePredicate matcher,
String workspaceName,
ProvidedIndex<?> index,
Iterable<IndexChangeAdapter> adapters)
Creates a composite change adapter which handles the case when an index has multiple columns.
|
static IndexChangeAdapter |
forNodeDepth(ExecutionContext context,
ChangeSetAdapter.NodeTypePredicate matcher,
String workspaceName,
ProvidedIndex<?> index)
Create an
IndexChangeAdapter implementation that handles the "mode:nodeDepth" property. |
static IndexChangeAdapter |
forNodeLocalName(ExecutionContext context,
ChangeSetAdapter.NodeTypePredicate matcher,
String workspaceName,
ProvidedIndex<?> index)
Create an
IndexChangeAdapter implementation that handles the "mode:localName" property. |
static IndexChangeAdapter |
forNodeName(ExecutionContext context,
ChangeSetAdapter.NodeTypePredicate matcher,
String workspaceName,
ProvidedIndex<?> index)
Create an
IndexChangeAdapter implementation that handles the "jcr:name" property. |
static IndexChangeAdapter |
forNodePath(ExecutionContext context,
ChangeSetAdapter.NodeTypePredicate matcher,
String workspaceName,
ProvidedIndex<?> index)
Create an
IndexChangeAdapter implementation that handles the "jcr:path" property. |
static IndexChangeAdapter |
forNodeTypes(String propertyName,
ExecutionContext context,
ChangeSetAdapter.NodeTypePredicate matcher,
String workspaceName,
ProvidedIndex<?> index)
Create an
IndexChangeAdapter implementation that handles node type information. |
static IndexChangeAdapter |
forPrimaryType(ExecutionContext context,
ChangeSetAdapter.NodeTypePredicate matcher,
String workspaceName,
ProvidedIndex<?> index)
Create an
IndexChangeAdapter implementation that handles the "jcr:primaryType" property. |
static <T> IndexChangeAdapter |
forProperty(ExecutionContext context,
ChangeSetAdapter.NodeTypePredicate matcher,
String workspaceName,
Name propertyName,
ValueFactory<T> factory,
ProvidedIndex<?> index)
Create an
IndexChangeAdapter implementation that handles a node property, either single or multi-valued. |
static IndexChangeAdapter |
forTextProperty(ExecutionContext context,
ChangeSetAdapter.NodeTypePredicate matcher,
String workspaceName,
Name propertyName,
ValueFactory<String> factory,
ProvidedIndex<?> index)
Create an
IndexChangeAdapter implementation that handles full text information. |
static <T> IndexChangeAdapter |
forUniqueValuedProperty(ExecutionContext context,
ChangeSetAdapter.NodeTypePredicate matcher,
String workspaceName,
Name propertyName,
ValueFactory<T> factory,
ProvidedIndex<?> index)
Create an
IndexChangeAdapter implementation that handles a unique-valued property, where every property value is
unique across all nodes. |
public static IndexChangeAdapter forMultipleColumns(ExecutionContext context, ChangeSetAdapter.NodeTypePredicate matcher, String workspaceName, ProvidedIndex<?> index, Iterable<IndexChangeAdapter> adapters)
context
- the execution context; may not be nullmatcher
- the node type matcher used to determine which nodes should be included in the index; may not be nullworkspaceName
- the name of the workspace; may not be nullindex
- the index that should be used; may not be nulladapters
- an Iterable
of existing "discrete" adapters.IndexChangeAdapter
; never nullpublic static IndexChangeAdapter forNodeDepth(ExecutionContext context, ChangeSetAdapter.NodeTypePredicate matcher, String workspaceName, ProvidedIndex<?> index)
IndexChangeAdapter
implementation that handles the "mode:nodeDepth" property.context
- the execution context; may not be nullmatcher
- the node type matcher used to determine which nodes should be included in the index; may not be nullworkspaceName
- the name of the workspace; may not be nullindex
- the index that should be used; may not be nullIndexChangeAdapter
; never nullpublic static IndexChangeAdapter forNodeName(ExecutionContext context, ChangeSetAdapter.NodeTypePredicate matcher, String workspaceName, ProvidedIndex<?> index)
IndexChangeAdapter
implementation that handles the "jcr:name" property.context
- the execution context; may not be nullmatcher
- the node type matcher used to determine which nodes should be included in the index; may not be nullworkspaceName
- the name of the workspace; may not be nullindex
- the local index that should be used; may not be nullIndexChangeAdapter
; never nullpublic static IndexChangeAdapter forNodeLocalName(ExecutionContext context, ChangeSetAdapter.NodeTypePredicate matcher, String workspaceName, ProvidedIndex<?> index)
IndexChangeAdapter
implementation that handles the "mode:localName" property.context
- the execution context; may not be nullmatcher
- the node type matcher used to determine which nodes should be included in the index; may not be nullworkspaceName
- the name of the workspace; may not be nullindex
- the local index that should be used; may not be nullIndexChangeAdapter
; never nullpublic static IndexChangeAdapter forNodePath(ExecutionContext context, ChangeSetAdapter.NodeTypePredicate matcher, String workspaceName, ProvidedIndex<?> index)
IndexChangeAdapter
implementation that handles the "jcr:path" property.context
- the execution context; may not be nullmatcher
- the node type matcher used to determine which nodes should be included in the index; may not be nullworkspaceName
- the name of the workspace; may not be nullindex
- the local index that should be used; may not be nullIndexChangeAdapter
; never nullpublic static IndexChangeAdapter forPrimaryType(ExecutionContext context, ChangeSetAdapter.NodeTypePredicate matcher, String workspaceName, ProvidedIndex<?> index)
IndexChangeAdapter
implementation that handles the "jcr:primaryType" property.context
- the execution context; may not be nullmatcher
- the node type matcher used to determine which nodes should be included in the index; may not be nullworkspaceName
- the name of the workspace; may not be nullindex
- the local index that should be used; may not be nullIndexChangeAdapter
; never nullpublic static IndexChangeAdapter forMixinTypes(ExecutionContext context, ChangeSetAdapter.NodeTypePredicate matcher, String workspaceName, ProvidedIndex<?> index)
IndexChangeAdapter
implementation that handles the "jcr:mixinTypes" property.context
- the execution context; may not be nullmatcher
- the node type matcher used to determine which nodes should be included in the index; may not be nullworkspaceName
- the name of the workspace; may not be nullindex
- the local index that should be used; may not be nullIndexChangeAdapter
; never nullpublic static <T> IndexChangeAdapter forProperty(ExecutionContext context, ChangeSetAdapter.NodeTypePredicate matcher, String workspaceName, Name propertyName, ValueFactory<T> factory, ProvidedIndex<?> index)
IndexChangeAdapter
implementation that handles a node property, either single or multi-valued.context
- the execution context; may not be nullmatcher
- the node type matcher used to determine which nodes should be included in the index; may not be nullworkspaceName
- the name of the workspace; may not be nullpropertyName
- the name of the property; may not be nullfactory
- the value factory for the property's value type; may not be nullindex
- the local index that should be used; may not be nullIndexChangeAdapter
; never nullpublic static <T> IndexChangeAdapter forUniqueValuedProperty(ExecutionContext context, ChangeSetAdapter.NodeTypePredicate matcher, String workspaceName, Name propertyName, ValueFactory<T> factory, ProvidedIndex<?> index)
IndexChangeAdapter
implementation that handles a unique-valued property, where every property value is
unique across all nodes.context
- the execution context; may not be nullmatcher
- the node type matcher used to determine which nodes should be included in the index; may not be nullworkspaceName
- the name of the workspace; may not be nullpropertyName
- the name of the property; may not be nullfactory
- the value factory for the property's value type; may not be nullindex
- the local index that should be used; may not be nullIndexChangeAdapter
; never nullpublic static IndexChangeAdapter forEnumeratedProperty(ExecutionContext context, ChangeSetAdapter.NodeTypePredicate matcher, String workspaceName, Name propertyName, ProvidedIndex<?> index)
IndexChangeAdapter
implementation that handles a enumerated properties, either single or multi-valued.context
- the execution context; may not be nullmatcher
- the node type matcher used to determine which nodes should be included in the index; may not be nullworkspaceName
- the name of the workspace; may not be nullpropertyName
- the name of the property; may not be nullindex
- the local index that should be used; may not be nullIndexChangeAdapter
; never nullpublic static IndexChangeAdapter forNodeTypes(String propertyName, ExecutionContext context, ChangeSetAdapter.NodeTypePredicate matcher, String workspaceName, ProvidedIndex<?> index)
IndexChangeAdapter
implementation that handles node type information.propertyName
- a symbolic name of the property that will be sent to the ProvidedIndex
when the adapter
notices that there are either primary type of mixin type changes.context
- the execution context; may not be nullmatcher
- the node type matcher used to determine which nodes should be included in the index; may not be nullworkspaceName
- the name of the workspace; may not be nullindex
- the local index that should be used; may not be nullIndexChangeAdapter
; never nullpublic static IndexChangeAdapter forTextProperty(ExecutionContext context, ChangeSetAdapter.NodeTypePredicate matcher, String workspaceName, Name propertyName, ValueFactory<String> factory, ProvidedIndex<?> index)
IndexChangeAdapter
implementation that handles full text information.context
- the execution context; may not be nullmatcher
- the node type matcher used to determine which nodes should be included in the index; may not be nullworkspaceName
- the name of the workspace; may not be nullpropertyName
- the name of the property; may not be nullfactory
- the value factory for the property's value type; may not be nullindex
- the local index that should be used; may not be nullIndexChangeAdapter
; never nullCopyright © 2008–2016 JBoss, a division of Red Hat. All rights reserved.