Index

A C D E F G H I L M N O R S T U V 
All Classes and Interfaces|All Packages|Constant Field Values

A

asDuration(String) - Static method in class io.github.amanzat.util.DateTimeUtils
Parses the specified string value to a Duration if possible, otherwise returns null.

C

chunkify(Iterator<T>, int) - Static method in class io.github.amanzat.util.CollectionUtils
Transforms an iterator into a stream of lists with a maximum size.
CollectionUtils - Class in io.github.amanzat.util
Miscellaneous collections related utilities.
CollectionUtils() - Constructor for class io.github.amanzat.util.CollectionUtils
 
ComparableUtils - Class in io.github.amanzat.util
Miscellaneous comparable utility methods.
ComparableUtils() - Constructor for class io.github.amanzat.util.ComparableUtils
 
concat(char, String...) - Static method in class io.github.amanzat.util.StringUtils
Concatenates an array of strings using a delimiter and returns the resulting string.
concat(String, char, String...) - Static method in class io.github.amanzat.util.StringUtils
Concatenates a string with an array of strings using a delimiter and returns the resulting string.
concat(String, String) - Method in enum class io.github.amanzat.util.StringUtils.Padding
Concatenates the str with the specified pad string.
concat(String, String...) - Static method in class io.github.amanzat.util.StringUtils
Concatenates a string with an array of strings and returns the resulting array.
copy(InputStream, OutputStream) - Static method in class io.github.amanzat.util.IOUtils
Copies bytes a InputStream to an OutputStream.
copy(InputStream, OutputStream, byte[]) - Static method in class io.github.amanzat.util.IOUtils
Copies bytes from a InputStream to an OutputStream.
copy(InputStream, OutputStream, int) - Static method in class io.github.amanzat.util.IOUtils
Copies bytes from an InputStream to an OutputStream using an internal buffer of the given size.

D

DateTimeUtils - Class in io.github.amanzat.util
Miscellaneous date and time utility methods and constants.
DateTimeUtils() - Constructor for class io.github.amanzat.util.DateTimeUtils
 
DEFAULT_BUFFER_SIZE - Static variable in class io.github.amanzat.util.IOUtils
The default buffer size (8192) to use in copy methods.
deleteFile(String) - Static method in class io.github.amanzat.util.FileUtils
Deletes the file at the specified path if exists.

E

EMPTY_STRING - Static variable in class io.github.amanzat.util.StringUtils
The empty String constant.
ensureDirectoryExists(String) - Static method in class io.github.amanzat.util.FileUtils
Ensures that the directory at the specified path exists.
EOF - Static variable in class io.github.amanzat.util.IOUtils
Represents the end-of-file (or stream).
ExceptionUtils - Class in io.github.amanzat.util
Miscellaneous Throwable utility methods and constants.
ExceptionUtils() - Constructor for class io.github.amanzat.util.ExceptionUtils
 

F

FileUtils - Class in io.github.amanzat.util
Miscellaneous file related utilities.
FileUtils() - Constructor for class io.github.amanzat.util.FileUtils
 
formatDurationHMS(long) - Static method in class io.github.amanzat.util.DateTimeUtils
Formats the time duration in millis using the HH:mm:ss.SSS format.

G

getCause(Throwable) - Static method in class io.github.amanzat.util.ExceptionUtils
Returns the cause of this throwable if exists and is not the same instance with the throwable.
getFileName(String) - Static method in class io.github.amanzat.util.FileUtils
Returns the file name from the specified path by eliminating the directories or null if the path is null.
getFirst(List<E>) - Static method in class io.github.amanzat.util.CollectionUtils
Returns an optional containing the first element of the list if any.

H

HOUR_MILLIS - Static variable in class io.github.amanzat.util.DateTimeUtils
The number of milliseconds in an hour.

I

indexOfLastDirectorySeparator(String) - Static method in class io.github.amanzat.util.FileUtils
Returns the index of the last directory separator character of the path or -1 if there is no such character.
io.github.amanzat.util - package io.github.amanzat.util
 
IOUtils - Class in io.github.amanzat.util
Miscellaneous I/O streams related utilities.
IOUtils() - Constructor for class io.github.amanzat.util.IOUtils
 
isBlank(CharSequence) - Static method in class io.github.amanzat.util.StringUtils
Checks if a CharSequence is empty, null or whitespace only.
isEmpty(CharSequence) - Static method in class io.github.amanzat.util.StringUtils
Returns true if the CharSequence is null or empty, false otherwise.
isEmpty(Collection<?>) - Static method in class io.github.amanzat.util.CollectionUtils
Returns true if the specified collection is empty, false otherwise.

L

