Class Util
java.lang.Object
edu.umd.cs.findbugs.util.Util
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescription(package private) static final float(package private) static Collection<Runnable> (package private) static final Pattern -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic <K> List<K> static <K> Set<K> static voidcloseSilently(Closeable out) Deprecated.Use try-with-resources instead.static voidstatic voidDeprecated.Use try-with-resources instead.static voidcloseSilently(Reader in) Deprecated.Use try-with-resources instead.static voidcloseSilently(ZipFile zip) Deprecated.Use try-with-resources instead.static <T> Set<T> static <E> Estatic Stringprivate static StringgetFileExtension(String name) static Stringstatic ReadergetFileReader(File filename) static ReadergetFileReader(String filename) static WritergetFileWriter(String filename) static MessageDigeststatic ReadergetReader(InputStream in) static WritergetWriter(OutputStream out) static Stringstatic <K,V> Map <K, V> immutableMap(Map<K, V> map) static booleanisPowerOfTwo(int i) static <K> ArrayList<K> makeSmallArrayList(List<K> m) static <K,V> HashMap <K, V> makeSmallHashMap(Map<K, V> m) static <K> HashSet<K> makeSmallHashSet(Collection<K> m) static Stringstatic Threadstatic ThreadrunInDameonThread(Runnable r, String name) static voidstatic Thread
-
Field Details
-
runAtShutdown
-
tag
-
DEFAULT_LOAD_FACTOR
static final float DEFAULT_LOAD_FACTOR- See Also:
-
-
Constructor Details
-
Util
public Util()
-
-
Method Details
-
startDameonThread
-
runInDameonThread
-
runInDameonThread
-
repeat
-
runLogAtShutdown
-
emptyOrNonnullSingleton
-
immutableMap
-
getReader
-
getFileReader
- Throws:
IOException
-
getFileReader
- Throws:
IOException
-
getWriter
-
getFileWriter
- Throws:
IOException
-
closeSilently
-
closeSilently
Deprecated.Use try-with-resources instead. -
closeSilently
Deprecated.Use try-with-resources instead. And basicallyIOExceptionfromOutputStream.close()is not good to ignore. -
closeSilently
Deprecated.Use try-with-resources instead. And basicallyIOExceptionfromOutputStream.close()is not good to ignore. -
closeSilently
Deprecated.Use try-with-resources instead. -
getXMLType
- Throws:
IOException
-
getFileExtension
-
getFileExtension
-
getFileExtensionIgnoringGz
-
first
- Parameters:
i- the Iterable whose first element is to be retrieved- Returns:
- first element of iterable
-
makeSmallHashMap
-
makeSmallHashSet
-
makeSmallArrayList
-
addTo
-
addTo
-
getMD5Digest
-
isPowerOfTwo
public static boolean isPowerOfTwo(int i)
-