org.mortbay.html

Class Applet

public class Applet extends Block

An Applet Block.

Lets you set the class name from the program, and optionally, the size and the codebase.

This class uses any attributes set in Element.

Usage

 org.mortbay.Page page = new org.mortbay.html.Page();
 page.add(new org.mortbay.Applet("org.mortbay.Foo.App"));
 

Version: $Id: Applet.java,v 1.7 2004/07/19 13:12:58 hlavac Exp $

Author: Matthew Watson

See Also: Block

Field Summary
StringcodeBase
Constructor Summary
Applet(String className)
Create an Applet Element.
Method Summary
AppletcodeBase(String cb)
Set the codebase
AppletsetAlternate(Element alt)
Set an alternate display for non-java browsers.
AppletsetAlternate(String alt)
Set an alternate display for non-java browsers.
AppletsetDebug(boolean debug)
Set whether debugging is on in the Applet.
AppletsetDimensions(int height, int width)
Set the dimensions of the Applet.
AppletsetParam(String name, String value)
voidwrite(Writer out)
Write out the HTML

Field Detail

codeBase

public String codeBase

Constructor Detail

Applet

public Applet(String className)
Create an Applet Element.

Parameters: className The name of the class to give for the applet

Method Detail

codeBase

public Applet codeBase(String cb)
Set the codebase

setAlternate

public Applet setAlternate(Element alt)

Deprecated: use add

Set an alternate display for non-java browsers.

Parameters: alt The alternate element to display

setAlternate

public Applet setAlternate(String alt)

Deprecated: use add

Set an alternate display for non-java browsers.

Parameters: alt The alternate element to display

setDebug

public Applet setDebug(boolean debug)
Set whether debugging is on in the Applet.

This controls whether the org.mortbay.util.Code debug messages will be printed to the java console.

Defaults to whether debug is turned on in the generating app

setDimensions

public Applet setDimensions(int height, int width)
Set the dimensions of the Applet.

setParam

public Applet setParam(String name, String value)

write

public void write(Writer out)
Write out the HTML
Copyright © 2004 Mortbay Consulting Pty. Ltd. All Rights Reserved.