Andrus Adamchik created CAY-2807:
------------------------------------
Summary: EntityProperty.inId(..) / ninId(..) - disambiguate method
parameters
Key: CAY-2807
URL: https://issues.apache.org/jira/browse/CAY-2807
Project: Cayenne
Issue Type: Improvement
Affects Versions: 4.2
Reporter: Andrus Adamchik
Assignee: Nikita Timofeev
Fix For: 5.0.M1
EntityProperty has a few polymorphic methods to bind "in" and "nin" ID arrays.
E.g. for "in":
{noformat}
Expression inId(Collection<Object> ids)
Expression inId(Object firstId, Object... moreIds)
{noformat}
This API has a few issues - parameter ambiguity (e.g. code trying to bind IDs
as a "Set<String>" would hit the second (vararg) method instead of the desired
first method), and inability to bind an Object[].
We need to redesign this API to address the two problems above... Maybe smth
like this:
{noformat}
Expression idsIn(Object... ids)
Expression idsInCollection(Collection<?> ids)
{noformat}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)