///home/berryj/link/bin/genMethods "-t" "Testobj" "-I" "LINK/userobj/Testobj.h" "-d" "userobj" "-y" "display_testobj" "-w" "free_testobj" 
#include <stk.h>
#include <LINK/stkWrapper/LINK_STk.h>

#include <LINK/userobj/Testobj.h>

#include <LINK/stkWrapper/Wrapper.h>
#include <LINK/stkWrapper/Register.h>

void display_testobj(SCM, SCM, int);
void free_testobj(SCM);

typedef Testobj _Testobj;

#define _TestobjDATA(x) ((Testobj*) (EXTDATA(x)))
#define _TestobjIS_DATA(x) (TYPEP(x, tc_CXXwrapper) && \
		TYPEP(STk_slot_ref(x,val_scm), tc_CXXwrapper) && \
		(EXTID(STk_slot_ref(x,val_scm)) == Wrapper<Testobj >::type))
#define _TestobjISNT_DATA(x) (!_TestobjIS_DATA(x))

#define _TestobjCXX_DATA(x) (*(Testobj*) (EXTDATA(VAL(x))))
#define _TestobjCXX_IS_DATA(x) (INSTANCEP(x) && \
		TYPEP(STk_slot_ref(x,val_scm), tc_CXXwrapper) && \
		(EXTID(STk_slot_ref(x,val_scm)) == Wrapper<Testobj >::type))
#define _TestobjCXX_ISNT_DATA(x) (!_TestobjCXX_IS_DATA(x))


PRIMITIVE STk_init__Testobj()
{
	Wrapper<_Testobj>::type = STk_new_CXXwrapper_id(
			Wrapper<_Testobj>::name, 
			"",
			(void (*)(SCM x, SCM port, int mode))
			display_testobj,
			(void (*)(SCM x))0,
			(void (*)(SCM x))free_testobj);
	Tcl_InitHashTable(&Register<_Testobj>::objTable, TCL_ONE_WORD_KEYS);
	return UNDEFINED;
}

void genExtra_TestobjMethods(void);

PRIMITIVE STk_init_methods__Testobj()
{
	genExtra_TestobjMethods();
	return UNDEFINED;
}
