Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!news.swapon.de!fu-berlin.de!uni-berlin.de!news.dfncis.de!not-for-mail From: Joerg Meier Newsgroups: comp.lang.java.gui Subject: Re: Swing actions in separate code files - how Date: Tue, 22 Jul 2014 12:12:43 +0200 Lines: 28 Message-ID: References: <2qtju5F13feioU1@uni-berlin.de> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: news.dfncis.de YNG0jp/lFqMwouMJHLNxVA97oalFteKfCXzOBrg9FLCaKVNLZ4rJVvx4KY Cancel-Lock: sha1:kgXX7s9rTWaYsB8TdhSdqlHntOA= User-Agent: 40tude_Dialog/2.0.15.1 X-Antivirus: avast! (VPS 140722-0, 22.07.2014), Outbound message X-Antivirus-Status: Clean Xref: csiph.com comp.lang.java.gui:5443 On Mon, 21 Jul 2014 18:42:07 -0500, iMatt wrote: > I discovered a method which allows a central class to provide data > access to satellite classes. I needed a method to separate code into > several files, and this has proven effective. The satellite classes > have full data access to all but private variables, and can directly > change data in the central class. This concept has been tested > successfully on a large scale project. See what you think about it. That sounds like the well known god class anti-pattern, one of the most common programming mistakes. It makes testing hard, debugging harder and unit tests almost impossible. It is basically the opposite of any good OOP advice. > You should take a look at some Java code conventions (I recommend the Google ones now that the Oracle ones are 'deprecated'). Class names should start with upper case letters, variable names should be camel cased, and your use of spaces is mostly wrong, making your code hard to read for anyone who has programmed in Java before. Liebe Gruesse, Joerg -- Ich lese meine Emails nicht, replies to Email bleiben also leider ungelesen.