What is the difference between Enumeration and Iteration
interfaces? What is the way of to retreive the objects from
these interfaces ?



What is the difference between Enumeration and Iteration interfaces? What is the way of to retreiv..

Answer / suma

1.Enumeration interface applicable legacy implemented classes.
Iterator is applicable for all collection implemented classes.
2.Enumeration :While iterating the elements we are not
allowed to remove the objects just we can perform only read
operation
Iterator:While iterating we can perform removal also in
addition to read operation
3. Enumeration uses elements() method ,
Iterator uses iterator() method

Is This Answer Correct ?    8 Yes 0 No

Post New Answer

More Java Related AllOther Interview Questions

What is meant by annotation in java?

0 Answers  


what is the serialization?

2 Answers   TCS,


I am trying to create a new universal user group. Why can't i? : java security

0 Answers  


What is setstring method in java?

0 Answers  


Is java installed on windows 10?

0 Answers  






What is flatmap in java8?

0 Answers  


What about products that claim to detect malicious applets? : java security

0 Answers  


What is a java executable jar file?

0 Answers  


Java prints out a ton of digits when I system.out.println() a double. How can I format it so it displays only 3 digits after the decimal place?

0 Answers  


How do javabeans work?

0 Answers  


How does java handle integer overflows and underflows?

0 Answers  


How to load a class programmatically?

1 Answers  


Categories