public static <T> Collector<T, AtomicReference<T>, T> uniqueNullable() {
        return Collector.of(
                AtomicReference::new,
                CollectorUtils::uniqueAccumulate,
                CollectorUtils::uniqueCombine,
                AtomicReference::get
        );
    }
public static < T > Collector < T , AtomicReference < T > , T > uniqueNullable ( ) { return Collector . of ( AtomicReference :: new , CollectorUtils :: uniqueAccumulate , CollectorUtils :: uniqueCombine , AtomicReference :: get ) ; }
A collector that returns the single member of a stream (or null if not present), or throws a
{@link com.codepoetics.protonpack.collectors.NonUniqueValueException} if more
than one item is found.
@param <T> The type of the items in the stream.
@return The collector.