Class FileUtil

java.lang.Object
org.eclipse.nebula.widgets.xviewer.util.internal.FileUtil

public class FileUtil
extends java.lang.Object
  • Constructor Summary

    Constructors 
    Constructor Description
    FileUtil()  
  • Method Summary

    Modifier and Type Method Description
    static java.lang.String fileToString​(java.io.File file)  
    static java.lang.String justFilename​(java.lang.String filename)  
    static java.lang.String justPath​(java.lang.String filename)  
    static java.lang.String readFile​(java.io.File file)
    Use the Lib method directly - the original implementation of this method was not memory efficient and suppressed exceptions
    static java.lang.String readFile​(java.lang.String filename)
    Use the Lib method directly - the original implementation of this method was not memory efficient and suppressed exceptions
    static java.util.List<java.lang.String> readListFromDir​(java.io.File directory, java.io.FilenameFilter filter)  
    static void writeStringToFile​(java.lang.String str, java.io.File file)  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • justFilename

      public static java.lang.String justFilename​(java.lang.String filename)
    • justPath

      public static java.lang.String justPath​(java.lang.String filename)
    • readFile

      public static java.lang.String readFile​(java.lang.String filename) throws XViewerException
      Use the Lib method directly - the original implementation of this method was not memory efficient and suppressed exceptions
      Throws:
      java.io.IOException
      XViewerException
    • readFile

      public static java.lang.String readFile​(java.io.File file) throws XViewerException
      Use the Lib method directly - the original implementation of this method was not memory efficient and suppressed exceptions
      Throws:
      java.io.IOException
      XViewerException
    • fileToString

      public static java.lang.String fileToString​(java.io.File file) throws XViewerException
      Throws:
      XViewerException
    • writeStringToFile

      public static void writeStringToFile​(java.lang.String str, java.io.File file) throws java.io.IOException
      Throws:
      java.io.IOException
    • readListFromDir

      public static java.util.List<java.lang.String> readListFromDir​(java.io.File directory, java.io.FilenameFilter filter)