Programming - Collection Of Frameworks
You Are Here :: Home > JAVA > Collection Of Frameworks - General Questions
25. |
In Enumeration,how many methods it contains?
|
|
Answer: Option B
Explanation:
Enumeration contains 2 methods namely hasMoreElements() & nextElement() |
|
26. |
How many methods that Iterator Contains?
|
|
Answer: Option C
Explanation:
Iterator contains three methods namely hasNext(), next(),remove(). |
|
27. |
Using _____________ we can delete the objects but Enumeration interface does not support this feature.
|
A. |
remove() |
B.
|
delete() |
C.
|
delEnum()
|
D.
|
removeEnum()
|
|
Answer: Option A
Explanation:
Using remove() we can delete the objects but Enumeration interface does not support this feature. |
|
28. |
_________________________ method returns Enumeration.
|
A. |
Hashtable.elements() |
B.
|
Vector.elements() |
C.
|
Both A and B
|
D.
|
None of these
|
|
Answer: Option C
Explanation:
Vector.elements() & Hashtable.elements() method returns Enumeration. |
|
29. |
_________________________ is returned by all Java Collections Framework classes.
|
A. |
Iterator |
B.
|
ListIterator |
C.
|
Wrapper Classes
|
D.
|
Abstract Classes
|
|
Answer: Option A
Explanation:
Iterator is returned by all Java Collections Framework classes. |
|
30. |
_______________ method returns an instance of Iterator.
|
A. |
Hashtable.elements() |
B.
|
Vector.elements() |
C.
|
java.util.Collection.iterator()
|
D.
|
java.lang.Collection.Item()
|
|
Answer: Option C
Explanation:
java.util.Collection.iterator() method returns an instance of Iterator. |
|
« prev
next »