Unable to extend NumericFieldBridge

Description

Hi,

In the documentation (https://docs.jboss.org/hibernate/stable/search/reference/en-US/html_single/#numeric-field-annotation) we have the example:

Example 27. Defining a custom NumericFieldBridge for BigDecimal

By checking the class (org.hibernate.search.bridge.builtin.NumericFieldBridge), I realized that it is now an 'enum' and the constructor is private respectively.

I believe the documentation is incorrect, or a refactoring made it impossible to extend the class.

Particularly, I'm using with Elasticsearch 5.6 like this:

If it's just the documentation, I can update it. We can even add more examples, such as a custom FieldBridge to a complex enum too.

Test Cases.

TestCase with error: https://github.com/frekele/hibernate-search-elasticsearch-test-case/tree/HSEARCH-2906
Travis CI log: https://travis-ci.org/frekele/hibernate-search-elasticsearch-test-case/builds/282576064

TestCase without error: https://github.com/frekele/hibernate-search-elasticsearch-test-case/tree/HSEARCH-2906-fixed
Travis CI log: https://travis-ci.org/frekele/hibernate-search-elasticsearch-test-case/builds/282577388

Environment

None

Status

Assignee

Yoann Rodière

Reporter

Leandro Kersting de Freitas

Labels

None

Suitable for new contributors

None

Feedback Requested

None

Components

Fix versions

Affects versions

Priority

Major
Configure