10-12-2015 11:40 AM
Are we sure that we have correctly defined the signature for searchAndDecrypt(). It currently looks like this:
<T extends BaseDbBean> | searchAndDecrypt(Class<T> classType, Map<String,String> searchParams, Operation op) Searches for all objects matching the search params for the API. |
Although we actually prepare a searchParams Map that is defined as follows (see MultivaluedMap (Java(TM) EE 7 Specification APIs)):
Map < String >, List < String > >
The current signature forces us to use a special MultivaluedMap that seems to do a bit of trickery with the "value" of a "key" in a Map. I'd like to suggest that the signature of this method be changed to the following:
< T extends BaseDbBean > | searchAndDecrypt (Class < T > classType, Map < String, List < String > > searchParams, Operation op) Searches for all objects matching the search params for the API. |
This would allow the following bit of code to work:
final String fieldSetName = "FIELD_SET_A";
final Map < String, List < String > > p = new HashMap < String, List < String > > ();
p.put ("id", Arrays.asList (fieldSetName));
final List < FieldSet > fieldSets = contextServiceClient.searchAndDecrypt (FieldSet.class, p, Operation.OR);
Or am I misinterpreting something?
Solved! Go to Solution.
10-13-2015 07:40 AM
Hi Joseph,
We've passed this along to the design team. Thanks for the feedback!
10-13-2015 07:40 AM
Hi Joseph,
We've passed this along to the design team. Thanks for the feedback!
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide