naaah...

interface MySuperDuperConstants {
  public static final char SLASHY_THINGY = File.separatorChar;
  public static final String SLASHY_STRINGY_THINGY = File.separator;
}

class MyExcellentApp implements MySuperDuperConstants {
  // TODO: make baby jesus cry ...
}

narf! ;-)

// Ben


2010/12/30 Cédric Beust ♔ <[email protected]>:
> Just because it works on all OS today doesn't mean it will always be the
> case.
> For example, just over the past few years, two operating systems have
> emerged with "novel" ways of viewing the file system (Android and iOS).
> I don't think hardcoding '/' instead of using File.separatorChar is worth
> the risk.
> --
> Cédric
>
> On Wed, Dec 29, 2010 at 9:30 AM, phil swenson <[email protected]>
> wrote:
>>
>> I find code that uses the "File.separator" field irritating.  It makes
>> the code uglier and best I can tell "/" works everywhere, including
>> windows.  Does anyone know if there is a reason to use File.separator
>> instead of just "/"?  My guess is unless you are writing java code
>> that writes to a .bat file or something along those lines, "/" is
>> fine.  Right?
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "The Java Posse" group.
>> To post to this group, send email to [email protected].
>> To unsubscribe from this group, send email to
>> [email protected].
>> For more options, visit this group at
>> http://groups.google.com/group/javaposse?hl=en.
>>
>
>
>
> --
> Cédric
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "The Java Posse" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/javaposse?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups "The 
Java Posse" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/javaposse?hl=en.

Reply via email to