src/share/classes/java/applet/AppletContext.java

Print this page
rev 10048 : 8044740: Convert all JDK versions used in @since tag to 1.n[.n] in jdk repo
Reviewed-by:


  26 package java.applet;
  27 
  28 import java.awt.Image;
  29 import java.awt.Graphics;
  30 import java.awt.image.ColorModel;
  31 import java.net.URL;
  32 import java.util.Enumeration;
  33 import java.io.InputStream;
  34 import java.io.IOException;
  35 import java.util.Iterator;
  36 
  37 /**
  38  * This interface corresponds to an applet's environment: the
  39  * document containing the applet and the other applets in the same
  40  * document.
  41  * <p>
  42  * The methods in this interface can be used by an applet to obtain
  43  * information about its environment.
  44  *
  45  * @author      Arthur van Hoff
  46  * @since       JDK1.0
  47  */
  48 public interface AppletContext {
  49     /**
  50      * Creates an audio clip.
  51      *
  52      * @param   url   an absolute URL giving the location of the audio clip.
  53      * @return  the audio clip at the specified URL.
  54      */
  55     AudioClip getAudioClip(URL url);
  56 
  57     /**
  58      * Returns an <code>Image</code> object that can then be painted on
  59      * the screen. The <code>url</code> argument that is
  60      * passed as an argument must specify an absolute URL.
  61      * <p>
  62      * This method always returns immediately, whether or not the image
  63      * exists. When the applet attempts to draw the image on the screen,
  64      * the data will be loaded. The graphics primitives that draw the
  65      * image will incrementally paint on the screen.
  66      *




  26 package java.applet;
  27 
  28 import java.awt.Image;
  29 import java.awt.Graphics;
  30 import java.awt.image.ColorModel;
  31 import java.net.URL;
  32 import java.util.Enumeration;
  33 import java.io.InputStream;
  34 import java.io.IOException;
  35 import java.util.Iterator;
  36 
  37 /**
  38  * This interface corresponds to an applet's environment: the
  39  * document containing the applet and the other applets in the same
  40  * document.
  41  * <p>
  42  * The methods in this interface can be used by an applet to obtain
  43  * information about its environment.
  44  *
  45  * @author      Arthur van Hoff
  46  * @since       1.0
  47  */
  48 public interface AppletContext {
  49     /**
  50      * Creates an audio clip.
  51      *
  52      * @param   url   an absolute URL giving the location of the audio clip.
  53      * @return  the audio clip at the specified URL.
  54      */
  55     AudioClip getAudioClip(URL url);
  56 
  57     /**
  58      * Returns an <code>Image</code> object that can then be painted on
  59      * the screen. The <code>url</code> argument that is
  60      * passed as an argument must specify an absolute URL.
  61      * <p>
  62      * This method always returns immediately, whether or not the image
  63      * exists. When the applet attempts to draw the image on the screen,
  64      * the data will be loaded. The graphics primitives that draw the
  65      * image will incrementally paint on the screen.
  66      *