Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please document use of generic classes to parse search results #3038

Open
alexspurling opened this issue Apr 23, 2024 · 0 comments
Open

Please document use of generic classes to parse search results #3038

alexspurling opened this issue Apr 23, 2024 · 0 comments

Comments

@alexspurling
Copy link

The current documentation for the Java API client is out of date. It shows an example with the following code:

SearchForHits request = new SearchForHits()
        .setIndexName("<YOUR_INDEX_NAME>")
        .setQuery("my aloglia ojbect");
SearchMethodParams params = new SearchMethodParams().addRequests(request);
SearchResponses responses = client.search(params);
System.out.println(responses);

This will fail because as of #2413 the client.search method now requires two parameters. It's not clear from the javadoc of this function what value for the second parameter innerType is expected.

Please give documentation which is up to date and describes how to use generics. Alternatively please give documentation how how to use the client library without using generics.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant