Optimize with a SATA RAID Storage Solution
Range of capacities as low as $1250 per TB. Ideal if you currently rely on servers/disks/JBODs
Java's Abstract Windowing Toolkit (AWT) includes four concrete menu classes: menu bars representing a group of menus that
appears across the top of the window or the screen (class MenuBar); pull-down menus that pull from menu bars or from other menus (class Menu); menu items that represent menu selections (class MenuItem); and menu items that the user can turn on and off (class CheckBoxMenuItem).
These classes are all subclasses of MenuComponent, not subclasses of Component. Because they aren't components, they can't be placed in any container -- the way you would place buttons and lists in a
container. In a graphical user interface (GUI) the only way to use these menu classes is to place a menu bar (which can contain
additional menus) in a frame using the frame's setMenuBar method. Since the applet class is not a subclass of Frame, it does not inherit the setMenuBar method. This means you cannot simply place a menu bar in an applet.
Still, there are several ways to create applets with menus: (1) An applet can open a new frame that contains an AWT menu bar with pull-down menus -- perhaps in response to the user clicking on a button; (2) an applet can use a custom pop-up-menu class, either one that you implement yourself or one that comes from a third-party widget library. (The AWT itself does not include pop-up menus.); and (3) an applet can also use an AWT menu bar with pull-down menus embedded in its enclosing rectangle in a Web page. You can accomplish this last action using the simple technique described in this article.
While each of the three approaches has its uses, the last one has several advantages over the other two. The main advantage of this approach over a design in which the applet opens a new frame with a menu bar are:
The main advantages of using AWT menus in applets rather than using a custom pop-up-menu class are:
Although an applet is not a subclass of Frame and therefore cannot contain a menu bar, it is always contained within some frame. You can find the frame that contains your
applet using the following code, which was suggested for a different purpose in the Recently Asked Questions document on Sun's JavaSoft site: