Skip to content

Commit 6705e69

Browse files
DavideDSanne
authored andcommitted
HSEARCH-2387 Fix javadoc
1 parent 61619d5 commit 6705e69

File tree

5 files changed

+19
-17
lines changed

5 files changed

+19
-17
lines changed

elasticsearch/src/main/java/org/hibernate/search/elasticsearch/cfg/DynamicType.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,10 @@
99
/**
1010
* Configuration values for Elasticsearch "dynamic" attribute values.
1111
* <p>
12-
* Defines the behaviour when a document contains an unrecognized field.
13-
*
14-
* @see <a href="https://www.elastic.co/guide/en/elasticsearch/reference/current/dynamic.html">Elasticsearch mapping:
12+
* Defines the behaviour when a document contains a field the wasn't define in the index schema.
13+
* <p>
14+
* More details on the Elasticsearch documentation:
15+
* <a href="https://www.elastic.co/guide/en/elasticsearch/reference/current/dynamic.html">Elasticsearch mapping:
1516
* dynamic</a>
1617
*
1718
* @author Davide D'Alto

elasticsearch/src/main/java/org/hibernate/search/elasticsearch/cfg/ElasticsearchEnvironment.java

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -225,14 +225,15 @@ public static final class Defaults {
225225
public static final String SCROLL_TIMEOUT = "elasticsearch.scroll_timeout";
226226

227227
/**
228-
* Property for specifying the behaviour when Elasticsearch encounters a previously unknown field in a document.
228+
* Equivalent to elasticsearch "dynamic", define what to do when a document contains a field which was not declared
229+
* in the index schema.
229230
* <p>
230231
* Possible values are:
231232
* <p>
232233
* <ul>
233-
* <li>{@code true}: Add new fields dynamically</li>
234-
* <li>{@code false}: Ignore new fields</li>
235-
* <li>{@code strict}: Throw an exception if an unknown field is encountered</li>
234+
* <li>{@code true}: Add new fields dynamically</li>
235+
* <li>{@code false}: Ignore new fields</li>
236+
* <li>{@code strict}: Throw an exception</li>
236237
* </ul>
237238
* <p>
238239
* Defaults to {@code strict}.

engine/src/main/java/org/hibernate/search/bridge/spi/FieldMetadataCreationContext.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,10 @@ public interface FieldMetadataCreationContext {
3535
FieldMetadataCreationContext sortable(boolean sortable);
3636

3737
/**
38-
* Give access to properties that are backend specific
38+
* Gives access to properties that are specific to an indexing technology.
3939
*
40-
* @param backendType the selected backend.
40+
* @param indexTechnology the selected index technology.
4141
* @return the context for the fluent API related to the select backend.
4242
*/
43-
<T extends FieldMetadataCreationContext> T mappedOn(Class<T> backendType);
43+
<T extends FieldMetadataCreationContext> T mappedOn(Class<T> indexTechnology);
4444
}

engine/src/main/java/org/hibernate/search/bridge/spi/FieldType.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ public enum FieldType {
5151
DOUBLE,
5252

5353
/**
54-
* An object field, a generic object that doesn't have a unique definition in all the backends.
54+
* A composite object that will benefit from using a different encoding on each indexing technology.
5555
* <p>
5656
* For example, it could identify a field that should be mapped in Elasticsearch as an inner object and in Lucene
5757
* as multiple string fields (Lucene does not have inner objects).

engine/src/main/java/org/hibernate/search/engine/metadata/impl/BridgeDefinedField.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ public class BridgeDefinedField {
2929
private final FieldType type;
3030

3131
/*
32-
* Backends have specific field properties (Elastic search dynamic mapping for example). this map will group the
33-
* properties per backend.
32+
* This map will group bridge defined field properties that make sense only for specific index managers.
33+
* For example, in Elasticsearch one can specify the mapping as dynamic.
3434
*/
3535
private Map<Class<?>, Object> extra = new HashMap<>();
3636

@@ -84,12 +84,12 @@ public <T> void add(Class<T> backendBridgeDefineFieldClass, T backendBridgeDefin
8484
}
8585

8686
/**
87-
* Returns the object containing the properties of the field for the specific class.
87+
* Get the bridge defined field of the specific class.
8888
*
89-
* @param backendBridgeDefineFieldClass the type of the object containing the properties of the field
89+
* @param bridgeDefineFieldClass the type of the object containing the properties of the field
9090
* @return the object containing the properties of the field
9191
*/
92-
public <T> T mappedOn(Class<T> backendBridgeDefineFieldClass) {
93-
return backendBridgeDefineFieldClass.cast( extra.get( backendBridgeDefineFieldClass ) );
92+
public <T> T mappedOn(Class<T> bridgeDefineFieldClass) {
93+
return bridgeDefineFieldClass.cast( extra.get( bridgeDefineFieldClass ) );
9494
}
9595
}

0 commit comments

Comments
 (0)