What does this means

node* next;
is this means we can take class name as datatype for pointer

yes u can take pointers to class member functions and member variables.

class Simple
{
    public:
    int a;
};

int main()
{
    Simple obj;
    Simple* ptr;   // Pointer of class type
    ptr = &obj;
 
    cout << obj.a;
    cout << ptr->a;  // Accessing member with pointer
}