01: /**
02: * $Id: NetFileRootNode.java,v 1.2 2003/11/19 07:21:20 vt126379 Exp $
03: * Copyright 2003 Sun Microsystems, Inc. All
04: * rights reserved. Use of this product is subject
05: * to license terms. Federal Acquisitions:
06: * Commercial Software -- Government Users
07: * Subject to Standard License Terms and
08: * Conditions.
09: *
10: * Sun, Sun Microsystems, the Sun logo, and Sun ONE
11: * are trademarks or registered trademarks of Sun Microsystems,
12: * Inc. in the United States and other countries.
13: */package com.sun.portal.netfile.applet.java2.model;
14:
15: import java.util.Hashtable;
16:
17: /**
18: * NetFileRootNode:
19: * Represents the root node on the NetFile Tree. It has only 2 children:
20: * a. Network neighbourhood - to which all the remote host are added.
21: * b. Local Host - to which the local drives are mapped and all the local
22: * folders are added.
23: *
24: * This node is not displayed in the applet and only the 2 children are displayed.
25: */
26:
27: public class NetFileRootNode extends NetFileNode {
28:
29: private static final NetFileRootNode instance = new NetFileRootNode();
30:
31: private static final String ICON_NAME = "Neighborhood_16.gif";
32: private static final String OPEN_ICON_NAME = "Neighborhood_16.gif";
33: private static final String NAME = "NetFile Root";
34:
35: private NetFileRootNode() {
36: super (NAME, ICON_NAME, OPEN_ICON_NAME);
37: }
38:
39: public void addNetFileNode(NetFileNode node) {
40: addChildNode(node);
41: }
42:
43: public static NetFileRootNode getInstance() {
44: return instance;
45: }
46:
47: public String getFQName() {
48: return "";
49: }
50:
51: public Hashtable toHashtable() {
52: return new Hashtable();
53: }
54: }
|