/ 

at.yawk.numaec/ numa-eclipse-collections/ 0.2/ at/yawk/numaec/MutableShortIntBTreeMapFactory.java

 

  • class final publicMutableShortIntBTreeMapFactory
    • field final privateallocator: LargeByteBufferAllocator
    • field final privateconfig: BTreeConfig
    • method privateMutableShortIntBTreeMapFactory(LargeByteBufferAllocator, BTreeConfig): void
    • method final publicwithAllocator(LargeByteBufferAllocator): MutableShortIntBufferMapFactory
    • method final publicwithAllocatorAndConfig(LargeByteBufferAllocator, BTreeConfig): MutableShortIntBufferMapFactory
    • method publicempty(): MutableShortIntBufferMap
    • method publicofInitialCapacity(int): MutableShortIntBufferMap
    • method publicofAll(ShortIntMap): MutableShortIntBufferMap
https://github.com/yawkat/numaec: NUMA-capable implementation of parts of eclipse-collections-api
  • Eclipse Public License - v 1.0
  • Jonas Konrad
package at.yawk.numaec;

import org.eclipse.collections.api.map.primitive.ShortIntMap;

public final class MutableShortIntBTreeMapFactory implements MutableShortIntBufferMapFactory {
    private final LargeByteBufferAllocator allocator;
    private final BTreeConfig config;

    private MutableShortIntBTreeMapFactory(LargeByteBufferAllocator allocator, BTreeConfig config) {
        this.allocator = allocator;
        this.config = config;
    }

    public static MutableShortIntBufferMapFactory withAllocator(LargeByteBufferAllocator allocator) {
        return withAllocatorAndConfig(allocator, BTreeConfig.builder().build());
    }

    public static MutableShortIntBufferMapFactory withAllocatorAndConfig(
            LargeByteBufferAllocator allocator, BTreeConfig config
    ) {
        return new MutableShortIntBTreeMapFactory(allocator, config);
    }

    @Override
    public MutableShortIntBufferMap empty() {
        return new ShortIntBTreeMap.Mutable(allocator, config);
    }

    @Override
    public MutableShortIntBufferMap ofInitialCapacity(int capacity) {
        return empty();
    }

    @Override
    public MutableShortIntBufferMap ofAll(ShortIntMap map) {
        MutableShortIntBufferMap n = ofInitialCapacity(map.size());
        n.putAll(map);
        return n;
    }
}


Missing a library or version you want to see? Open an issue!
Icon set and themes from IntelliJ Community