LEFT - Enum constant in enum class io.github.amanzat.util.StringUtils.Padding
The left padding enum.
leftPad(String, int, char) - Static method in class io.github.amanzat.util.StringUtils
Left pads the specified string input with the given character.
length(CharSequence) - Static method in class io.github.amanzat.util.StringUtils
Returns the length of the CharSequence or 0 if the value is null.
log(Logger, Level, String, Object...) - Static method in class io.github.amanzat.util.Slf4jUtils
Simple logging based on the specified parameters.

M

MINUTE_MILLIS - Static variable in class io.github.amanzat.util.DateTimeUtils
The number of milliseconds in a minute.

N

NEW_LINE - Static variable in class io.github.amanzat.util.StringUtils
The new line String.
NumberUtils - Class in io.github.amanzat.util
Miscellaneous Number utility methods and constants.
NumberUtils() - Constructor for class io.github.amanzat.util.NumberUtils
 

O

ObjectUtils - Class in io.github.amanzat.util
Miscellaneous Object utility methods.
ObjectUtils() - Constructor for class io.github.amanzat.util.ObjectUtils
 
onlyDigits(CharSequence, int) - Static method in class io.github.amanzat.util.StringUtils
Checks if the specified CharSequence has only digits and the specified length.

R

readAllLines(String) - Static method in class io.github.amanzat.util.FileUtils
Reads all lines from the file at the given file path.
RIGHT - Enum constant in enum class io.github.amanzat.util.StringUtils.Padding
The right padding enum.
rightPad(String, int, char) - Static method in class io.github.amanzat.util.StringUtils
Right pads the specified string input with the given character.

S

safeAcquire(Semaphore) - Static method in class io.github.amanzat.util.ThreadUtils
Safely acquires a semaphore permit.
safeAwait(CountDownLatch) - Static method in class io.github.amanzat.util.ThreadUtils
Safely waits for the latch to count down to zero.
safeCompare(T, T) - Static method in class io.github.amanzat.util.ComparableUtils
Does a safe comparison of two Comparable objects accounting for nulls.
safeParseDecimal(String) - Static method in class io.github.amanzat.util.NumberUtils
Safely parses the specified string value to a BigDecimal ignoring nulls and blank strings.
safeSleep(long) - Static method in class io.github.amanzat.util.ThreadUtils
Safely sleeps the current thread for the specified number of millis.
SECOND_MILLIS - Static variable in class io.github.amanzat.util.DateTimeUtils
The number of milliseconds in a second.
Slf4jUtils - Class in io.github.amanzat.util
Miscellaneous utility methods for Slf4J.
Slf4jUtils() - Constructor for class io.github.amanzat.util.Slf4jUtils
 
StringUtils - Class in io.github.amanzat.util
Miscellaneous String utility methods and constants.
StringUtils() - Constructor for class io.github.amanzat.util.StringUtils
 
StringUtils.Padding - Enum Class in io.github.amanzat.util
Defines the padding types.

T

ThreadUtils - Class in io.github.amanzat.util
Miscellaneous Thread utility methods.
ThreadUtils() - Constructor for class io.github.amanzat.util.ThreadUtils
 
throwableOfType(Throwable, Class<T>) - Static method in class io.github.amanzat.util.ExceptionUtils
Returns the first throwable of the specified type in the exception chain if exists, null otherwise.
toInputStream(String, Charset) - Static method in class io.github.amanzat.util.IOUtils
Converts the specified string to an input stream, encoded as bytes using the specified character encoding.
toLowerCase(String) - Static method in class io.github.amanzat.util.StringUtils
Safely converts the specified value to lower-case handling nulls.
toUpperCase(String) - Static method in class io.github.amanzat.util.StringUtils
Safely converts the specified value to upper-case handling nulls.
truncateWithMarker(String, int) - Static method in class io.github.amanzat.util.StringUtils
Truncates the specified String value to the maximum length and add the truncation marker if the max length is greater than the marker's length.
TRUNCATION_MARKER - Static variable in class io.github.amanzat.util.StringUtils
The truncation marker String.

U

uncheckedCast(Object) - Static method in class io.github.amanzat.util.ObjectUtils
Performs an unchecked cast for the specified object.
UNIX_SEPARATOR - Static variable in class io.github.amanzat.util.FileUtils
The Unix path separator.

V

valueOf(String) - Static method in enum class io.github.amanzat.util.StringUtils.Padding
Returns the enum constant of this class with the specified name.
values() - Static method in enum class io.github.amanzat.util.StringUtils.Padding
Returns an array containing the constants of this enum class, in the order they are declared.
A C D E F G H I L M N O R S T U V 
All Classes and Interfaces|All Packages|Constant Field Values