| java.lang.Object org.eclipse.jdt.internal.compiler.util.Util
Inner Class :public interface Displayable | |
Method Summary | |
public static char[] | bytesToChar(byte[] bytes, String encoding) Returns the given bytes as a char array using a given encoding (null means platform default). | public static byte[] | getFileByteContent(File file) Returns the contents of the given file as a byte array. | public static char[] | getFileCharContent(File file, String encoding) Returns the contents of the given file as a char array. | public static byte[] | getInputStreamAsByteArray(InputStream stream, int length) Returns the given input stream's contents as a byte array.
If a length is specified (ie. | public static char[] | getInputStreamAsCharArray(InputStream stream, int length, String encoding) Returns the given input stream's contents as a character array.
If a length is specified (ie. | public static int | getLineNumber(int position, int[] lineEnds, int g, int d) | public static byte[] | getZipEntryByteContent(ZipEntry ze, ZipFile zip) Returns the contents of the given zip entry as a byte array. | final public static boolean | isArchiveFileName(String name) Returns true iff str.toLowerCase().endsWith(".jar") || str.toLowerCase().endsWith(".zip")
implementation is not creating extra strings. | final public static boolean | isClassFileName(char[] name) Returns true iff str.toLowerCase().endsWith(".class")
implementation is not creating extra strings. | final public static boolean | isClassFileName(String name) Returns true iff str.toLowerCase().endsWith(".class")
implementation is not creating extra strings. | final public static boolean | isExcluded(char[] path, char[][] inclusionPatterns, char[][] exclusionPatterns, boolean isFolderPath) | final public static boolean | isJavaFileName(char[] name) Returns true iff str.toLowerCase().endsWith(".java")
implementation is not creating extra strings. | final public static boolean | isJavaFileName(String name) Returns true iff str.toLowerCase().endsWith(".java")
implementation is not creating extra strings. | public static void | reverseQuickSort(char[][] list, int left, int right, int[] result) | public static void | reverseQuickSort(char[][] list, int left, int right) | final public static int | searchColumnNumber(int[] startLineIndexes, int lineNumber, int position) | public static Boolean | toBoolean(boolean bool) Converts a boolean value into Boolean. | public static String | toString(Object[] objects) Converts an array of Objects into String. | public static String | toString(Object[] objects, Displayable renderer) Converts an array of Objects into String. |
EMPTY_INT_ARRAY | final public static int[] EMPTY_INT_ARRAY(Code) | | |
LINE_SEPARATOR | final public static String LINE_SEPARATOR(Code) | | |
bytesToChar | public static char[] bytesToChar(byte[] bytes, String encoding) throws IOException(Code) | | Returns the given bytes as a char array using a given encoding (null means platform default).
|
getFileByteContent | public static byte[] getFileByteContent(File file) throws IOException(Code) | | Returns the contents of the given file as a byte array.
throws: IOException - if a problem occured reading the file. |
getFileCharContent | public static char[] getFileCharContent(File file, String encoding) throws IOException(Code) | | Returns the contents of the given file as a char array.
When encoding is null, then the platform default one is used
throws: IOException - if a problem occured reading the file. |
getInputStreamAsByteArray | public static byte[] getInputStreamAsByteArray(InputStream stream, int length) throws IOException(Code) | | Returns the given input stream's contents as a byte array.
If a length is specified (ie. if length != -1), only length bytes
are returned. Otherwise all bytes in the stream are returned.
Note this doesn't close the stream.
throws: IOException - if a problem occured reading the stream. |
getInputStreamAsCharArray | public static char[] getInputStreamAsCharArray(InputStream stream, int length, String encoding) throws IOException(Code) | | Returns the given input stream's contents as a character array.
If a length is specified (ie. if length != -1), this represents the number of bytes in the stream.
Note this doesn't close the stream.
throws: IOException - if a problem occured reading the stream. |
getLineNumber | public static int getLineNumber(int position, int[] lineEnds, int g, int d)(Code) | | |
getZipEntryByteContent | public static byte[] getZipEntryByteContent(ZipEntry ze, ZipFile zip) throws IOException(Code) | | Returns the contents of the given zip entry as a byte array.
throws: IOException - if a problem occured reading the zip entry. |
isArchiveFileName | final public static boolean isArchiveFileName(String name)(Code) | | Returns true iff str.toLowerCase().endsWith(".jar") || str.toLowerCase().endsWith(".zip")
implementation is not creating extra strings.
|
isClassFileName | final public static boolean isClassFileName(char[] name)(Code) | | Returns true iff str.toLowerCase().endsWith(".class")
implementation is not creating extra strings.
|
isClassFileName | final public static boolean isClassFileName(String name)(Code) | | Returns true iff str.toLowerCase().endsWith(".class")
implementation is not creating extra strings.
|
isExcluded | final public static boolean isExcluded(char[] path, char[][] inclusionPatterns, char[][] exclusionPatterns, boolean isFolderPath)(Code) | | |
isJavaFileName | final public static boolean isJavaFileName(char[] name)(Code) | | Returns true iff str.toLowerCase().endsWith(".java")
implementation is not creating extra strings.
|
isJavaFileName | final public static boolean isJavaFileName(String name)(Code) | | Returns true iff str.toLowerCase().endsWith(".java")
implementation is not creating extra strings.
|
reverseQuickSort | public static void reverseQuickSort(char[][] list, int left, int right, int[] result)(Code) | | |
reverseQuickSort | public static void reverseQuickSort(char[][] list, int left, int right)(Code) | | |
searchColumnNumber | final public static int searchColumnNumber(int[] startLineIndexes, int lineNumber, int position)(Code) | | INTERNAL USE-ONLY
Search the column number corresponding to a specific position
|
toBoolean | public static Boolean toBoolean(boolean bool)(Code) | | Converts a boolean value into Boolean.
Parameters: bool - The boolean to convert The corresponding Boolean object (TRUE or FALSE). |
toString | public static String toString(Object[] objects)(Code) | | Converts an array of Objects into String.
|
toString | public static String toString(Object[] objects, Displayable renderer)(Code) | | Converts an array of Objects into String.
|
|
|