Class AbstractElasticsearchIndexCompositeNodeBuilder
java.lang.Object
org.hibernate.search.backend.elasticsearch.document.model.dsl.impl.AbstractElasticsearchIndexCompositeNodeBuilder
- All Implemented Interfaces:
IndexCompositeNodeBuilder,IndexSchemaBuildContext
- Direct Known Subclasses:
ElasticsearchIndexRootBuilder
public abstract class AbstractElasticsearchIndexCompositeNodeBuilder
extends Object
implements IndexCompositeNodeBuilder
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAbstractElasticsearchIndexCompositeNodeBuilder(ElasticsearchIndexCompositeNodeType.Builder typeBuilder) -
Method Summary
Modifier and TypeMethodDescriptionaddField(String relativeFieldName, TreeNodeInclusion inclusion, IndexFieldType<F> indexFieldType) Create a new field and add it to the current builder.addFieldTemplate(String templateName, TreeNodeInclusion inclusion, IndexFieldType<?> indexFieldType, String prefix) Create a new field template and add it to the current builder.addNamedPredicate(String name, TreeNodeInclusion inclusion, PredicateDefinition definition) Create a new named predicate and add it to the current builder.addObjectField(String relativeFieldName, TreeNodeInclusion inclusion, ObjectStructure structure) Create a new object field and add it to the current builder.addObjectFieldTemplate(String templateName, ObjectStructure structure, String prefix, TreeNodeInclusion inclusion) Create a new object field template and add it to the current builder.toString()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.hibernate.search.engine.backend.document.model.dsl.spi.IndexSchemaBuildContext
eventContext
-
Field Details
-
typeBuilder
-
-
Constructor Details
-
AbstractElasticsearchIndexCompositeNodeBuilder
protected AbstractElasticsearchIndexCompositeNodeBuilder(ElasticsearchIndexCompositeNodeType.Builder typeBuilder)
-
-
Method Details
-
toString
-
addField
public <F> IndexSchemaFieldOptionsStep<?,IndexFieldReference<F>> addField(String relativeFieldName, TreeNodeInclusion inclusion, IndexFieldType<F> indexFieldType) Description copied from interface:IndexCompositeNodeBuilderCreate a new field and add it to the current builder.- Specified by:
addFieldin interfaceIndexCompositeNodeBuilder- Type Parameters:
F- The type of values for the new field- Parameters:
relativeFieldName- The relative name of the new fieldinclusion- Whether fields matching this template should be included, provided their parent is included.indexFieldType- The type of the new field- Returns:
- A DSL step where the field can be defined in more details.
-
addObjectField
public IndexObjectFieldBuilder addObjectField(String relativeFieldName, TreeNodeInclusion inclusion, ObjectStructure structure) Description copied from interface:IndexCompositeNodeBuilderCreate a new object field and add it to the current builder.- Specified by:
addObjectFieldin interfaceIndexCompositeNodeBuilder- Parameters:
relativeFieldName- The relative name of the new object fieldinclusion- Whether fields matching this template should be included, provided their parent is included.structure- The structure of the new object field- Returns:
- A builder for the new object field
-
addNamedPredicate
public IndexSchemaNamedPredicateOptionsStep addNamedPredicate(String name, TreeNodeInclusion inclusion, PredicateDefinition definition) Description copied from interface:IndexCompositeNodeBuilderCreate a new named predicate and add it to the current builder.- Specified by:
addNamedPredicatein interfaceIndexCompositeNodeBuilder- Parameters:
name- The relative name of the new named predicate.inclusion- Whether fields matching this template should be included, provided their parent is included.definition- The definition of the named predicate.- Returns:
- A DSL step where the named predicate can be defined in more details.
-
addFieldTemplate
public IndexSchemaFieldTemplateOptionsStep<?> addFieldTemplate(String templateName, TreeNodeInclusion inclusion, IndexFieldType<?> indexFieldType, String prefix) Description copied from interface:IndexCompositeNodeBuilderCreate a new field template and add it to the current builder.- Specified by:
addFieldTemplatein interfaceIndexCompositeNodeBuilder- Parameters:
templateName- The name of the new templateinclusion- Whether fields matching this template should be included, provided their parent is included.indexFieldType- The type of the new field templateprefix- A prefix to prepend to theglob patternand to field paths passed toDocumentElement.addValue(String, Object).- Returns:
- A DSL step where the field template can be defined in more details.
-
addObjectFieldTemplate
public IndexSchemaFieldTemplateOptionsStep<?> addObjectFieldTemplate(String templateName, ObjectStructure structure, String prefix, TreeNodeInclusion inclusion) Description copied from interface:IndexCompositeNodeBuilderCreate a new object field template and add it to the current builder.- Specified by:
addObjectFieldTemplatein interfaceIndexCompositeNodeBuilder- Parameters:
templateName- The name of the new templatestructure- The structure of the new object field templateprefix- A prefix to prepend to theglob patternand to field paths passed toDocumentElement.addObject(String).inclusion- Whether fields matching this template should be included, provided their parent is included.- Returns:
- A DSL step where the field template can be defined in more details.
-