summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEtienne M. Gagnon <etienne.gagnon@uqam.ca>2004-03-29 07:07:23 +0000
committerEtienne M. Gagnon <etienne.gagnon@uqam.ca>2004-03-29 07:07:23 +0000
commit09f0b054866aa87e199ba9f01d6c40b2fcbed79b (patch)
tree2530542527634015d5efc3063a09b3c427ac9827
parent99a877a17ed38044ac99845c682a9ecba8074de7 (diff)
downloadclasspath-09f0b054866aa87e199ba9f01d6c40b2fcbed79b.tar.gz
*** empty log message ***
-rw-r--r--.indent.pro50
-rwxr-xr-xautogen.sh1
-rw-r--r--gnu/regexp/.cvsignore2
-rw-r--r--resource/gnu/regexp/.cvsignore2
-rw-r--r--vm/reference/java/lang/reflect/ReflectUtil.java217
5 files changed, 0 insertions, 272 deletions
diff --git a/.indent.pro b/.indent.pro
deleted file mode 100644
index 352b6ddde..000000000
--- a/.indent.pro
+++ /dev/null
@@ -1,50 +0,0 @@
--T FILE
--T ptrdiff_t
--T size_t
--T va_list
--T JNIEXPORT
--T JNICALL
-
--T Bigint
--T JNIEnv
--T JNINativeMethod
--T JavaVM
--T JavaVMAttachArgs
--T JavaVMInitArgs
--T JavaVMOption
--T _Jv_func
--T ieee_double_shape_type
--T ieee_float_shape_type
--T int32_t
--T jarray
--T jboolean
--T jbooleanArray
--T jbyte
--T jbyteArray
--T jchar
--T jcharArray
--T jclass
--T jdouble
--T jdoubleArray
--T jfieldID
--T jfloat
--T jfloatArray
--T jframeID
--T jint
--T jintArray
--T jlong
--T jlongArray
--T jmethodID
--T jobject
--T jobjectArray
--T jshort
--T jshortArray
--T jsize
--T jstring
--T jthread
--T jthrowable
--T jvalue
--T jweak
--T linkedClass
--T uint32_t
--T vmiError
diff --git a/autogen.sh b/autogen.sh
deleted file mode 100755
index e065bf10e..000000000
--- a/autogen.sh
+++ /dev/null
@@ -1 +0,0 @@
-aclocal && libtoolize --force && autoconf && autoheader && automake -a -c
diff --git a/gnu/regexp/.cvsignore b/gnu/regexp/.cvsignore
deleted file mode 100644
index 282522db0..000000000
--- a/gnu/regexp/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/resource/gnu/regexp/.cvsignore b/resource/gnu/regexp/.cvsignore
deleted file mode 100644
index 282522db0..000000000
--- a/resource/gnu/regexp/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/vm/reference/java/lang/reflect/ReflectUtil.java b/vm/reference/java/lang/reflect/ReflectUtil.java
deleted file mode 100644
index 7946ae60c..000000000
--- a/vm/reference/java/lang/reflect/ReflectUtil.java
+++ /dev/null
@@ -1,217 +0,0 @@
-/* ReflectUtil.java --
- Copyright (C) 2003 David Belanger <dbelan2@cs.mcgill.ca>
-
-This file is part of GNU Classpath.
-
-GNU Classpath is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-GNU Classpath 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 GNU Classpath; see the file COPYING. If not, write to the
-Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-02111-1307 USA.
-
-Linking this library statically or dynamically with other modules is
-making a combined work based on this library. Thus, the terms and
-conditions of the GNU General Public License cover the whole
-combination.
-
-As a special exception, the copyright holders of this library give you
-permission to link this library with independent modules to produce an
-executable, regardless of the license terms of these independent
-modules, and to copy and distribute the resulting executable under
-terms of your choice, provided that you also meet, for each linked
-independent module, the terms and conditions of the license of that
-module. An independent module is a module which is not derived from
-or based on this library. If you modify this library, you may extend
-this exception to your version of the library, but you are not
-obligated to do so. If you do not wish to do so, delete this
-exception statement from your version. */
-
-package java.lang.reflect;
-
-/**
- * Common methods needed by several reflection classes.
- *
- * @author David Bélanger
- *
- */
-class ReflectUtil
-{
-
- /**
- * Returns the <code>Class</code> that represents the type
- * specificied by <code>name</name>. (ex: "I", "V", "Ljava/lang/String;")
- *
- */
- public static Class typeToClass(String name)
- {
- char c;
-
- c = name.charAt(0);
-
- switch (c)
- {
- case 'Z':
- return boolean.class;
- case 'B':
- return byte.class;
- case 'S':
- return short.class;
- case 'C':
- return char.class;
- case 'I':
- return int.class;
- case 'J':
- return long.class;
- case 'F':
- return float.class;
- case 'D':
- return double.class;
- case 'V': // got also that type for return types
- return void.class;
- case 'L':
- {
- String formalName;
- // check needed?
- if (name.charAt(name.length() - 1) != ';')
- {
- throw new InternalError("Invalid class name format");
- }
- formalName = name.substring(1, name.length() - 1); // remove ';'
- formalName = formalName.replace('/', '.');
- try
- {
- return Class.forName(formalName);
- }
- catch (ClassNotFoundException e)
- {
- throw new InternalError(e.toString());
- }
- }
- case '[':
- // formal name for arrays example: "[Ljava.lang.String;"
- {
- String formalName;
-
- formalName = name.replace('/', '.');
-
- /*
- int indexL;
-
- formalName = name;
- indexL = formalName.lastIndexOf('[') + 1;
- if (formalName.charAt(indexL) == 'L') {
- // remove L and ;
- formalName = formalName.substring(0, indexL) +
- formalName.substring(indexL + 1, formalName.length() - 1);
- // '/' => '.'
- formalName = formalName.replace('/', '.');
- }
- */
- try
- {
- return Class.forName(formalName);
- }
- catch (ClassNotFoundException e)
- {
- throw new InternalError(e.toString());
- }
- }
- default:
- throw new InternalError("Unknown type:" + name);
- }
- }
-
- /**
- * Creates an array of <code>Class</code> that represents the
- * type described by <code>names</code>. Names have same format
- * as method signature.
- */
- public static Class[] namesToClasses(String[] names)
- {
- Class[] classes;
-
- classes = new Class[names.length];
- for (int i = 0; i < names.length; i++)
- {
- classes[i] = typeToClass(names[i]);
- }
- return classes;
- }
-
- public static Class getReturnType(String descriptor)
- {
- return typeToClass(descriptor.substring(descriptor.indexOf(')') + 1));
- }
-
- public static Class[] getParameterTypes(String desc)
- {
- String[] names;
- int count;
- int i;
- String descriptor;
-
- // count them
- count = 0;
- i = 0;
- descriptor = desc.substring(desc.indexOf('(') + 1, desc.indexOf(')'));
- while (i < descriptor.length())
- {
- if (descriptor.charAt(i) == '[')
- {
- i++;
- continue;
- }
- if (descriptor.charAt(i) == 'L')
- {
- while (descriptor.charAt(++i) != ';')
- {
- // skip char
- }
- }
- count++;
- i++;
- }
-
- // parse them
- names = new String[count];
- for (i = 0; i < count; i++)
- {
- names[i] = "";
- }
- int index = 0;
- i = 0;
- while (i < descriptor.length())
- {
- if (descriptor.charAt(i) == '[')
- {
- names[index] += "[";
- i++;
- continue;
- }
- if (descriptor.charAt(i) == 'L')
- {
- String s;
- s = descriptor.substring(i, descriptor.indexOf(';', i) + 1);
- names[index] += s;
- i += s.length();
- }
- else
- {
- names[index] += descriptor.charAt(i);
- i++;
- }
- index++;
- }
- return namesToClasses(names);
- }
-
-}