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

How to use
delete
method
in
net.sourceforge.squirrel_sql.fw.util.FileWrapper

Best Java code snippets using net.sourceforge.squirrel_sql.fw.util.FileWrapper.delete (Showing top 8 results out of 315)

origin: net.sf.squirrel-sql/squirrel-sql

/**
 * @see net.sourceforge.squirrel_sql.client.update.UpdateUtil#copyDir(
 * net.sourceforge.squirrel_sql.fw.util.FileWrapper,
 *      java.lang.String, boolean, net.sourceforge.squirrel_sql.fw.util.FileWrapper)
 */
@Override
public void moveFiles(FileWrapper fromDir, String filePattern, boolean matchPattern, FileWrapper toDir)
  throws FileNotFoundException, IOException
{
  if (StringUtils.isEmpty(filePattern)) {
    throw new IllegalArgumentException("filePattern arg cannot be empty or null");
  }
  if (!fromDir.isDirectory()) { throw new IllegalArgumentException("Expected fromDir("
    + fromDir.getAbsolutePath() + ") to be a directory."); }
  if (!toDir.isDirectory()) { throw new IllegalArgumentException("Expected toDir("
    + toDir.getAbsolutePath() + ") to be a directory."); }
  List<FileWrapper> filesToMove = getFilterFileList(fromDir, filePattern, matchPattern);
  for (FileWrapper file : filesToMove) {
    copyFile(file, toDir);
    if (s_log.isDebugEnabled()) {
      s_log.debug("moveFiles: Attempting to delete file "+file.getAbsolutePath());
    }
    if (file.delete()) {
      s_log.error("moveFiles: Unable to delete file "+file.getAbsolutePath());
    }
    
  }
}

origin: realXuJiang/bigtable-sql

newFile.delete();
origin: net.sf.squirrel-sql/squirrel-sql

newFile.delete();
origin: realXuJiang/bigtable-sql

/**
 * @see net.sourceforge.squirrel_sql.client.update.UpdateUtil#copyDir(
 * net.sourceforge.squirrel_sql.fw.util.FileWrapper,
 *      java.lang.String, boolean, net.sourceforge.squirrel_sql.fw.util.FileWrapper)
 */
@Override
public void moveFiles(FileWrapper fromDir, String filePattern, boolean matchPattern, FileWrapper toDir)
  throws FileNotFoundException, IOException
{
  if (StringUtils.isEmpty(filePattern)) {
    throw new IllegalArgumentException("filePattern arg cannot be empty or null");
  }
  if (!fromDir.isDirectory()) { throw new IllegalArgumentException("Expected fromDir("
    + fromDir.getAbsolutePath() + ") to be a directory."); }
  if (!toDir.isDirectory()) { throw new IllegalArgumentException("Expected toDir("
    + toDir.getAbsolutePath() + ") to be a directory."); }
  List<FileWrapper> filesToMove = getFilterFileList(fromDir, filePattern, matchPattern);
  for (FileWrapper file : filesToMove) {
    copyFile(file, toDir);
    if (s_log.isDebugEnabled()) {
      s_log.debug("moveFiles: Attempting to delete file "+file.getAbsolutePath());
    }
    if (file.delete()) {
      s_log.error("moveFiles: Unable to delete file "+file.getAbsolutePath());
    }
    
  }
}

origin: net.sf.squirrel-sql/squirrel-sql

result = path.delete();
if (s_log.isInfoEnabled())
result = result && path.delete();
origin: realXuJiang/bigtable-sql

result = path.delete();
if (s_log.isInfoEnabled())
result = result && path.delete();
origin: net.sf.squirrel-sql.plugins/dbdiff

/**
 * @see net.sourceforge.squirrel_sql.plugins.dbdiff.IScriptFileManager#cleanupScriptFiles()
 */
public void cleanupScriptFiles()
{
  for (final String scriptFile : scriptFiles)
  {
    final FileWrapper fileWrapper = fileWrapperFactory.create(scriptFile);
    if (fileWrapper.exists())
    {
      if (s_log.isDebugEnabled())
      {
        s_log.debug("Attempting to delete previously created temporary script file: " + scriptFile);
      }
      fileWrapper.delete();
    }
    else
    {
      if (s_log.isDebugEnabled())
      {
        s_log.debug("Previously created temporary script file did not exist: " + scriptFile);
      }
    }
  }
}
origin: net.sf.squirrel-sql.plugins/laf

if (!oldPrefsFile.delete())
net.sourceforge.squirrel_sql.fw.utilFileWrapperdelete

Popular methods of FileWrapper

  • exists
  • getAbsolutePath
  • getPath
  • getFileWriter
  • isFile
  • list
  • listFiles
  • mkdir
  • mkdirs
  • toURI
  • canRead
  • deleteOnExit
  • canRead,
  • deleteOnExit,
  • getFileInputStream,
  • getName,
  • isDirectory,
  • lastModified,
  • length,
  • createNewFile,
  • getBufferedReader

Popular in Java

  • Reactive rest calls using spring rest template
  • onCreateOptionsMenu (Activity)
  • getResourceAsStream (ClassLoader)
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • GridLayout (java.awt)
    The GridLayout class is a layout manager that lays out a container's components in a rectangular gri
  • Thread (java.lang)
    A thread is a thread of execution in a program. The Java Virtual Machine allows an application to ha
  • HttpURLConnection (java.net)
    An URLConnection for HTTP (RFC 2616 [http://tools.ietf.org/html/rfc2616]) used to send and receive d
  • List (java.util)
    An ordered collection (also known as a sequence). The user of this interface has precise control ove
  • 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
  • ConcurrentHashMap (java.util.concurrent)
    A plug-in replacement for JDK1.5 java.util.concurrent.ConcurrentHashMap. This version is based on or
  • Sublime Text for Python
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