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

  • Reactive rest calls using spring rest template
  • setContentView (Activity)
  • addToBackStack (FragmentTransaction)
  • compareTo (BigDecimal)
  • InputStream (java.io)
    A readable source of bytes.Most clients will use input streams that read data from the file system (
  • Dictionary (java.util)
    Note: Do not use this class since it is obsolete. Please use the Map interface for new implementatio
  • Map (java.util)
    A Map is a data structure consisting of a set of keys and values in which each key is mapped to a si
  • TimerTask (java.util)
    The TimerTask class represents a task to run at a specified time. The task may be run once or repeat
  • BlockingQueue (java.util.concurrent)
    A java.util.Queue that additionally supports operations that wait for the queue to become non-empty
  • DateTimeFormat (org.joda.time.format)
    Factory that creates instances of DateTimeFormatter from patterns and styles. Datetime formatting i
  • 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