Code example for LinkedHashSet

Methods: add

0
     * Map a key to a value. Can be called multiple times with the same key, but different value. 
     */ 
    public void put(A key, B value) {
        LinkedHashSet<B> vals = get(key);
        if (vals == null) {
            vals = new LinkedHashSet<B>();
            put(key, vals);
        } 
        vals.add(value);
    } 
 
    /** 
     * Put a key that maps to nothing. 
     */ 
    public void putVoid(A key) {
        if (containsKey(key))
            return; 
        put(key, new LinkedHashSet<B>());
    } 
 
    /**