1 package com.loribel.commons.abstraction;
2
3 import javax.swing.tree.*;
4
5 /***
6 * Interface for Builder of trees.
7 * <p>
8 * Implementations of this interface can build a hierarchy of TreeNode to represent an
9 * object.
10 *
11 * @author Grégory Borelli
12 * @version 2003/09/18 - 16:53:29 - gen 7.09
13 */
14 public interface GB_TreeBuilder
15 {
16
17 /***
18 * Build a tree Node to represent the data <tt>a_data</tt>
19 *
20 * @param a_data Object - the data of the node
21 *
22 * @return TreeNode
23 */
24 TreeNode buildTreeNode(
25 Object a_data);
26
27 /***
28 * Build the children of a TreeNode.
29 *
30 * @param a_parent TreeNode - the parent of the children
31 * @param a_data Object - the data of the parent
32 *
33 * @return java.util.List
34 */
35 java.util.List buildChildren(
36 TreeNode a_parent,
37 Object a_data);
38
39 }