In Java, there is a generic class called \"Object\", in which all classes are a subclass of. I am trying to make a linked list library (for a school project), and I have managed
class Object{
protected:
void * Value;
public:
template
void operator = (Type Value){
this->Value = (void*)Value;
}
template <>
void operator = (string Value){
this->Value = (void*)Value.c_str();
}
template
bool operator == (Type Value2){
return (int)(void*)Value2==(int)(void*)this->Value;
}
template<>
bool operator ==
Then make a subclass of it