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

Support pagination on the Clients entity #124

Merged
merged 3 commits into from
Jun 11, 2018
Merged

Conversation

lbalmaceda
Copy link
Contributor

@lbalmaceda lbalmaceda commented May 31, 2018

This PR refactors the way "Page Deserializers" work to prepare them for a generic approach. It also adds a ClientFilter and a new list(filter) under the clients entity to send pagination parameters, among others.

A separate PR will deprecate the existing list() method, once this one is merged so it can reference the new one.

@lbalmaceda lbalmaceda added this to the v1-Next milestone May 31, 2018
@@ -8,7 +8,7 @@
import java.util.List;

/**
* Class that represents a Page of Auth0 Events objects. Related to the {@link com.auth0.client.mgmt.LogEventsEntity} entity.
* Class that represents a given Page of Log Events. Related to the {@link com.auth0.client.mgmt.LogEventsEntity} entity.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lower case page and log

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I accept the page change, but LogEvents is the name of the class that's why I capitalized it. Should I reference the class with a @link annotation instead?

@@ -8,7 +8,7 @@
import java.util.List;

/**
* Class that represents an Auth0 User object. Related to the {@link com.auth0.client.mgmt.UsersEntity} entity.
* Class that represents a given Page of Users. Related to the {@link com.auth0.client.mgmt.UsersEntity} entity.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lower case page

}

@Override
public ClientFilter withFields(String fields, boolean includeFields) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the point of this logical? If you pick fields surely you would want to include them? Otherwise why include them?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@cocojoe a Client has a huge number of properties. The endpoint accepts a fields value so you can filter them. When you pass a list of fields, you can also say whether you want those fields included (whitelist) or excluded (blacklist) from the response.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah ok, that makes more sense, I miss interpreted it 👍

@lbalmaceda lbalmaceda modified the milestone: v1-Next Jun 4, 2018
Copy link
Member

@cocojoe cocojoe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@lbalmaceda lbalmaceda merged commit 19121df into master Jun 11, 2018
@lbalmaceda lbalmaceda modified the milestones: v1-Next, 1.7.0 Jun 11, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants