X-FeedAbuse: http://nntpfeed.proxad.net/abuse.pl feeded by 88.191.16.109 Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!news.dougwise.org!nntpfeed.proxad.net!nospam.fr.eu.org!usenet-fr.net!de-l.enfer-du-nord.net!feeder2.enfer-du-nord.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!news.wiretrip.org!feeder3.cambriumusenet.nl!feed.tweaknews.nl!209.197.12.242.MISMATCH!nx01.iad01.newshosting.com!newshosting.com!69.16.185.11.MISMATCH!npeer01.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!spln!extra.newsguy.com!newsp.newsguy.com!news2 From: Michael Wojcik Newsgroups: comp.lang.java.programmer Subject: Re: CLI Java Glitch Date: Thu, 23 Jun 2011 12:24:06 -0400 Organization: Micro Focus Lines: 39 Message-ID: References: <4dffe2ea$0$57121$c30e37c6@exi-reader.telstra.net> NNTP-Posting-Host: pf2629609bfb4a122e9be4fcf1bfd6714bba2e39d9d4344cf.newsdawg.com Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.8.1.23) Gecko/20090812 Thunderbird/2.0.0.23 Mnenhy/0.7.5.0 In-Reply-To: Xref: x330-a1.tempe.blueboxinc.net comp.lang.java.programmer:5587 Peter Duniho wrote: > For better or worse, Java _is_ case-sensitive, which means > that it definitely should be just as illegal for the user to specify > "helloworld" as the class name when starting the program as it is for > the programmer to specify "helloworld" as the class name when referring > to it from code. Agreed. And "case-insensitive" becomes problematic when you move outside European alphabets, which is another argument against it. (If I name a class using Japanese katakana characters, should I be able to invoke it using the corresponding hiragana characters? That would seem pretty silly - but where do we draw the line?) > If Java is deficient in any way here, I'd say it's the inability to > specify the .class file name separately from the name of the class > itself, specifically because of the potential for this mis-match of > casing rules. But even that seems a stretch to me, especially since > offering that option could encourage people naming their .class files > something completely different than the class contained within > (something I'd rather not see as a general practice :) ). And in effect we already have this with JARs and other cases where the class isn't loaded from a .class file in the local filesystem. There's no need for a .jar file to have a name that corresponds to the main class (and it typically won't). The same applies if I'm using a class loader that fetches the class from a network resource, or out of a database, or whatever. "java foo", without other options, is a special case of invoking the JVM and asking it to load a class and invoke its "main" method: it's the case where that class happens to reside in a .class file with the same name as the class. The "foo" argument is the name of the class, and the "java" executable is inferring the file name from it. Not the other way around. -- Michael Wojcik Micro Focus Rhetoric & Writing, Michigan State University