Boost logo

Boost :

From: Gary Powell (Gary.Powell_at_[hidden])
Date: 2000-09-12 09:42:21

Why does this sound like a homework assignment?

Anyway First, its off topic, boost is not a how to learn to program list
server, try USNET, comp.lang.c++, or comp.lang.c++.mod

Second, get a good STL text, I like the latest "The C++ Standard Library" by
N. Josuttis.
If you don't have time to buy and read the book, or perhaps in addition,
there is some on line documentation at

Third, who ever designed class "Point" made the member functions you wish to
access "protected", this means only Point or classes which inherit from
Point can access them. See a good learn to program C++ book to find out
about this sort of task. I've always been partial to the "C++ Primer" by S.
Lippman, but there are others.

Fourth, whoever designed list<queue<Point> > wanted a lot of copies of all
the data. Ick!

Sorry to be less than fully helpful, but this isn't really the place for
this discussion. Boost is for discussing new libraries.

  Yours Truly,


> -----Original Message-----
> From: Ekkachart Hattha [SMTP:ekkachart_at_[hidden]]
> Sent: Tuesday, September 12, 2000 7:26 AM
> To: boost_at_[hidden]
> Subject: [boost] Require your help !!!
> Can anyone help and teach me how to access to the
> object contained within STL?
> My problem is If I have a class below:
> class Point {
> // Any constructor !!!
> //
> protected:
> int get_x(){return x;}
> int get_y(){return y;}
> int x, y;
> };
> Moreover I want to contain this class into
> list<queue<Point> > mylist;
> I want to insert the value of x and y into queue 4
> times and then push these values into list 1 times and
> then start again pushing the same 3 times Thus I can
> push 16 values of x and y into list<queue<Point> >.
> Unfortunately I don't know how to get or access to the
> member of class Point such as get_x(). And If I have
> an array of class Point such as mylist[10]. I want to
> know how to get the value of x and y by STL iterator
> by using its gramma or syntax.
> Thanks in advance,
> Ekkachart Hattha.
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Mail - Free email you can access from anywhere!

Boost list run by bdawes at, gregod at, cpdaniel at, john at