public static boolean hasWindowsDrive ( String path , boolean slashed ) { int start = slashed ? 1 : 0 ; return path . length ( ) >= start + 2 && ( ! slashed || path . charAt ( 0 ) == ' ' ) && path . charAt ( start + 1 ) == ' ' && ( ( path . charAt ( start ) >= ' ' && path . charAt ( start ) <= ' ' ) || ( path . charAt ( start ) >= ' ' && path . charAt ( start ) <= ' ' ) ) ; }
Checks if the path is a windows path . This should be platform independent .