Path: csiph.com!x330-a1.tempe.blueboxinc.net!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!nx02.iad01.newshosting.com!newshosting.com!69.16.185.16.MISMATCH!npeer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail From: Lew Newsgroups: comp.lang.java.programmer Subject: Re: A strange behaviour of a File property Date: Fri, 11 Nov 2011 14:17:26 -0800 (PST) Organization: http://groups.google.com Lines: 44 Message-ID: <13969500.491.1321049846293.JavaMail.geo-discussion-forums@prou19> References: <5980efbc-9010-4145-b886-fe106c5ac2d5@c18g2000yqj.googlegroups.com> <2735801.801.1321025690138.JavaMail.geo-discussion-forums@prdy11> Reply-To: comp.lang.java.programmer@googlegroups.com NNTP-Posting-Host: 2620:0:1000:2404:224:d7ff:fe69:5838 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: posting.google.com 1321049939 27809 127.0.0.1 (11 Nov 2011 22:18:59 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Fri, 11 Nov 2011 22:18:59 +0000 (UTC) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=2620:0:1000:2404:224:d7ff:fe69:5838; posting-account=CP-lKQoAAAAGtB5diOuGlDQk0jIwmH0T User-Agent: G2/1.0 X-Google-Web-Client: true Xref: x330-a1.tempe.blueboxinc.net comp.lang.java.programmer:9857 On Friday, November 11, 2011 9:28:59 AM UTC-8, ale...@inwind.it wrote: > > If you're asking the world of strangers to help, please do try to make it easy to read your code. > > > > Use spaces to indent, up to four per level. > > ok it'll be done, i'm sorry > > > > What are your outputs in the scenario that "works" (and what does "works" mean?) and in the scenario that doesn't? > > > the call to isDirectory() returns true only for the directories > present in the "." directory, for every other path it returns always > false, even when the file >is< a directory. I repeat: What *precisely* are the symptoms when it doesn't work, and what values other than "." have you tried? It's difficult to help when you're vague about the problem. What is "every other path"? What are the inputs and outputs that you see? The code you show doesn't show the scenario that fails. How can we tell what's failing when you don't show the code? The word "precisely" was emphasized for a reason. Your information is so vague, I don't even know what's going wrong much less why. Follow the advice in http://sscce.org/ Try to imagine that you are not at all familiar with your code, and read your explanation. Does it tell you enough to figure out what's wrong, let alone why? Where's the code? Where's the code? What are the outputs? You haven't shown any inputs, outputs or code for the failure case. Sorry, can't help you with such little data. -- Lew