1. /*
  2. * Copyright 2002 Sun Microsystems, Inc. All rights reserved.
  3. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  4. */
  5. package javax.activation;
  6. /**
  7. * This interface defines a factory for <code>DataContentHandlers</code>. An
  8. * implementation of this interface should map a MIME type into an
  9. * instance of DataContentHandler. The design pattern for classes implementing
  10. * this interface is the same as for the ContentHandler mechanism used in
  11. * <code>java.net.URL</code>.
  12. */
  13. public interface DataContentHandlerFactory {
  14. /**
  15. * Creates a new DataContentHandler object for the MIME type.
  16. *
  17. * @param mimeType the MIME type to create the DataContentHandler for.
  18. * @return The new <code>DataContentHandler</code>, or <i>null</i>
  19. * if none are found.
  20. */
  21. public DataContentHandler createDataContentHandler(String mimeType);
  22. }