 
#ifndef msgmailbox_DEFINED
#define msgmailbox_DEFINED 1
 
#include <class.h>
/* 
 * This file was generated by the Andrew class system preprocessor.
 * Don't make changes to this file as it is created from msgmlbox.ch and will be
 * overwritten.  Make changes to msgmlbox.ch instead.
 */ 
 
/* 
 * The following information was copied, as-is, from msgmlbox.ch.
 */ 
 






/* 
 * End of information copied from msgmlbox.ch.
 */ 
 
/* 
 * Include the superclass information
 */ 
/* msgmailbox has no super class */ 
 
 
/* 
 * Data structure for msgmailbox 
 */ 
struct msgmailbox { 
    struct {
	struct basicobject_methods *msgmailbox_methods;
    } header;
    struct msgdatabase *database;
    char *folderName;

};

 
/* 
 * End of data structure for msgmailbox.
 */ 
 


#ifndef msgmailbox_PROGRAMMERVERSION
#define msgmailbox_PROGRAMMERVERSION 1
#endif /* msgmailbox_PROGRAMMERVERSION */

#ifdef msgmailbox_VERSION
#undef msgmailbox_VERSION
#endif /* msgmailbox_VERSION */
#define msgmailbox_VERSION ((((msgmailbox_PROGRAMMERVERSION << 16) ^ (7 << 8) ^ sizeof(struct msgmailbox)) & 0x7ffff) + 0x80000 + (1 << 20))

#define msgmailbox_StaticLoadOnlyThisClass()  \
{ extern struct classinfo *msgmailbox__GetClassInfo(); \
  (void) class_EnterInfo(NULL, msgmailbox_classheader.name, msgmailbox__GetClassInfo, NULL, msgmailbox_classheader.namekey); } 
 
#define msgmailbox_StaticLoad()  \
    { \
    msgmailbox_StaticLoadOnlyThisClass();  \
    } 
 
#define msgmailbox_StaticEntry  {msgmailbox_StaticLoad()} 
 
static struct classheader msgmailbox_classheader = {
    msgmailbox_VERSION,
    "msgmailbox",
    "msgmlbox",
    (struct basicobject_methods *) &class_RoutineStruct,
};


#endif /* msgmailbox_DEFINED */

#if !defined(msgmailbox_ROUTINESDEFINED) && !defined(dontDefineRoutinesFor_msgmailbox) && !defined(class_StaticEntriesOnly)
#define msgmailbox_ROUTINESDEFINED

#define msgmailbox_IsThereNewMail(self) \
    ((* ((boolean (*)())((self)->header.msgmailbox_methods->routines[0]))) (self))
#define msgmailbox_CountOfNewMail(self) \
    ((* ((long (*)())((self)->header.msgmailbox_methods->routines[1]))) (self))
#define msgmailbox_ProcessNewMail(self,numGood,numBad,numLocked,firstError,errorBuf,bufferSize) \
    ((* ((boolean (*)())((self)->header.msgmailbox_methods->routines[2]))) (self,numGood,numBad,numLocked,firstError,errorBuf,bufferSize))
#define msgmailbox_SetDatabase(self,database) \
    ((* ((void (*)())((self)->header.msgmailbox_methods->routines[3]))) (self,database))
#define msgmailbox_GetDatabase(self) \
    ((* ((struct msgdatabase * (*)())((self)->header.msgmailbox_methods->routines[4]))) (self))
#define msgmailbox_SetFolderName(self,folderName) \
    ((* ((void (*)())((self)->header.msgmailbox_methods->routines[5]))) (self,folderName))
#define msgmailbox_GetFolderName(self) \
    ((* ((char * (*)())((self)->header.msgmailbox_methods->routines[6]))) (self))

#define msgmailbox_NewFromObject(self) \
    ((* ((struct msgmailbox * (*)())((self)->header.msgmailbox_methods->info->procs->routines[0]))) (&msgmailbox_classheader, (self)->header.msgmailbox_methods->info->versionnumber))
#define msgmailbox_New() \
    (msgmailbox__New(NULL, msgmailbox_VERSION))
#define msgmailbox_Initialize(self) \
    (msgmailbox__Initialize(NULL, self, msgmailbox_VERSION))

#define msgmailbox_Destroy(self) \
    ((* ((void (*)()) ((self)->header.msgmailbox_methods->info->procs->routines[1]))) (&msgmailbox_classheader, self))
#define msgmailbox_Finalize(self) \
    (msgmailbox__Finalize(NULL, self))

#define msgmailbox_InitializeObject(self) \
    ((boolean) msgmailbox__InitializeObject(NULL, self))
#define msgmailbox_FinalizeObject(self) \
    ((void) msgmailbox__FinalizeObject(NULL, self))


