1. /*
  2. * Copyright (c) 2004 World Wide Web Consortium,
  3. *
  4. * (Massachusetts Institute of Technology, European Research Consortium for
  5. * Informatics and Mathematics, Keio University). All Rights Reserved. This
  6. * work is distributed under the W3C(r) Software License [1] in the hope that
  7. * it will be useful, but WITHOUT ANY WARRANTY; without even the implied
  8. * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  9. *
  10. * [1] http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
  11. */
  12. package org.w3c.dom;
  13. /**
  14. * This interface permits a DOM implementer to supply one or more
  15. * implementations, based upon requested features and versions, as specified
  16. * in . Each implemented <code>DOMImplementationSource</code> object is
  17. * listed in the binding-specific list of available sources so that its
  18. * <code>DOMImplementation</code> objects are made available.
  19. * <p>See also the <a href='http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407'>Document Object Model (DOM) Level 3 Core Specification</a>.
  20. * @since DOM Level 3
  21. */
  22. public interface DOMImplementationSource {
  23. /**
  24. * A method to request the first DOM implementation that supports the
  25. * specified features.
  26. * @param features A string that specifies which features and versions
  27. * are required. This is a space separated list in which each feature
  28. * is specified by its name optionally followed by a space and a
  29. * version number. This method returns the first item of the list
  30. * returned by <code>getDOMImplementationList</code>. As an example,
  31. * the string <code>"XML 3.0 Traversal +Events 2.0"</code> will
  32. * request a DOM implementation that supports the module "XML" for its
  33. * 3.0 version, a module that support of the "Traversal" module for
  34. * any version, and the module "Events" for its 2.0 version. The
  35. * module "Events" must be accessible using the method
  36. * <code>Node.getFeature()</code> and
  37. * <code>DOMImplementation.getFeature()</code>.
  38. * @return The first DOM implementation that support the desired
  39. * features, or <code>null</code> if this source has none.
  40. */
  41. public DOMImplementation getDOMImplementation(String features);
  42. /**
  43. * A method to request a list of DOM implementations that support the
  44. * specified features and versions, as specified in .
  45. * @param features A string that specifies which features and versions
  46. * are required. This is a space separated list in which each feature
  47. * is specified by its name optionally followed by a space and a
  48. * version number. This is something like: "XML 3.0 Traversal +Events
  49. * 2.0"
  50. * @return A list of DOM implementations that support the desired
  51. * features.
  52. */
  53. public DOMImplementationList getDOMImplementationList(String features);
  54. }