001    package com.sptci.rwt.webui;
002    
003    import com.sptci.echo2.Configuration;
004    import com.sptci.epng.Tree;
005    import com.sptci.rwt.webui.tree.DBMSNode;
006    import com.sptci.rwt.webui.tree.SelectionListener;
007    
008    /**
009     * The {@link com.sptci.epng.Tree} component used to display the database
010     * metadata objects in hierarchical format.
011     *
012     * <p>&copy; Copyright 2007 <a href='http://sptci.com/' target='_new'>Sans Pareil Technologies, Inc.</a></p>
013     * @author Rakesh Vidyadharan 2007-09-29
014     * @version $Id: MetaDataTree.java 4123 2008-05-25 21:49:01Z rakesh $
015     */
016    public class MetaDataTree extends Tree
017    {
018      /** The controller for interacting with the application. */
019      private final MainController controller;
020    
021      /**
022       * Create a new instance using the specified controller.
023       *
024       * @param controller The {@link #controller} to use.
025       */
026      public MetaDataTree( final MainController controller )
027      {
028        super( new DBMSNode( controller.getDBMSMetaData() ) );
029        this.controller = controller;
030        getSelectionModel().addTreeSelectionListener(
031            new SelectionListener( controller ) );
032      }
033    }