#endif /* !defined(msgmailbox_ROUTINESDEFINED) && !defined(dontDefineRoutinesFor_msgmailbox ) && !defined(class_StaticEntriesOnly)*/



#ifndef AUXMODULE

struct msgmailbox_methods {
    struct classinfo *info;
    long (*routines[7])();
};

struct msgmailbox_classprocedures {
    struct classinfo *info;
    long (*routines[6])();
};

boolean msgmailbox__IsThereNewMail();
long msgmailbox__CountOfNewMail();
boolean msgmailbox__ProcessNewMail();
void msgmailbox__SetDatabase();
struct msgdatabase * msgmailbox__GetDatabase();
void msgmailbox__SetFolderName();
char * msgmailbox__GetFolderName();

static struct msgmailbox_methods msgmailbox_methodtable = {
    NULL,
    (long (*)()) msgmailbox__IsThereNewMail,
    (long (*)()) msgmailbox__CountOfNewMail,
    (long (*)()) msgmailbox__ProcessNewMail,
    (long (*)()) msgmailbox__SetDatabase,
    (long (*)()) msgmailbox__GetDatabase,
    (long (*)()) msgmailbox__SetFolderName,
    (long (*)()) msgmailbox__GetFolderName
};

struct msgmailbox *msgmailbox__New();
void msgmailbox__Destroy();
boolean msgmailbox__Initialize();
void msgmailbox__Finalize();
boolean msgmailbox__InitializeObject();
void msgmailbox__FinalizeObject();

static struct msgmailbox_classprocedures msgmailbox_classproceduretable = {
    NULL,
    (long (*)()) msgmailbox__New,
    (long (*)()) msgmailbox__Destroy,
    (long (*)()) msgmailbox__Initialize,
    (long (*)()) msgmailbox__Finalize,
    (long (*)()) msgmailbox__InitializeObject,
    (long (*)()) msgmailbox__FinalizeObject
};


static struct classinfo msgmailbox_classinfo = {
    (struct basicobject_methods *) &msgmailbox_methodtable,
    (struct basicobject_methods *) &msgmailbox_classproceduretable,
    "msgmailbox",
    "msgmlbox",
    msgmailbox_VERSION,
    NULL,
    NULL,
    NULL,
    NULL,
    &msgmailbox_classheader,
    NULL,
    0
};

static int classinitialized = FALSE;

boolean msgmailbox__Initialize(classID, self, versionnumber)
struct classheader *classID;
struct msgmailbox *self;
unsigned long versionnumber;
{
    if (! classinitialized)  {
	classinitialized = TRUE;
	msgmailbox_methodtable.info = &msgmailbox_classinfo;
    }
    self->header.msgmailbox_methods = (struct basicobject_methods *) &msgmailbox_methodtable;
    if(!msgmailbox__InitializeObject(classID, self)){
	return FALSE;
    }
    return TRUE;
}

struct msgmailbox *msgmailbox__New(classID, versionnumber)
struct classheader *classID;
unsigned long versionnumber;
{
    struct msgmailbox *self;
    if (versionnumber != class_VERSIONNOTKNOWN && versionnumber != msgmailbox_VERSION)  {
	(void) fprintf(stderr, "Incompatible version of msgmailbox requested!\n");
    }
    self = (struct msgmailbox *) malloc (sizeof(struct msgmailbox));
    if (! self)  {
	(void) fprintf(stderr, "Could not allocate msgmailbox object!\n");
	return NULL;
    }
    if(!msgmailbox__Initialize(classID, self, versionnumber)){
	free((char *)self);
	return NULL;
    }
    return self;
}

void msgmailbox__Finalize(classID, self)
struct classheader *classID;
struct msgmailbox *self;
{
    msgmailbox__FinalizeObject(classID, self);
}

void msgmailbox__Destroy(classID, self)
struct classheader *classID;
struct msgmailbox *self;
{
    msgmailbox__Finalize(classID, self);
    free(self);
}

struct classinfo *msgmailbox__GetClassInfo(classID, versionnumber)
struct classheader *classID;
unsigned long versionnumber;
{
    if (versionnumber != class_VERSIONNOTKNOWN && versionnumber != msgmailbox_VERSION)  {
	(void) fprintf(stderr, "Incompatible version of msgmailbox requested!\n");
    }
    msgmailbox_classproceduretable.info = &msgmailbox_classinfo;
    return &msgmailbox_classinfo;
}

/* 
 * THIS IS NEEDED BECAUSE OF THE WAY makedo WORKS.
 * HOPEFULLY, IT CAN BE REMOVED SOON.
 */ 
 
struct classinfo *msgmlbox__GetClassInfo(classID, versionnumber)
struct classheader *classID;
unsigned long versionnumber;
{
    return msgmailbox__GetClassInfo(classID, versionnumber);
}
 
/* 
 * END OF THIS PATCH. 
 */ 
 
#endif /* AUXMODULE */
