sources.am, [...]: Rebuilt.

* sources.am, Makefile.in: Rebuilt.
	* scripts/mime.types: Removed.
	* scripts/MakeDefaultMimeTypes.java: Removed.
	* gnu/gcj/io/MimeTypes.java: Removed.
	* gnu/gcj/io/MimeTypes.h: Removed.
	* gnu/gcj/io/DefaultMimeTypes.java: Removed.
	* gnu/gcj/io/DefaultMimeTypes.h: Removed.

From-SVN: r123288
This commit is contained in:
Tom Tromey
2007-03-28 02:01:01 +00:00
committed by Tom Tromey
parent 00ffc97ce5
commit ee753a0ab1
11 changed files with 10 additions and 654 deletions
-35
View File
@@ -1,35 +0,0 @@
// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*-
#ifndef __gnu_gcj_io_DefaultMimeTypes__
#define __gnu_gcj_io_DefaultMimeTypes__
#pragma interface
#include <java/lang/Object.h>
#include <gcj/array.h>
extern "Java"
{
namespace gnu
{
namespace gcj
{
namespace io
{
class DefaultMimeTypes;
}
}
}
}
class gnu::gcj::io::DefaultMimeTypes : public ::java::lang::Object
{
public:
DefaultMimeTypes();
static JArray< ::java::lang::String * > * types;
static ::java::lang::Class class$;
};
#endif // __gnu_gcj_io_DefaultMimeTypes__
-139
View File
@@ -1,139 +0,0 @@
// Do not edit this file! Create a new version with MakeDefaultMimeTypes.
/* Copyright (C) 2000 Free Software Foundation
This file is part of libgcj.
This software is copyrighted work licensed under the terms of the
Libgcj License. Please consult the file "LIBGCJ_LICENSE" for
details. */
package gnu.gcj.io;
public class DefaultMimeTypes
{
public static final String[] types = {
"midi", "audio/midi"
, "sit", "application/x-stuffit"
, "ram", "audio/x-pn-realaudio"
, "ez", "application/andrew-inset"
, "jpeg", "image/jpeg"
, "sv4crc", "application/x-sv4crc"
, "sv4cpio", "application/x-sv4cpio"
, "txt", "text/plain"
, "spl", "application/x-futuresplash"
, "ras", "image/x-cmu-raster"
, "sh", "application/x-sh"
, "dcr", "application/x-director"
, "msh", "model/mesh"
, "swf", "application/x-shockwave-flash"
, "hdf", "application/x-hdf"
, "bcpio", "application/x-bcpio"
, "zip", "application/zip"
, "gif", "image/gif"
, "me", "application/x-troff-me"
, "gtar", "application/x-gtar"
, "tex", "application/x-tex"
, "xyz", "chemical/x-pdb"
, "hqx", "application/mac-binhex40"
, "ms", "application/x-troff-ms"
, "oda", "application/oda"
, "vcd", "application/x-cdlink"
, "aifc", "audio/x-aiff"
, "skd", "application/x-koan"
, "smil", "application/smil"
, "asc", "text/plain"
, "aiff", "audio/x-aiff"
, "xml", "text/xml"
, "tr", "application/x-troff"
, "nc", "application/x-netcdf"
, "dxr", "application/x-director"
, "skm", "application/x-koan"
, "wrl", "model/vrml"
, "tsv", "text/tab-separated-values"
, "mpeg", "video/mpeg"
, "skp", "application/x-koan"
, "src", "application/x-wais-source"
, "rpm", "application/x-rpm"
, "skt", "application/x-koan"
, "ai", "application/postscript"
, "cpt", "application/mac-compactpro"
, "mp2", "audio/mpeg"
, "man", "application/x-troff-man"
, "mp3", "audio/mpeg"
, "mesh", "model/mesh"
, "igs", "model/iges"
, "shar", "application/x-shar"
, "au", "audio/basic"
, "texi", "application/x-texinfo"
, "cpio", "application/x-cpio"
, "jpe", "image/jpeg"
, "lzh", "application/octet-stream"
, "jpg", "image/jpeg"
, "cdf", "application/x-netcdf"
, "etx", "text/x-setext"
, "texinfo", "application/x-texinfo"
, "sgml", "text/sgml"
, "roff", "application/x-troff"
, "pgm", "image/x-portable-graymap"
, "pgn", "application/x-chess-pgn"
, "bin", "application/octet-stream"
, "png", "image/png"
, "tar", "application/x-tar"
, "mid", "audio/midi"
, "mov", "video/quicktime"
, "movie", "video/x-sgi-movie"
, "mif", "application/vnd.mif"
, "pnm", "image/x-portable-anymap"
, "mpga", "audio/mpeg"
, "smi", "application/smil"
, "t", "application/x-troff"
, "tiff", "image/tiff"
, "xbm", "image/x-xbitmap"
, "htm", "text/html"
, "mpe", "video/mpeg"
, "dms", "application/octet-stream"
, "mpg", "video/mpeg"
, "lha", "application/octet-stream"
, "latex", "application/x-latex"
, "ps", "application/postscript"
, "sgm", "text/sgml"
, "tif", "image/tiff"
, "ice", "x-conference/x-cooltalk"
, "snd", "audio/basic"
, "html", "text/html"
, "pbm", "image/x-portable-bitmap"
, "xpm", "image/x-xpixmap"
, "iges", "model/iges"
, "aif", "audio/x-aiff"
, "avi", "video/x-msvideo"
, "csh", "application/x-csh"
, "wav", "audio/x-wav"
, "xwd", "image/x-xwindowdump"
, "js", "application/x-javascript"
, "silo", "model/mesh"
, "vrml", "model/vrml"
, "tcl", "application/x-tcl"
, "css", "text/css"
, "eps", "application/postscript"
, "class", "application/octet-stream"
, "qt", "video/quicktime"
, "doc", "application/msword"
, "ustar", "application/x-ustar"
, "ppm", "image/x-portable-pixmap"
, "ppt", "application/vnd.ms-powerpoint"
, "ra", "audio/x-realaudio"
, "rgb", "image/x-rgb"
, "rtf", "text/rtf"
, "kar", "audio/midi"
, "dvi", "application/x-dvi"
, "rm", "audio/x-pn-realaudio"
, "exe", "application/octet-stream"
, "pdb", "chemical/x-pdb"
, "pdf", "application/pdf"
, "rtx", "text/richtext"
, "dir", "application/x-director"
, "ief", "image/ief"
};
}
-37
View File
@@ -1,37 +0,0 @@
// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*-
#ifndef __gnu_gcj_io_MimeTypes__
#define __gnu_gcj_io_MimeTypes__
#pragma interface
#include <java/lang/Object.h>
extern "Java"
{
namespace gnu
{
namespace gcj
{
namespace io
{
class MimeTypes;
}
}
}
}
class gnu::gcj::io::MimeTypes : public ::java::lang::Object
{
public:
MimeTypes();
static void fillFromFile(::java::util::Hashtable *, ::java::lang::String *);
static ::java::lang::String * getMimeTypeFromExtension(::java::lang::String *);
private:
static ::java::util::Hashtable * mime_types;
public:
static ::java::lang::Class class$;
};
#endif // __gnu_gcj_io_MimeTypes__
-86
View File
@@ -1,86 +0,0 @@
/* Copyright (C) 2000 Free Software Foundation
This file is part of libgcj.
This software is copyrighted work licensed under the terms of the
Libgcj License. Please consult the file "LIBGCJ_LICENSE" for
details. */
package gnu.gcj.io;
import java.util.*;
import java.io.*;
public class MimeTypes
{
private static Hashtable mime_types;
public static void fillFromFile (Hashtable table, String fname)
throws IOException
{
LineNumberReader reader =
new LineNumberReader (new FileReader (fname));
while (reader.ready ())
{
StringTokenizer tokenizer =
new StringTokenizer (reader.readLine ());
try
{
String t = tokenizer.nextToken ();
if (! t.startsWith ("#"))
{
while (true)
{
// Read the next extension
String e = tokenizer.nextToken ();
if ((e != null) && (! e.startsWith ("#")))
table.put (e, t);
else
break;
}
}
} catch (NoSuchElementException ex) {
// Do nothing.
}
}
}
// This is the primary interface to this class.
public static String getMimeTypeFromExtension (String extension)
{
if (mime_types == null)
{
mime_types = new Hashtable ();
// First populate the hash table with the default mime type
// mappings.
int i = DefaultMimeTypes.types.length;
while (i > 1)
{
mime_types.put (DefaultMimeTypes.types[i - 2],
DefaultMimeTypes.types[i - 1]);
i = i - 2;
}
// Now read mime types from /etc/mime.types if it exists.
// This should override the default values.
try {
fillFromFile (mime_types, "/etc/mime.types");
} catch (IOException ex) {
// Do nothing.
}
// Now read mime types from ~/.mime.types.
// FIXME: We can't currently parse this file.
}
String type = (String) mime_types.get (extension);
if (type == null)
return ("application/octet-stream");
else
return (type);
}
}