| | |
| | | * |
| | | * |
| | | * Copyright 2010 Sun Microsystems, Inc. |
| | | * Portions Copyright 2011-2014 ForgeRock AS |
| | | * Portions Copyright 2011-2015 ForgeRock AS |
| | | */ |
| | | package org.opends.server.api; |
| | | |
| | |
| | | private int size; |
| | | |
| | | /** Backing Map implementation. */ |
| | | private Map<DN,Node<T>> ditCacheMap; |
| | | private final Map<DN,Node<T>> ditCacheMap = new HashMap<>(); |
| | | |
| | | /** Default constructor. */ |
| | | public DITCacheMap() |
| | | { |
| | | ditCacheMap = new HashMap<DN,Node<T>>(); |
| | | } |
| | | |
| | | /** |
| | |
| | | */ |
| | | public DITCacheMap(Map<? extends DN, ? extends T> m) |
| | | { |
| | | ditCacheMap = new HashMap<DN,Node<T>>(); |
| | | this.putAll(m); |
| | | } |
| | | |
| | |
| | | return returnValue; |
| | | } |
| | | |
| | | Node<T> node = new Node<T>(); |
| | | Node<T> node = new Node<>(); |
| | | node.dn = key; |
| | | node.element = value; |
| | | node.parent = null; |
| | |
| | | if (parentNode == null) |
| | | { |
| | | // Add glue node. |
| | | final Node<T> newParentNode = new Node<T>(); |
| | | final Node<T> newParentNode = new Node<>(); |
| | | newParentNode.dn = parentDN; |
| | | newParentNode.element = null; |
| | | newParentNode.parent = null; |