package at.yawk.numaec;
import org.eclipse.collections.api.block.function.primitive.CharFunction;
import org.eclipse.collections.api.block.function.primitive.ByteFunction;
import org.eclipse.collections.api.factory.map.primitive.MutableByteCharMapFactory;
import org.eclipse.collections.api.map.primitive.MutableByteCharMap;
import org.eclipse.collections.api.map.primitive.ByteCharMap;
public interface MutableByteCharBufferMapFactory extends MutableByteCharMapFactory {
@Override
MutableByteCharBufferMap empty();
@Override
default MutableByteCharBufferMap of() {
return empty();
}
@Override
default MutableByteCharBufferMap with() {
return empty();
}
@Override
MutableByteCharBufferMap ofInitialCapacity(int capacity);
@Override
default MutableByteCharBufferMap withInitialCapacity(int capacity) {
return ofInitialCapacity(capacity);
}
@Override
MutableByteCharBufferMap ofAll(ByteCharMap map);
@Override
default MutableByteCharBufferMap withAll(ByteCharMap map) {
return ofAll(map);
}
@Override
default <T> MutableByteCharMap from(
Iterable<T> iterable, ByteFunction<? super T> keyFunction, CharFunction<? super T> valueFunction
) {
MutableByteCharBufferMap n = empty();
for (T t : iterable) {
n.put(keyFunction.byteValueOf(t), valueFunction.charValueOf(t));
}
return n;
}
}