* src/vm/Makefile.am (noinst_LTLIBRARIES): Reformatted.
[cacao.git] / src / vm / loader.h
index 1bd005f6f4202717d9f451e974a366fb4d6ec44a..412553a531f1a5754a985c7ce67a279aa7e118cd 100644 (file)
@@ -1,9 +1,9 @@
 /* src/vm/loader.h - class loader header
 
-   Copyright (C) 1996-2005 R. Grafl, A. Krall, C. Kruegel, C. Oates,
-   R. Obermaisser, M. Platter, M. Probst, S. Ring, E. Steiner,
-   C. Thalinger, D. Thuernbeck, P. Tomsich, C. Ullrich, J. Wenninger,
-   Institut f. Computersprachen - TU Wien
+   Copyright (C) 1996-2005, 2006 R. Grafl, A. Krall, C. Kruegel,
+   C. Oates, R. Obermaisser, M. Platter, M. Probst, S. Ring,
+   E. Steiner, C. Thalinger, D. Thuernbeck, P. Tomsich, C. Ullrich,
+   J. Wenninger, Institut f. Computersprachen - TU Wien
 
    This file is part of CACAO.
 
 
    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.
+   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+   02110-1301, USA.
 
-   Contact: cacao@complang.tuwien.ac.at
+   Contact: cacao@cacaojvm.org
 
    Authors: Reinhard Grafl
 
-   $Id: loader.h 3501 2005-10-26 20:27:15Z twisti $
+   Changes: Christian Thalinger
+
+   $Id: loader.h 4490 2006-02-12 16:02:43Z edwin $
 */
 
 
 #ifndef _LOADER_H
 #define _LOADER_H
 
+#include "config.h"
+
 #include <stdio.h>
 
+#include "vm/types.h"
+
 
 /* forward typedefs ***********************************************************/
 
 typedef struct classbuffer classbuffer;
-typedef struct classpath_info classpath_info;
 
 
+#include "vm/class.h"
+#include "vm/descriptor.h"
 #include "vm/global.h"
-#include "vm/utf8.h"
 #include "vm/references.h"
-#include "vm/descriptor.h"
 #include "vm/method.h"
-
-#if defined(USE_ZLIB)
-# include "vm/unzip.h"
-#endif
-
-
-/* signed suck defines ********************************************************/
-
-#define suck_s8(a)    (s8) suck_u8((a))
-#define suck_s2(a)    (s2) suck_u2((a))
-#define suck_s4(a)    (s4) suck_u4((a))
-#define suck_s1(a)    (s1) suck_u1((a))
+#include "vm/utf8.h"
 
 
 /* constant pool entries *******************************************************
@@ -121,49 +115,19 @@ struct classbuffer {
 };
 
 
-/* classpath_info *************************************************************/
-
-#define CLASSPATH_PATH       0
-#define CLASSPATH_ARCHIVE    1
-
-struct classpath_info {
-#if defined(USE_THREADS)
-       /* Required for monitor locking on zip/jar files. */
-       java_objectheader  header;
-#endif
-       s4                 type;
-       char              *path;
-       s4                 pathlen;
-#if defined(USE_ZLIB)
-       unzFile            uf;
-#endif
-       classpath_info    *next;
-};
-
-
 /* export variables ***********************************************************/
 
 #if defined(USE_THREADS)
 extern int blockInts;
 #endif
 
-extern classpath_info *classpath_entries;
-
 
 /* function prototypes ********************************************************/
 
 /* initialize loader, load important systemclasses */
 bool loader_init(u1 *stackbottom);
 
-void suck_init(char *cpath);
 void loader_load_all_classes(void);
-void suck_stop(classbuffer *cb);
-
-inline bool check_classbuffer_size(classbuffer *cb, s4 len);
-
-inline u1 suck_u1(classbuffer *cb);
-inline u2 suck_u2(classbuffer *cb);
-inline u4 suck_u4(classbuffer *cb);
 
 /* free resources */
 void loader_close(void);
@@ -177,13 +141,6 @@ classinfo *load_class_bootstrap(utf *name);
 classinfo *load_class_from_classbuffer(classbuffer *cb);
 classinfo *load_newly_created_array(classinfo *c,java_objectheader *loader);
 
-/* return the primitive class inidicated by the given signature character */
-classinfo *class_primitive_from_sig(char sig);
-
-/* debug helpers */
-void fprintflags(FILE *fp, u2 f);
-void printflags(u2 f);
-
 #endif /* _LOADER_H */
 
 /*
@@ -197,4 +154,5 @@ void printflags(u2 f);
  * c-basic-offset: 4
  * tab-width: 4
  * End:
+ * vim:noexpandtab:sw=4:ts=4:
  */