Interface PropertyMappingStep

    • Method Detail

      • hostingType

        TypeMappingStep hostingType()
        Returns:
        A DSL step where the mapping can be defined for the type hosting this property.
      • documentId

        PropertyMappingDocumentIdOptionsStep documentId()
        Maps the property to the identifier of documents in the index.

        This is only taken into account on Indexed types.

        Returns:
        A DSL step where the document ID mapping can be defined in more details, or where other elements can be mapped to the property.
        See Also:
        DocumentId
      • genericField

        PropertyMappingGenericFieldOptionsStep genericField()
        Maps the property to a field of standard type in the index with the same name as this property.
        Returns:
        A DSL step where the field mapping can be defined in more details, or where other elements can be mapped to the property.
        See Also:
        GenericField
      • genericField

        PropertyMappingGenericFieldOptionsStep genericField​(String relativeFieldName)
        Maps the property to a field of standard type in the index with a custom name.
        Parameters:
        relativeFieldName - The name of the index field.
        Returns:
        A DSL step where the field mapping can be defined in more details, or where other elements can be mapped to the property.
        See Also:
        GenericField, GenericField.name()
      • fullTextField

        PropertyMappingFullTextFieldOptionsStep fullTextField()
        Maps the property to a full-text field in the index with the same name as this property.
        Returns:
        A DSL step where the field mapping can be defined in more details, or where other elements can be mapped to the property.
        See Also:
        FullTextField
      • fullTextField

        PropertyMappingFullTextFieldOptionsStep fullTextField​(String relativeFieldName)
        Maps the property to a full-text field in the index with a custom name.
        Parameters:
        relativeFieldName - The name of the index field.
        Returns:
        A DSL step where the field mapping can be defined in more details, or where other elements can be mapped to the property.
        See Also:
        FullTextField, FullTextField.name()
      • keywordField

        PropertyMappingKeywordFieldOptionsStep keywordField()
        Maps the property to a keyword field in the index with the same name as this property.
        Returns:
        A DSL step where the field mapping can be defined in more details, or where other elements can be mapped to the property.
        See Also:
        KeywordField
      • keywordField

        PropertyMappingKeywordFieldOptionsStep keywordField​(String relativeFieldName)
        Maps the property to a keyword field in the index with a custom name.
        Parameters:
        relativeFieldName - The name of the index field.
        Returns:
        A DSL step where the field mapping can be defined in more details, or where other elements can be mapped to the property.
        See Also:
        KeywordField, KeywordField.name()
      • scaledNumberField

        PropertyMappingScaledNumberFieldOptionsStep scaledNumberField()
        Maps the property to a scaled number field in the index with the same name as this property.
        Returns:
        A DSL step where the field mapping can be defined in more details, or where other elements can be mapped to the property.
        See Also:
        ScaledNumberField
      • nonStandardField

        PropertyMappingFieldOptionsStep<?> nonStandardField()
        Maps the property to a field of non-standard type in the index with the same name as this property.

        This is for advanced use cases, when defining a field whose type is only supported in a specific backend.

        Returns:
        A DSL step where the field mapping can be defined in more details, or where other elements can be mapped to the property.
        See Also:
        NonStandardField
      • nonStandardField

        PropertyMappingFieldOptionsStep<?> nonStandardField​(String relativeFieldName)
        Maps the property to a field of non-standard type in the index with a custom name.

        This is for advanced use cases, when defining a field whose type is only supported in a specific backend.

        Parameters:
        relativeFieldName - The name of the index field.
        Returns:
        A DSL step where the field mapping can be defined in more details, or where other elements can be mapped to the property.
        See Also:
        NonStandardField, NonStandardField.name()
      • indexedEmbedded

        PropertyMappingIndexedEmbeddedStep indexedEmbedded()
        Maps the property to an object field whose fields are the same as those defined in the property type, using the name of this property as the name of the object field.
        Returns:
        A DSL step where the indexed-embedded mapping can be defined in more details, or where other elements can be mapped to the property.
        See Also:
        IndexedEmbedded
      • indexedEmbedded

        PropertyMappingIndexedEmbeddedStep indexedEmbedded​(String relativeFieldName)
        Maps the property to an object field whose fields are the same as those defined in the property type, using the given custom name as the name of the object field.
        Parameters:
        relativeFieldName - The name of the object field created for this indexed-embedded mapping.
        Returns:
        A DSL step where the indexed-embedded mapping can be defined in more details, or where other elements can be mapped to the property.
        See Also:
        IndexedEmbedded, IndexedEmbedded.name()
      • associationInverseSide

        AssociationInverseSideOptionsStep associationInverseSide​(PojoModelPathValueNode inversePath)
        Assuming the property represents an association on a entity type A to entity type B, defines the inverse side of an association, i.e. the path from B to A.

        This is generally not needed, as inverse sides of associations should generally be inferred by the mapper. For example, Hibernate ORM defines inverse sides using @OneToMany#mappedBy, @OneToOne#mappedBy, etc., and the Hibernate ORM mapper will register these inverse sides automatically.

        Parameters:
        inversePath - The path representing the inverse side of the association.
        Returns:
        A DSL step where the association's inverse side can be defined in more details, or where other elements can be mapped to the property.
        See Also:
        AssociationInverseSide, PojoModelPath.ofValue(String), PojoModelPath.ofValue(String, ContainerExtractorPath), PojoModelPath.builder()
      • indexingDependency

        IndexingDependencyOptionsStep indexingDependency()
        Defines how a dependency of the indexing process to this property should affect automatic reindexing.
        Returns:
        A DSL step where indexing dependency can be defined in more details, or where other elements can be mapped to the property.