1. /**
  2. * @(#)AccessibleStreamable.java 1.3 03/12/19
  3. *
  4. * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
  5. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  6. */
  7. package javax.accessibility;
  8. import java.io.InputStream;
  9. import java.awt.datatransfer.DataFlavor;
  10. /*
  11. *
  12. * The <code>AccessibleStreamable</code> interface should be implemented
  13. * by the <code>AccessibleContext</code> of any component that presents the
  14. * raw stream behind a component on the display screen. Examples of such
  15. * components are HTML, bitmap images and MathML. An object that implements
  16. * <code>AccessibleStreamable</code> provides two things: a list of MIME
  17. * types supported by the object and a streaming interface for each MIME type to
  18. * get the data.
  19. *
  20. * @version 1.3 12/19/03
  21. * @author Lynn Monsanto
  22. * @author Peter Korn
  23. *
  24. * @see javax.accessibility.AccessibleContext
  25. * @since 1.5
  26. */
  27. public interface AccessibleStreamable {
  28. /**
  29. * Returns an array of DataFlavor objects for the MIME types
  30. * this object supports.
  31. *
  32. * @return an array of DataFlavor objects for the MIME types
  33. * this object supports.
  34. */
  35. DataFlavor[] getMimeTypes();
  36. /**
  37. * Returns an InputStream for a DataFlavor
  38. *
  39. * @param flavor the DataFlavor
  40. * @return an ImputStream if an ImputStream for this DataFlavor exists.
  41. * Otherwise, null is returned.
  42. */
  43. InputStream getStream(DataFlavor flavor);
  44. }