//						IMPORTS.H

#ifndef importsh
#define importsh

struct importdirentry
{ unsigned long originalthunkrva;
  unsigned long timedatestamp;
  unsigned long forwarder;
  unsigned long namerva;
  unsigned long firstthunkrva;
};

struct importlist
{ struct importlist *next;
  unsigned char *name;
  unsigned long addr;
};

class imp
{ private:
	 struct importlist *implist;
	 char *exportnames;
	 unsigned long fsize;

  public:
	 imp();
	 ~imp();
	 void summary(void);
	 BOOL isimport(unsigned long address);
    void printname(unsigned long address);

  private:
	 void addtoimplist(unsigned char *name,unsigned long addr);
	 void ordaddtoimplist(unsigned char *dllname,unsigned long ordnum,unsigned long addr);
	 unsigned char *lookupimpname(unsigned char *dllname,unsigned long ordnum);
};

#endif