If I have this line in the code java.util.Collection search = searchQuery1.getResultList();
Is this a collection of <list>? and can I find out if search should be named"Search" or does it have to be instantiated of something?
ceyesuma
-4
Posting Pro
Recommended Answers
Jump to PostThere is absolutely no way to tell the type of the collection from that line of code. The return type of that method will be documented by whatever API describes the class of "searchQuery1".
The question about "search" vs "Search" doesn't make any sense - it's your variable declaration, …
Jump to PostThanks for posting generic information on a Collection for whoever might randomly need such, but it doesn't change the fact that the actually return type of that collection can only be ascertained by the api itself. Perhaps you need to reword your original question, because based upon this last post …
All 6 Replies
Ezzaral
2,714
Posting Sage
Team Colleague
Featured Poster
ceyesuma
-4
Posting Pro
ceyesuma
-4
Posting Pro
Ezzaral
2,714
Posting Sage
Team Colleague
Featured Poster
ceyesuma
-4
Posting Pro
Ezzaral
2,714
Posting Sage
Team Colleague
Featured Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.