diff options
author | Aaron M. Renn <arenn@urbanophile.com> | 1998-05-18 00:34:12 +0000 |
---|---|---|
committer | Aaron M. Renn <arenn@urbanophile.com> | 1998-05-18 00:34:12 +0000 |
commit | cef12ba87faabdb23fc796df9046ddf61247e325 (patch) | |
tree | f19569ad75e9695f2448093caeed508768f9a5cb /java/net/ContentHandlerFactory.java | |
parent | e5cd4c332de77192e9beb4b0533a2e6ffe0e0cd1 (diff) | |
download | classpath-cef12ba87faabdb23fc796df9046ddf61247e325.tar.gz |
Initial Checkin
Diffstat (limited to 'java/net/ContentHandlerFactory.java')
-rw-r--r-- | java/net/ContentHandlerFactory.java | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/java/net/ContentHandlerFactory.java b/java/net/ContentHandlerFactory.java new file mode 100644 index 000000000..65b8e47ed --- /dev/null +++ b/java/net/ContentHandlerFactory.java @@ -0,0 +1,45 @@ +/************************************************************************* +/* ContentHandlerFactory.java -- Interface for creating content handlers +/* +/* Copyright (c) 1998 by Aaron M. Renn (arenn@urbanophile.com) +/* +/* This program is free software; you can redistribute it and/or modify +/* it under the terms of the GNU Library General Public License as published +/* by the Free Software Foundation, version 2. (see COPYING.LIB) +/* +/* This program is distributed in the hope that it will be useful, but +/* WITHOUT ANY WARRANTY; without even the implied warranty of +/* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +/* GNU General Public License for more details. +/* +/* You should have received a copy of the GNU General Public License +/* along with this program; if not, write to the Free Software Foundation +/* Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307 USA +/*************************************************************************/ + +package java.net; + +/** + * This interface maps MIME types to ContentHandler objects. It consists + * of one method that, when passed a MIME type, returns a handler for that + * type. + * + * @version 0.5 + * + * @author Aaron M. Renn (arenn@urbanophile.com) + */ +public interface ContentHandlerFactory +{ +/** + * This method is passed a MIME type as a string and is responsible for + * returning the appropriate ContentType object. + * + * @param mime_type The MIME type to map to a ContentHandler + * + * @return The ContentHandler for the passed in MIME type + */ +public abstract ContentHandler +createContentHandler(String mime_type); + +} // interface ContentHandlerFactory + |