congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
CndFileUtils.isSystemCaseSensitive
Code IndexAdd Tabnine to your IDE (free)

How to use
isSystemCaseSensitive
method
in
org.netbeans.modules.cnd.utils.cache.CndFileUtils

Best Java code snippets using org.netbeans.modules.cnd.utils.cache.CndFileUtils.isSystemCaseSensitive (Showing top 5 results out of 315)

origin: org.netbeans.modules/org-netbeans-modules-cnd-makeproject

public static Set<String> createExtensionSet() {
  if (CndFileUtils.isSystemCaseSensitive()) {
    return new TreeSet<>();
  } else {
    return new TreeSet<>(String.CASE_INSENSITIVE_ORDER);
  }
}
origin: org.netbeans.modules/org-netbeans-modules-cnd-utils

  protected boolean areFilenamesEqual(String firstFile, String secondFile) {
    return CndFileUtils.isSystemCaseSensitive() ? firstFile.equals(secondFile) : firstFile.equalsIgnoreCase(secondFile);
  }
}
origin: org.netbeans.modules/org-netbeans-modules-cnd-utils

public static boolean areFilenamesEqual(String firstFile, String secondFile) {
  return isSystemCaseSensitive() ? firstFile.equals(secondFile) : firstFile.equalsIgnoreCase(secondFile);
}
origin: org.netbeans.modules/org-netbeans-modules-cnd-utils

private static String changeStringCaseIfNeeded(FileSystem fs, String path) {
  if (isLocalFileSystem(fs)) {
    if (CndFileUtils.isSystemCaseSensitive()) {
      return path;
    } else {
      return path.toLowerCase();
    }
  } else {
    return path; // remote is always case sensitive
  }
}
origin: org.netbeans.modules/org-netbeans-modules-cnd-utils

/**
 * normalize LOCAL absolute paths
 * @param path
 * @return
 */
public static String normalizeAbsolutePath(String path) {
  CndUtils.assertAbsolutePathInConsole(path, "path for normalization must be absolute"); //NOI18N
  // TODO: this should be probably rewritten in a more elegant way
  if (path.startsWith("/") && Utilities.isWindows()) { // NOI18N
    return PathUtilities.normalizeUnixPath(path);
  }
  boolean caseSensitive = isSystemCaseSensitive();
  if (!caseSensitive) {
    if (Utilities.isWindows()) {
      path = path.replace('\\', '/');
    }
  }
  String normalized;
  // small optimization for true case sensitive OSs
  if (!caseSensitive || (path.endsWith("/.") || path.endsWith("\\.") || path.contains("..") || path.contains("./") || path.contains(".\\"))) { // NOI18N
    normalized = FileUtil.normalizeFile(new File(path)).getAbsolutePath();
  } else {
    normalized = path;
  }        
  return normalized;
}
org.netbeans.modules.cnd.utils.cacheCndFileUtilsisSystemCaseSensitive

Popular methods of CndFileUtils

  • isLocalFileSystem
  • normalizeAbsolutePath
  • toFileObject
  • getLocalFileSystem
  • createLocalFile
  • normalizeFile
    normalize file
  • fileObjectToUrl
  • getFileSeparatorChar
  • isExistingFile
    Tests whether the file exists and not directory. One of file or filePath must be not null
  • normalizePath
  • urlToFileObject
  • areFilenamesEqual
  • urlToFileObject,
  • areFilenamesEqual,
  • getCanonicalFileObject,
  • getCanonicalPath,
  • isExistingDirectory,
  • toFSPathList,
  • toFile,
  • changeStringCaseIfNeeded,
  • clearFileExistenceCache

Popular in Java

  • Parsing JSON documents to java classes using gson
  • getResourceAsStream (ClassLoader)
  • compareTo (BigDecimal)
  • scheduleAtFixedRate (ScheduledExecutorService)
  • Pointer (com.sun.jna)
    An abstraction for a native pointer data type. A Pointer instance represents, on the Java side, a na
  • Rectangle (java.awt)
    A Rectangle specifies an area in a coordinate space that is enclosed by the Rectangle object's top-
  • EOFException (java.io)
    Thrown when a program encounters the end of a file or stream during an input operation.
  • ByteBuffer (java.nio)
    A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate
  • Calendar (java.util)
    Calendar is an abstract base class for converting between a Date object and a set of integer fields
  • TimerTask (java.util)
    The TimerTask class represents a task to run at a specified time. The task may be run once or repeat
  • Top 17 PhpStorm Plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now