Sep
12
2010
12
2010
Design Patterns : Iterator pattern
What is iteration?
In computer science, an iterator is an object which allows a programmer to traverse through all the elements of a collection, regardless of its specific implementation. An iterator is sometimes called a cursor, especially within the context of a database.
Intent
Provide a way to access the elements of an aggregate object sequentially without exposing its underlying representation.
Diagram

Applicability
Use Iterator pattern
- To access an aggregate object’s contents without exposing its internal representation.
- To support multiple traversals of aggregate objects.
- To provide a uniform interface for traversing different aggregate structures (that is, to support polymorphic iteration)
Related Posts
1 Comment + Add Comment
Recent Posts
- How to populate a dropdown menu from database in CodeIgniter [Workaround]
- How to Overclock Samsung Galaxy Mini Upto 800MHz
- Current and Future Relavance of Business Excellence / Improvement to Argos UK Ltd. Possible Benefits and Likely Inhabitors Exists
- What can Harm Your Online Reputation?
- Does Race Matter in the Choice of Popular Music among Youngsters?
The Tutebox
- Accounting
- Android Tips
- Apps
- Business
- C / C++
- Computers
- Database
- Design Patterns
- E-Commerce
- Economics
- Electronics
- Entertainment
- Finance
- Functional Programming
- Games
- Hardware
- Health
- HRM
- International Business
- Internet
- iOS Tips
- JAVA
- Life Style
- Linux
- M-Commerce
- Management
- Marketing
- Mathematics
- Mobile
- MS Office
- Network
- PC
- Personal Development
- Photography
- PHP
- Physics
- Places
- Programming
- Science
- Software
- Statistics
- Tweaks
- Visual Studio
- Web Hosting
- Windows

Article by





Splendid article . Will definitely copy it to my blog,surely with link pointing towards you..Thanks.