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

How to use
traverse
method
in
aQute.bnd.osgi.FileResource

Best Java code snippets using aQute.bnd.osgi.FileResource.traverse (Showing top 6 results out of 315)

origin: biz.aQute/bndlib

public static void build(Jar jar, File directory, Pattern doNotCopy) {
  traverse(jar, directory.getAbsolutePath().length(), directory, doNotCopy);
}
origin: biz.aQute.bnd/bndlib

public static void build(Jar jar, File directory, Pattern doNotCopy) {
  traverse(jar, directory.getAbsolutePath().length(), directory, doNotCopy);
}
origin: biz.aQute.bnd/bnd

public static void build(Jar jar, File directory, Pattern doNotCopy) {
  traverse(jar, directory.getAbsolutePath().length(), directory, doNotCopy);
}
origin: biz.aQute/bndlib

static void traverse(Jar jar, int rootlength, File directory, Pattern doNotCopy) {
  if (doNotCopy != null && doNotCopy.matcher(directory.getName()).matches())
    return;
  jar.updateModified(directory.lastModified(), "Dir change");
  File files[] = directory.listFiles();
  for (int i = 0; i < files.length; i++) {
    if (files[i].isDirectory())
      traverse(jar, rootlength, files[i], doNotCopy);
    else {
      String path = files[i].getAbsolutePath().substring(rootlength + 1);
      if (File.separatorChar != '/')
        path = path.replace(File.separatorChar, '/');
      jar.putResource(path, new FileResource(files[i]), true);
    }
  }
}
origin: biz.aQute.bnd/bndlib

static void traverse(Jar jar, int rootlength, File directory, Pattern doNotCopy) {
  if (doNotCopy != null && doNotCopy.matcher(directory.getName()).matches())
    return;
  jar.updateModified(directory.lastModified(), "Dir change " + directory);
  File files[] = directory.listFiles();
  for (int i = 0; i < files.length; i++) {
    if (files[i].isDirectory())
      traverse(jar, rootlength, files[i], doNotCopy);
    else {
      String path = files[i].getAbsolutePath().substring(rootlength + 1);
      if (File.separatorChar != '/')
        path = path.replace(File.separatorChar, '/');
      jar.putResource(path, new FileResource(files[i]), true);
    }
  }
}
origin: biz.aQute.bnd/bnd

static void traverse(Jar jar, int rootlength, File directory, Pattern doNotCopy) {
  if (doNotCopy != null && doNotCopy.matcher(directory.getName()).matches())
    return;
  jar.updateModified(directory.lastModified(), "Dir change " + directory);
  File files[] = directory.listFiles();
  for (int i = 0; i < files.length; i++) {
    if (files[i].isDirectory())
      traverse(jar, rootlength, files[i], doNotCopy);
    else {
      String path = files[i].getAbsolutePath().substring(rootlength + 1);
      if (File.separatorChar != '/')
        path = path.replace(File.separatorChar, '/');
      jar.putResource(path, new FileResource(files[i]), true);
    }
  }
}
aQute.bnd.osgiFileResourcetraverse

Popular methods of FileResource

  • <init>
  • deleteOnClose
  • build
  • copy
  • buffer
  • getFile

Popular in Java

  • Making http requests using okhttp
  • addToBackStack (FragmentTransaction)
  • getSystemService (Context)
  • getSupportFragmentManager (FragmentActivity)
  • BufferedWriter (java.io)
    Wraps an existing Writer and buffers the output. Expensive interaction with the underlying reader is
  • Runnable (java.lang)
    Represents a command that can be executed. Often used to run code in a different Thread.
  • URLConnection (java.net)
    A connection to a URL for reading or writing. For HTTP connections, see HttpURLConnection for docume
  • StringTokenizer (java.util)
    Breaks a string into tokens; new code should probably use String#split.> // Legacy code: StringTo
  • Cipher (javax.crypto)
    This class provides access to implementations of cryptographic ciphers for encryption and decryption
  • Scheduler (org.quartz)
    This is the main interface of a Quartz Scheduler. A Scheduler maintains a registry of org.quartz.Job
  • 14 Best Plugins for Eclipse
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