home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.umcs.maine.edu
/
2015-02-07.ftp.umcs.maine.edu.tar
/
ftp.umcs.maine.edu
/
pub
/
thesis
/
zhongy
/
rule
/
rule.h
< prev
next >
Wrap
C/C++ Source or Header
|
1994-12-14
|
2KB
|
68 lines
#ifndef RULE_H
#define RULE_H
#include "object.h"
/* operation for Premise */
#define EQUAL_STR 1
#define EQUAL_INT 2
#define BIGGER 3
#define LESSER 4
class PremiseType{
private:
int operation;
ObjectType *IN_Object;
ObjectValueType IN_Value; /*op code EQUAL_STR*/
int int_val; /*op code EQUAL_INT, BIGGER, LESSER*/
PremiseType *IN_Next;
public:
void set_Object(ObjectType *Obj);
void set_Value(char *Obj_Value);
void set_Next(PremiseType *Next_Obj);
void set_Operation(int oper);
void set_Int(int val);
ObjectType *Object();
char *Value();
PremiseType *Next();
int Op();
int INT_Value();
};
class ConclusionType{
private:
ObjectType *IN_Object;
ObjectValueType IN_Value;
public:
void set_Object(ObjectType *Obj);
void set_Value(char *Obj_Value);
ObjectType *Object();
char *Value();
};
class RuleType{
private:
RuleNameType IN_Name;
PremiseType *IN_Premise;
ConclusionType *IN_Conclusion;
RuleType *IN_Next;
public:
void set_Name(char *Rule_Name);
void set_Premise(PremiseType *PremisePtr);
void set_Conclusion(ConclusionType *ConclusionPtr);
void set_Next(RuleType *Next_Rule);
char *Name();
PremiseType *Premise();
ConclusionType *Conclusion();
RuleType *Next();
};
#endif