Wednesday, December 27, 2006
DataObject, DataClass, ProcessorClass, ProcessorObject implementation.
//***************************************************************************
// Title: Data object entity prototype code.
//
// status: Under development.
//
// 1. Data Type Design (Class)
// - Can exploit YanneDesigner source code.
// 2. Data Object Entity (Object)
// - Name and Type where Type points to Data Type Design entity.
//
// comment:
// It is temporary implementation for test purpose. Real implementation
// will be derived class of "Info" class which is base class for infor-
// mation attached to Node and Edge of Graph structure.
//
class YanneDataObject
{
public:
// Constructor and destructor.
YanneDataObject(string a_sObjName, string a_sTypeName)
{
setTypeName(a_sTypeName);
setObjName(a_sObjName);
}
~YanneDataObject(void)
{
// Currently nothing to delete.
}
// Data manipulation methods.
void setObjName(string a_sObjName) { m_sObjName = a_sObjName; }
string getObjName(void) { return m_sObjName; }
void setTypeName(string a_sTypeName) { m_sTypeName = a_sTypeName; }
string getTypeName(void) { return m_sTypeName; }
void setComment(string a_sComment) { m_sComment = a_sComment; }
string getComment(void) { return m_sComment; }
// for debugging.
void print(void)
{
cout << "[object name: " << getObjName() << ", typename: " << getTypeName() << "]" << endl;
}
private:
string m_sObjName; // Object name.
string m_sTypeName; // Data type(class) name.
string m_sComment; // Explanation on the data object.
};
//***************************************************************************
// Title: Data class entity prototype code.
//
// status: Under development.
//
// 1. Data Type Design (Class)
// - Can exploit YanneDesigner source code.
// 2. Data Object Entity (Object)
// - Name and Type where Type points to Data Type Design entity.
//
// comment:
// It is temporary implementation for test purpose. Real implementation
// will be derived class of "Info" class which is base class for infor-
// mation attached to Node and Edge of Graph structure.
//
class YanneDataClass
{
public:
// Constructor and destructor.
YanneDataClass(string a_sClassName)
{
setClassName(a_sClassName);
}
~YanneDataClass(void)
{
// Currently nothing to delete.
}
// Data manipulation methods.
void setClassName(string a_sClassName) { m_sClassName = a_sClassName; }
string getClassName(void) { return m_sClassName; }
void setComment(string a_sComment) { m_sComment = a_sComment; }
string getComment(void) { return m_sComment; }
// for debugging.
void print(void)
{
cout << "[class name: " << getClassName() << "]" << endl;
}
private:
string m_sClassName; // Class name.
string m_sComment; // Explanation on the class.
};
//***************************************************************************
// Title: Processor object entity prototype code.
//
// status: Under development.
//
// 1. Processor class design.
// - Can exploit YanneDesigner source code.
// 2. Processor object entity.
// - Name and Type where Type points to Processor Class design entity.
//
// comment:
// It is temporary implementation for test purpose. Real implementation
// will be derived class of "Info" class which is base class for infor-
// mation attached to Node and Edge of Graph structure.
//
class YanneProcessorObject
{
public:
// Constructor and destructor.
YanneProcessorObject(string a_sObjName, string a_sTypeName)
{
setTypeName(a_sTypeName);
setObjName(a_sObjName);
}
~YanneProcessorObject(void)
{
// Currently nothing to delete.
}
// Data manipulation methods.
void setObjName(string a_sObjName) { m_sObjName = a_sObjName; }
string getObjName(void) { return m_sObjName; }
void setTypeName(string a_sTypeName) { m_sTypeName = a_sTypeName; }
string getTypeName(void) { return m_sTypeName; }
void setComment(string a_sComment) { m_sComment = a_sComment; }
string getComment(void) { return m_sComment; }
// for debugging.
void print(void)
{
cout << "[object name: " << getObjName() << ", typename: " << getTypeName() << "]" << endl;
}
private:
string m_sObjName; // Processor object name.
string m_sTypeName; // Processor class name.
string m_sComment; // Explanation on the processor object.
};
//***************************************************************************
// Title: Processor object entity prototype code.
//
// status: Under development.
//
// 1. Processor class design.
// - Can exploit YanneDesigner source code.
// 2. Processor object entity.
// - Name and Type where Type points to Processor Class design entity.
//
// comment:
// It is temporary implementation for test purpose. Real implementation
// will be derived class of "Info" class which is base class for infor-
// mation attached to Node and Edge of Graph structure.
//
class YanneProcessorClass
{
public:
// Constructor and destructor.
YanneProcessorClass(string a_sClassName)
{
setClassName(a_sClassName);
}
~YanneProcessorClass(void)
{
// Currently nothing to delete.
}
// Data manipulation methods.
void setClassName(string a_sClassName) { m_sClassName = a_sClassName; }
string getClassName(void) { return m_sClassName; }
void setComment(string a_sComment) { m_sComment = a_sComment; }
string getComment(void) { return m_sComment; }
// for debugging.
void print(void)
{
cout << "[class name: " << getClassName() << "]" << endl;
}
string m_sClassName; // Class name.
string m_sComment; // Explanation on the class.
};