Class PojoModelPath.Builder
- java.lang.Object
-
- org.hibernate.search.mapper.pojo.model.path.PojoModelPath.Builder
-
- Enclosing class:
- PojoModelPath
public static class PojoModelPath.Builder extends Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PojoModelPath.Builderproperty(String propertyName)Append to the path an access the property with the given name.PojoModelPathPropertyNodetoPropertyPath()PojoModelPathPropertyNodetoPropertyPathOrNull()PojoModelPathValueNodetoValuePath()PojoModelPathValueNodetoValuePathOrNull()PojoModelPath.Buildervalue(String extractorName)Append to the path a value extraction using the given container extractor.PojoModelPath.Buildervalue(ContainerExtractorPath extractorPath)Append to the path a value extraction using the given container extractor path.PojoModelPath.BuildervalueWithDefaultExtractors()Append to the path a value extraction using the default container extractors.PojoModelPath.BuildervalueWithoutExtractors()Append to the path a direct value extraction, not using any container extractors.
-
-
-
Method Detail
-
property
public PojoModelPath.Builder property(String propertyName)
Append to the path an access the property with the given name.- Parameters:
propertyName- The name of the property to access.- Returns:
this, for method chaining.- Throws:
org.hibernate.search.util.common.SearchException- If no property name was previously given.
-
value
public PojoModelPath.Builder value(ContainerExtractorPath extractorPath)
Append to the path a value extraction using the given container extractor path.- Parameters:
extractorPath- The container extractors to apply, as aContainerExtractorPath.- Returns:
this, for method chaining.- Throws:
org.hibernate.search.util.common.SearchException- If no property name was previously given.
-
value
public PojoModelPath.Builder value(String extractorName)
Append to the path a value extraction using the given container extractor.Multiple
value(String)calls can be chained to apply multiple extractors.- Parameters:
extractorName- The name of the container extractor to apply.- Returns:
this, for method chaining.- Throws:
org.hibernate.search.util.common.SearchException- If no property name was previously given.- See Also:
BuiltinContainerExtractors
-
valueWithoutExtractors
public PojoModelPath.Builder valueWithoutExtractors()
Append to the path a direct value extraction, not using any container extractors.- Returns:
this, for method chaining.- Throws:
org.hibernate.search.util.common.SearchException- If no property name was previously given.
-
valueWithDefaultExtractors
public PojoModelPath.Builder valueWithDefaultExtractors()
Append to the path a value extraction using the default container extractors.- Returns:
this, for method chaining.- Throws:
org.hibernate.search.util.common.SearchException- If no property name was previously given.
-
toPropertyPath
public PojoModelPathPropertyNode toPropertyPath()
- Returns:
- A
PojoModelPathPropertyNodebuilt from the given components. - Throws:
org.hibernate.search.util.common.SearchException- If no initial property name was given.
-
toPropertyPathOrNull
public PojoModelPathPropertyNode toPropertyPathOrNull()
- Returns:
- A
PojoModelPathPropertyNodebuilt from the given components, ornullif no information was added to this builder.
-
toValuePath
public PojoModelPathValueNode toValuePath()
- Returns:
- A
PojoModelPathValueNodebuilt from the given components. - Throws:
org.hibernate.search.util.common.SearchException- If no initial property name was given.
-
toValuePathOrNull
public PojoModelPathValueNode toValuePathOrNull()
- Returns:
- A
PojoModelPathValueNodebuilt from the given components, ornullif no information was added to this builder.
-
-