org.sakaiproject.search.util
Class FileUtils

java.lang.Object
  extended by org.sakaiproject.search.util.FileUtils

public class FileUtils
extends Object

Author:
ieb

Nested Class Summary
static interface FileUtils.RecurseAction
           
 
Constructor Summary
FileUtils()
           
 
Method Summary
static void createMarkerFile(File file)
           
static void deleteAll(File f)
          delete all files under this file and including this file
static String digest(String token)
           
static void listDirectory(File f)
           
static void pack(File source, String basePath, String replacePath, OutputStream output, boolean compress)
          pack a segment into the zip
static void recurse(File f, FileUtils.RecurseAction action)
           
static void recurseGrouped(File f, FileUtils.RecurseAction action)
           
static void unpack(InputStream source, File destination)
          unpack a segment from a zip
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FileUtils

public FileUtils()
Method Detail

deleteAll

public static void deleteAll(File f)
                      throws IOException
delete all files under this file and including this file

Parameters:
f -
Throws:
IOException

recurse

public static void recurse(File f,
                           FileUtils.RecurseAction action)
                    throws IOException
Throws:
IOException

recurseGrouped

public static void recurseGrouped(File f,
                                  FileUtils.RecurseAction action)
                           throws IOException
Throws:
IOException

pack

public static void pack(File source,
                        String basePath,
                        String replacePath,
                        OutputStream output,
                        boolean compress)
                 throws IOException
pack a segment into the zip

Parameters:
compress -
addsi -
Throws:
IOException

unpack

public static void unpack(InputStream source,
                          File destination)
                   throws IOException
unpack a segment from a zip

Parameters:
addsi -
packetStream -
version -
Throws:
IOException

digest

public static String digest(String token)
                     throws GeneralSecurityException,
                            IOException
Throws:
GeneralSecurityException
IOException

listDirectory

public static void listDirectory(File f)
                          throws IOException
Parameters:
parentFile -
Throws:
IOException

createMarkerFile

public static void createMarkerFile(File file)
                             throws IOException
Parameters:
file -
Throws:
IOException


Copyright © 2003-2012 Sakai Project. All Rights Reserved.