How can I overload an iterator/create an iterator

P

Pranav

How can I overload an iterator/create an iterator of my own as per my
requirements for a template class of my own?

Thank You,
 
J

Jerry Coffin

How can I overload an iterator/create an iterator of my own as per my
requirements for a template class of my own?

Yes, you can create your own iterators. std::iterator (for one) is
provided primarily as a base class in an attempt at making this a bit
simpler. IIRC, Boost also has a library that attempts to make it easier
to create your own iterators as well.
 
P

Pranav

But How? Iterator is an data type specifier/ it is an operator? I am
not getting.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,170
Messages
2,570,927
Members
47,469
Latest member
benny001

Latest Threads

Top