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

Allow filtering forPackage with type #706

Closed
xenoterracide opened this issue Sep 22, 2022 · 2 comments
Closed

Allow filtering forPackage with type #706

xenoterracide opened this issue Sep 22, 2022 · 2 comments
Labels

Comments

@xenoterracide
Copy link

xenoterracide commented Sep 22, 2022

See #697 (comment) for context

use forPackage is if I could do some kind of forPackageWithType("my.package", AbstactClassOrInterface.class) so that I could scan but check only things of that type.

This would be incredibly useful for things like scanning entities and aggregates that have an abstract base class or a common interface. I'm not sure how to fit recursive in here... but given that I would probably always use it that way with a filter.

@jqno jqno added the accepted label Sep 23, 2022
@jqno
Copy link
Owner

jqno commented Sep 23, 2022

So, to make it specific: EqualsVerifier would only check classes that are
a) in the specified package, AND
b) implement or extend the given class.

@jqno
Copy link
Owner

jqno commented Nov 2, 2022

I've just added this in version 3.11, which is now syncing with Maven Central.

@jqno jqno closed this as completed Nov 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants