Package org.jboss.as.jdr.util
Class Utils
- java.lang.Object
-
- org.jboss.as.jdr.util.Utils
-
public final class Utils extends Object
User: csams Date: 11/4/12 Time: 3:40 PM
-
-
Constructor Summary
Constructors Constructor Description Utils()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static booleanisSymlink(org.jboss.vfs.VirtualFile vFile)static booleanisWindows()static List<String>readLines(InputStream input)static voidsafeClose(JarFile jf)static voidsafelyClose(InputStream is)static voidskip(InputStream is, long amount)Ensure InputStream actually skips ahead the required number of bytesstatic byte[]toBytes(org.jboss.vfs.VirtualFile r)static StringtoString(org.jboss.vfs.VirtualFile r)
-
-
-
Field Detail
-
MANIFEST_NAME
public static final String MANIFEST_NAME
- See Also:
- Constant Field Values
-
LINE_SEP
public static final String LINE_SEP
-
WIN_SEP
public static final char WIN_SEP
- See Also:
- Constant Field Values
-
SYS_SEP
public static final char SYS_SEP
-
ONE_KB
public static final long ONE_KB
- See Also:
- Constant Field Values
-
ONE_MB
public static final long ONE_MB
- See Also:
- Constant Field Values
-
ONE_GB
public static final long ONE_GB
- See Also:
- Constant Field Values
-
ONE_TB
public static final long ONE_TB
- See Also:
- Constant Field Values
-
-
Method Detail
-
safeClose
public static void safeClose(JarFile jf)
-
safelyClose
public static void safelyClose(InputStream is)
-
readLines
public static List<String> readLines(InputStream input) throws IOException
- Throws:
IOException
-
toString
public static String toString(org.jboss.vfs.VirtualFile r) throws IOException
- Throws:
IOException
-
toBytes
public static byte[] toBytes(org.jboss.vfs.VirtualFile r) throws IOException- Throws:
IOException
-
skip
public static void skip(InputStream is, long amount) throws IOException
Ensure InputStream actually skips ahead the required number of bytes- Parameters:
is-amount-- Throws:
IOException
-
isSymlink
public static boolean isSymlink(org.jboss.vfs.VirtualFile vFile) throws IOException- Throws:
IOException
-
isWindows
public static boolean isWindows()
-
-