#ifndef _CLASS_H
#define _CLASS_H

/*
** $Id: class.h,v 1.2 2002/07/23 12:48:46 buytaert Exp $
*/

#include "jamjar.h"

typedef struct j_Class {
  j_class next;
  j_class previous;
  size_t size;              // Size of class file in bytes
  j_res res;                // The backlink to the resource of this class
  unsigned char * data;     // The classfile data
  unsigned char * name;     // The name of the class, without the ".class" extension
  size_t num_inner;         // The number of inner classes this class has
  j_res inner[0];           // The array with inner classes Java names (from the class information)
} j_Class;

j_class class_read(const char * file, size_t size);
void class_free(j_class class);

#endif /* _CLASS_H */
