Path: csiph.com!x330-a1.tempe.blueboxinc.net!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!border3.nntp.dca.giganews.com!Xl.tags.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!local2.nntp.dca.giganews.com!nntp.earthlink.com!news.earthlink.com.POSTED!not-for-mail NNTP-Posting-Date: Sun, 23 Oct 2011 00:14:39 -0500 Date: Sun, 23 Oct 2011 06:14:48 +0100 From: Patricia Shanahan User-Agent: Thunderbird 1.5.0.2 (Windows/20060308) MIME-Version: 1.0 Newsgroups: comp.lang.java.programmer Subject: Re: Question regarding methods and classes References: <4ea389df$0$13444$9a566e8b@news.aliant.net> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Message-ID: Lines: 20 X-Usenet-Provider: http://www.giganews.com NNTP-Posting-Host: 83.244.254.166 X-Trace: sv3-GCQWOfzYRDM0DUBIjUgk6K4ac13itamR4cGGyBvns5ySQdjLBwQB8V8riMapIAW+SHbH/HdmCF640jx!dkC1bx4yr1DvUAe4vX0qQ/W59ewnaU2f/bhb05Z8Hp64Hj7FjjAaik0LjATg9cLoTTMV9HdUKesK!xWC4lFTfWpGWIybbskMKZxuFacSbbFj45FRl8lSPmDenZCw= X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.3.40 X-Original-Bytes: 1961 Xref: x330-a1.tempe.blueboxinc.net comp.lang.java.programmer:9104 Peter Duniho wrote: > On 10/22/11 8:28 PM, Linus Flustillbe wrote: >> [...] >> So basically what I want to do is create a whole bunch of methods, put >> them in one class and have them all available on demand just by >> importing the class...no instantiations required. >> Make sense? This is probably silly so if it is, just ignore me..I'll >> go away > > Not silly at all. If I understand your question correctly, you are > asking about "static" methods (not to be confused with "static nested > classes" :( ). That is, a method that can be called using the type > name, rather than an instance reference. ... Also, see the class java.lang.Math for an easily accessible example of this in practice. Patricia