Remco Bos

Greenhorn
+ Follow
since Feb 14, 2005
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Remco Bos

AOP

i.e. in many cases SOA can be accomplished with more restrictive but efficient interfacing technologies


Yes it's off topic, but maybe we can start another thread for this one because I really want to hear your opinion about those "more restrictive but efficient interfacing technologies". I also believe that's the way to go..
P.374
The main problem the folowing statement in the next() method of the CompositeIterator class:

The createIterator() returns a new CompositeIterator, and so a new Stack!

How I solved it:

1. The Menu should return just an iterator, not an CompositeIterator



2. Let the Waitress instantiate the CompositeIterator instead of asking the Menu for one.



3. The Menu should not iterate over it's children, we use an external CompositeIterator for that!



4. The root (allMenus) is not returned by the iterator. This is because we ask the allMenus for an iterator for it's children, not for the Menu itself!

5. The printMenu() method in the Waitress should also use the CompositeIterator.



Took me some time to figure this out, maybe I'm totally wrong, please test!!

[ March 30, 2006: Message edited by: Remco Bos ]

[ March 30, 2006: Message edited by: Remco Bos ]
[ March 30, 2006: Message edited by: Remco Bos ]
I was also thinking about using a similar design. It looks very elegant. But now I look at the remote/local database part of the assignment: I wonder if I should implement the DB interface on the local and remote stub, or create a DAO interface and let the remote/local stub implement that interface.Any ideas?