X-Received: by 10.66.77.231 with SMTP id v7mr952748paw.35.1355952910991; Wed, 19 Dec 2012 13:35:10 -0800 (PST) Received: by 10.50.37.232 with SMTP id b8mr3098499igk.4.1355952910952; Wed, 19 Dec 2012 13:35:10 -0800 (PST) Path: csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!news.glorb.com!f6no2832789pbd.1!news-out.google.com!6ni51708pbd.1!nntp.google.com!f6no2832778pbd.1!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.java.programmer Date: Wed, 19 Dec 2012 13:35:10 -0800 (PST) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=69.28.149.29; posting-account=CP-lKQoAAAAGtB5diOuGlDQk0jIwmH0T NNTP-Posting-Host: 69.28.149.29 References: <20fa5c05-6fcc-47ed-9e80-a44975887928@googlegroups.com> <50cfcd0b$0$293$14726298@news.sunsite.dk> <50cfd4b9$0$295$14726298@news.sunsite.dk> <50d1144b$0$290$14726298@news.sunsite.dk> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <3653fada-0e69-4e98-afdc-8cc2b7b25602@googlegroups.com> Subject: Re: proper use of .java files (layout) From: Lew Injection-Date: Wed, 19 Dec 2012 21:35:10 +0000 Content-Type: text/plain; charset=ISO-8859-1 Xref: csiph.com comp.lang.java.programmer:20595 lipska the kat wrote: > I can't think of a card game that does not use PlayingCards of one sort By definition. Hardly a ground-shaking point. > or another. One might argue that Tarot is not a game yet uses Cards. Tarot is not a game because it's the name of the deck. There are games that use Tarot cards, and many decks that are based more directly on Tarot than the French deck that seems to be your imprinted standard. > This might mean that PlayingCard is unsuitable, so we fall back to Card Whatever. What do you do with Tarot cards that is not a game, hm? > with PlayingCard a possible later specialization. > If the base abstraction is not Card then what else might describe what a > Card is better than 'Card' Do you have a point here? Why do you refer to "the" base abstraction? The "base abstraction" of what? There are several such in a card-game simulation. The "base abstraction" of a playing card is the abstract notion of a playing card, as you say. So? Once you break out of tautologies you can find the entrance to design. The key in O-O is not finding one "base abstraction" (BTW, what exactly do you mean by that phrase?) but a cooperating set of them, and identifying the interactions. So to model a card game, you need several types in the model. One approach will comprise 'PlayingCard', 'Rule', 'CardGame', 'Deck', 'Shoe' and other semantic features. It is the interaction of these that makes up a model. -- Lew