Package com.gs.collections.impl.map.mutable.primitive

Examples of com.gs.collections.impl.map.mutable.primitive.CharByteHashMap$ValuesCollection


    private static final long serialVersionUID = 1L;
    private final MutableCharByteMap delegate;

    ImmutableCharByteHashMap(CharByteMap delegate)
    {
        this.delegate = new CharByteHashMap(delegate);
    }
View Full Code Here


        return this.delegate.asLazy();
    }

    public ImmutableCharByteMap newWithKeyValue(char key, byte value)
    {
        MutableCharByteMap map = new CharByteHashMap(this.size() + 1);
        map.putAll(this);
        map.put(key, value);
        return map.toImmutable();
    }
View Full Code Here

        return map.toImmutable();
    }

    public ImmutableCharByteMap newWithoutKey(char key)
    {
        MutableCharByteMap map = new CharByteHashMap(this.size());
        map.putAll(this);
        map.removeKey(key);
        return map.toImmutable();
    }
View Full Code Here

        return map.toImmutable();
    }

    public ImmutableCharByteMap newWithoutAllKeys(CharIterable keys)
    {
        MutableCharByteMap map = new CharByteHashMap(this.size());
        map.putAll(this);
        CharIterator iterator = keys.charIterator();
        while (iterator.hasNext())
        {
            map.removeKey(iterator.next());
        }
        return map.toImmutable();
    }
View Full Code Here

        }

        public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
        {
            int size = in.readInt();
            MutableCharByteMap deserializedMap = new CharByteHashMap();

            for (int i = 0; i < size; i++)
            {
                deserializedMap.put(in.readChar(), in.readByte());
            }

            this.map = deserializedMap;
        }
View Full Code Here

    }

    public ImmutableCharByteMap select(CharBytePredicate predicate)
    {
        return predicate.accept(this.key1, this.value1) ? CharByteHashMap.newWithKeysValues(this.key1, this.value1).toImmutable()
                : new CharByteHashMap().toImmutable();
    }
View Full Code Here

                : new CharByteHashMap().toImmutable();
    }

    public ImmutableCharByteMap reject(CharBytePredicate predicate)
    {
        return predicate.accept(this.key1, this.value1) ? new CharByteHashMap().toImmutable()
                : CharByteHashMap.newWithKeysValues(this.key1, this.value1).toImmutable();
    }
View Full Code Here

TOP

Related Classes of com.gs.collections.impl.map.mutable.primitive.CharByteHashMap$ValuesCollection

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.