Version | Date | Description |
---|---|---|
1.0.17 | 2019-08-03 | TBD |
1.0.16 | 2018-07-22 | grab-bag of additions |
1.0.15 | 2017-01-22 | A variety of new functions, across utils |
1.0.14 | 2014-01-21 | Multiple additions |
1.0.13 | 2013-08-29 | Collections, Serialization |
1.0.12 | 2013-06-30 | Introspection |
1.0.11 | 2013-06-15 | Lang, Collections |
1.0.10 | 2013-05-26 | Collections |
1.0.9 | 2013-04-07 | Collections, Lang |
1.0.8 | 2013-02-16 | Collections, IO, Utils |
1.0.7 | 2012-08-26 | Collections, IO |
1.0.6 | 2012-06-30 | Lang |
1.0.5 | 2012-05-17 | Beans, Collections, Threads |
1.0.4 | 2012-04-28 | Buffer, Lang, IO |
1.0.3 | 2012-04-22 | Collections |
1.0.2 | 2012-04-16 | Collections, Html, IO |
1.0.1 | 2011-12-29 | Collections, Html |
1.0.0 | 2011-08-27 | Initial public release |
Type | Changes | By |
---|---|---|
Counters: add toString() | kdgregory | |
JDBCUtil: add functions to support simple SQL operations | kdgregory | |
CollectionUtil.last(): optimization for linked lists | kdgregory | |
Counters: work-around signature change in ConcurrentHashMap (was producing an invalid artifact when compiling with JDK 8) | kdgregory | |
HashMultimap: Behavior enum was not public | kdgregory | |
SelfMock: retain invocation arguments | kdgregory |
Type | Changes | By |
---|---|---|
ClassUtil.getFieldValue(): retrieves a field's value from wherever it's defined in the class hierarchy | kdgregory | |
CollectionUtil.isEmpty(), isNotEmpty(): now accept Maps | kdgregory | |
CollectionUtil.partition(): breaks a passed collection into a list of max-size lists | kdgregory | |
CollectionUtil.submap(): extracts mappings for a set of keys. | kdgregory | |
NumericAsserts: add assertApproximate() for long and double values | kdgregory | |
NumericAsserts.assertInRange(): allows caller to assert that the actual value is within an arbitrary range +/- of the expected value | kdgregory | |
StringAsserts.assertNotEmpty() | kdgregory | |
SelfMock: a reflection-based mock object that invokes methods on itself; used to mock a portion of an interface without a long if-else chain in the invocation handler | kdgregory |
Type | Changes | By |
---|---|---|
BufferUtil.toArray: returns the entire contents of a ByteBuffer as an array | kdgregory | |
CollectionUtil.asMap(): produce a HashMap from a list of values | kdgregory | |
CollectionUtil.asSet(): be explicit that we return a HashSet | kdgregory | |
CollectionUtil.cast(): add variant for maps | kdgregory | |
CollectionUtil.getVia(): traverses hierarchies of maps, lists, and arrays | kdgregory | |
CollectionUtil.putIf(), putIfNotNull(): conditional stores for maps | kdgregory | |
ReadThroughCache: a size-limited LRU cache that uses a retriever function to load values | kdgregory | |
StringUtil.substr: flexible substring that's null-safe, bounds-safe, and allows selection of the right side of the string | kdgregory |
Type | Changes | By |
---|---|---|
ArrayAsserts: JUnit assertions for primitive arrays | kdgregory | |
Base64Codec: translates between byte[] and String using a Base-64 representation | kdgregory | |
HexCodec: translates between byte[] and String using a hex representation | kdgregory | |
CharSequenceUtil: utility methods common to all character sequences; initial methods are startsWith(), endsWith(), and containsAt() | kdgregory | |
CollectionUtil.compare(): compares the elements of two collections in iterator order | kdgregory | |
CollectionUtil.putIfAbsent(Map,Map): adds all mappings not present in base | kdgregory | |
Object.compare(): null-safe comparison, where null is optionally low or high when compared to not-null | kdgregory | |
StringUtil.valueOf(): a replacement for String.valueOf() that returns an empty string when passed null | kdgregory | |
Tuple2, ComparableTuple2: parameterized holder for a pair of values | kdgregory | |
UnclosingInputStream, UnclosingOutputStream: stream decorators that silently ignore close(); used to multiplex output onto a single stream | kdgregory | |
Base64Converter: deprecated in favor of Base64Codec | kdgregory |
Type | Changes | By |
---|---|---|
CollectionUtil: add first() and .last(): null-safe, empty-safe retrieval of first or last element of a list | kdgregory | |
Added equals() and hashCode() to DefaultMap, Hashmultimap | kdgregory | |
The following classes are now Serializable: CompoundKey, DefaultMap, HashMultimap, NameValue | kdgregory |
Type | Changes | By |
---|---|---|
CollectionUtil.addIfNotNull(): used to progressively build a collection where the source data may use null as a flag value | kdgregory | |
CollectionUtil.putIfAbsent(): a simple way to add default values to maps | kdgregory | |
StringUtil.length(): a null-safe length check (although StringUtil.isBlang()) is a better choice in most situations) | kdgregory | |
Introspection and IntrospectionCache now allow an optional setAccessible(true) on introspected methods | kdgregory |
Type | Changes | By |
---|---|---|
CollectionUtil.addIfNotNull(): used to progressively build a collection where the source data may use null as a flag value | kdgregory | |
CollectionUtil.filter(): the third common list-processing higher-order function | kdgregory | |
ObjectUtil.equals() variants that compare int and long with their object wrappers, to avoid null pointer exceptions from auto-unboxing | kdgregory |
Type | Changes | By |
---|---|---|
CollectionUtil.map() / reduce(): because every utilities library needs these | kdgregory | |
Counters: a threadsafe map of longs, used to summarize a stream of data | kdgregory |
Type | Changes | By |
---|---|---|
EnumerationIterable: allows old-style enumerations to be used in a for-each loop | kdgregory | |
IteratorIterable: allows arbitrary iterators to be used in a for-each loop | kdgregory | |
ClassUtil.getPrimitiveType(): returns the TYPE value for primitive wrapper instances | kdgregory | |
ClassUtil.getDeclaredMethodsByAccess(): slices and dices the result of Class.getDeclaredMethods() | kdgregory | |
ClassUtil.getVisibleMethods(), ClassUtil.getVisibleMethodMap(): returns all methods that a given class either declares or inherits from ancestors | kdgregory | |
ClassUtil.getBestMethod(): returns compiler's method selection rules to runtime arguments | kdgregory | |
StringUtil.trimToNull(): trim that produces a flag value on blank string | kdgregory | |
ClassUtil.getAnnotatedMethods(): now uses getVisibleMethods() | kdgregory | |
ClassUtil.getAllMethods(): deprecated in favor of getVisibleMethods() | kdgregory |
Type | Changes | By |
---|---|---|
SimpleCLIParser: processes an argument vector, extracting recognized options | kdgregory | |
CollectionUtil.addIf(): optionally adds an element to a collection | kdgregory | |
IOUtil.skipFully(): offers a higher level of skipping than InputStream.skip() | kdgregory | |
StringUtil.equalOrEmpty(): equality test where null is treated as an empty string | kdgregory |
Type | Changes | By |
---|---|---|
CollectionUtil.combine(): combines collections, returning result | kdgregory | |
CollectionUtil.isEmpty(), isNotEmpty(): null-safe tests for collection contents | kdgregory | |
CollectionUtil.defaultIfNull(): enables a null-safe for loop without explicit test/replace (applies to any iterable) | kdgregory | |
CollectionUtil.defaultIfEmpty(): used to eliminate "if for action else action" constructs | kdgregory | |
IOUtil.createTempFile(InputStream): now closes stream after copy | kdgregory | |
This library no longer establishes a transitive dependency on JUnit 3.8.x. If you use the assertion classes, you will need to provide your own JUnit dependency | kdgregory |
Type | Changes | By |
---|---|---|
ClassUtil.internalNameToExternal(): turns the type names from reflective signatures into actual classes | kdgregory | |
ObjectUtil.defaultValue(): replaces nulls with a default value, either literal or created from a factory | kdgregory | |
StringUtil.extractLeft(), extractRight(), extractLeftOfLast(), extractRightOfLast(): methods to partition a string around a delimiter | kdgregory | |
StringUtil.isIn(): tests a string against multiple candidates | kdgregory | |
StringBuilderUtil.appendUnless(): used to build up argument lists, where a comma goes before every element but the first | kdgregory |
Type | Changes | By |
---|---|---|
Introspection, IntrospectionCache: a replacement for the JDK's introspector; originally written for PracticalXml | kdgregory | |
MapBuilder: create and populate a Map in one expression | kdgregory | |
NamedThreadFactory: allows thread pools to name their threads | kdgregory | |
ThreadUtil.sleepQuietly(): catches and ignores InterruptedException | kdgregory |
Type | Changes | By |
---|---|---|
ClassUtil: utilities to muck with Class objects | kdgregory | |
IOUtil.readFully(): actually does what everyone things InputStream.read() does | kdgregory | |
UnreachableCodeException: a trap for branches that should never execute | kdgregory | |
ByteArray: String conversions now enforce 8-bit character limitation | kdgregory | |
ByteArray: fixed bug in remove() | kdgregory |
Type | Changes | By |
---|---|---|
CollectionUtil.filter(): produces one list from another by applying a regex | kdgregory |
Type | Changes | By |
---|---|---|
HtmlUtil.escape(): bugfix for escaped single quotes; add escaping of all non-ASCII characters | kdgregory | |
CollectionUtil.join(): turns a collection into a string, with separator | kdgregory | |
IOUtil.copy(): copies input stream to output stream; exists to eliminate dependencies | kdgregory | |
IOUtil.createTempFile(): variant that will fill file from InputStream | kdgregory |
Type | Changes | By |
---|---|---|
CombiningIterable: use a single loop to iterate multiple collections | kdgregory | |
HtmlUtil.escape(): bugfix for escaped single quotes; add escaping of all non-ASCII characters | kdgregory |
No changes in this release.