/** * Transforms an entry of a {@link SplitDockStationLayout} into a key * of a {@link SplitDockTree}. * @param entry the element to transform * @param tree the tree into which to add new keys * @param children the set of known children * @return the key or <code>null</code> */ private <D> SplitDockTree<D>.Key handleEntry( SplitDockStationLayout.Entry entry, SplitDockTree<D> tree, Map<Integer, D> children ){ if( entry.asLeaf() != null ) return handleLeaf( entry.asLeaf(), tree, children ); else return handleNode( entry.asNode(), tree, children ); }