Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.batik.bridge
Class BaseScriptingEnvironment.Window

    java.lang.Object
      org.apache.batik.bridge.BaseScriptingEnvironment.Window

All Implemented Interfaces:
  Window

Enclosing class:
  BaseScriptingEnvironment

protected class BaseScriptingEnvironment.Window
extends java.lang.Object
implements Window

Represents the window object of this environment.

Nested Class Summary

Nested classes inherited from class org.apache.batik.script.Window
`Window.GetURLHandler`

Field Summary
`protected Interpreter` | `interpreter` The associated interpreter.
`protected java.lang.String` | `language` The associated language.

Constructor Summary
`BaseScriptingEnvironment.Window(Interpreter interp, java.lang.String lang)` Creates a new Window.

Method Summary
`void` | `alert(java.lang.String message)` Displays an alert dialog box.
`void` | `clearInterval(java.lang.Object interval)` Implements `Window.clearInterval(Object)`.
`void` | `clearTimeout(java.lang.Object timeout)` Implements `Window.clearTimeout(Object)`.
`boolean` | `confirm(java.lang.String message)` Displays a confirm dialog box.
`BridgeContext` | `getBridgeContext()` Returns the current BridgeContext.
`Interpreter` | `getInterpreter()` Returns the associated interpreter.
`void` | `getURL(java.lang.String uri, Window.GetURLHandler h)` Gets data from the given URI.
`void` | `getURL(java.lang.String uri, Window.GetURLHandler h, java.lang.String enc)` Gets data from the given URI.
`org.w3c.dom.Node` | `parseXML(java.lang.String text, org.w3c.dom.Document doc)` Parses the given XML string into a DocumentFragment of the given document or a new document if 'doc' is null.
`java.lang.String` | `prompt(java.lang.String message)` Displays an input dialog box.
`java.lang.String` | `prompt(java.lang.String message, java.lang.String defVal)` Displays an input dialog box, given the default value.
`java.lang.Object` | `setInterval(java.lang.Runnable r, long interval)` Implements `Window.setInterval(Runnable,long)`.
`java.lang.Object` | `setInterval(java.lang.String script, long interval)` Implements `Window.setInterval(String,long)`.
`java.lang.Object` | `setTimeout(java.lang.Runnable r, long timeout)` Implements `Window.setTimeout(Runnable,long)`.
`java.lang.Object` | `setTimeout(java.lang.String script, long timeout)` Implements `Window.setTimeout(String,long)`.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### interpreter

    protected Interpreter interpreter

  The associated interpreter.

### language

    protected java.lang.String language

  The associated language.

Constructor Detail

### BaseScriptingEnvironment.Window

    public BaseScriptingEnvironment.Window(Interpreter interp,
                                           java.lang.String lang)

  Creates a new Window.

Method Detail

### setInterval

    public java.lang.Object setInterval(java.lang.String script,
                                        long interval)

  Implements `Window.setInterval(String,long)`.

  Specified by:
    `setInterval` in interface `Window`
  Returns:
    an object representing the interval created.

### setInterval

    public java.lang.Object setInterval(java.lang.Runnable r,
                                        long interval)

  Implements `Window.setInterval(Runnable,long)`.

  Specified by:
    `setInterval` in interface `Window`
  Returns:
    an object representing the interval created.

### clearInterval

    public void clearInterval(java.lang.Object interval)

  Implements `Window.clearInterval(Object)`.

  Specified by:
    `clearInterval` in interface `Window`

### setTimeout

    public java.lang.Object setTimeout(java.lang.String script,
                                       long timeout)

  Implements `Window.setTimeout(String,long)`.

  Specified by:
    `setTimeout` in interface `Window`
  Returns:
    an object representing the timeout created.

### setTimeout

    public java.lang.Object setTimeout(java.lang.Runnable r,
                                       long timeout)

  Implements `Window.setTimeout(Runnable,long)`.

  Specified by:
    `setTimeout` in interface `Window`
  Returns:
    an object representing the timeout created.

### clearTimeout

    public void clearTimeout(java.lang.Object timeout)

  Implements `Window.clearTimeout(Object)`.

  Specified by:
    `clearTimeout` in interface `Window`

### parseXML

    public org.w3c.dom.Node parseXML(java.lang.String text,
                                     org.w3c.dom.Document doc)

  Parses the given XML string into a DocumentFragment of the given document or a new document if 'doc' is null. The implementation in this class always returns 'null'

  Specified by:
    `parseXML` in interface `Window`
  Returns:
    The document/document fragment or null on error.

### getURL

    public void getURL(java.lang.String uri,
                       Window.GetURLHandler h)

  Gets data from the given URI.

  Specified by:
    `getURL` in interface `Window`
  Parameters:
    `uri` - The URI where the data is located.
    `h` - A handler called when the data is available.

### getURL

    public void getURL(java.lang.String uri,
                       Window.GetURLHandler h,
                       java.lang.String enc)

  Gets data from the given URI.

  Specified by:
    `getURL` in interface `Window`
  Parameters:
    `uri` - The URI where the data is located.
    `h` - A handler called when the data is available.
    `enc` - The character encoding of the data.

### alert

    public void alert(java.lang.String message)

  Displays an alert dialog box.

  Specified by:
    `alert` in interface `Window`

### confirm

    public boolean confirm(java.lang.String message)

  Displays a confirm dialog box.

  Specified by:
    `confirm` in interface `Window`

### prompt

    public java.lang.String prompt(java.lang.String message)

  Displays an input dialog box.

  Specified by:
    `prompt` in interface `Window`
  Returns:
    The input of the user, or null if the dialog was cancelled.

### prompt

    public java.lang.String prompt(java.lang.String message,
                                   java.lang.String defVal)

  Displays an input dialog box, given the default value.

  Specified by:
    `prompt` in interface `Window`
  Returns:
    The input of the user, or null if the dialog was cancelled.

### getBridgeContext

    public BridgeContext getBridgeContext()

  Returns the current BridgeContext.

  Specified by:
    `getBridgeContext` in interface `Window`

### getInterpreter

    public Interpreter getInterpreter()

  Returns the associated interpreter.

  Specified by:
    `getInterpreter` in interface `Window`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004 Apache Software Foundation. All Rights Reserved.