I have a function like this:

```
void something(void *obj)
{
    obj->Set();
}

```

The compiler says that left of the dereference operator has to be a pointer to a class/struct/union/generic (translated from german not sure about wording).

The idea is that I want to call the `something` function of obj no matter what is passed to `something`. It is ensured that it has this function. How can i achieve that?

--EDIT--

I started to work on an existing Software which has like > 100 Classes for datatypes. In one part of the code there is a big switch statement which depending on an id creates an instance of one of these classes and calls the Set function for that one. Now i want to do multiple of these calls parallel, and because of this i want to bring the ->Set() call to a seperate function which i then can call in a new thread. Sadly there is no baseclass and i cant change too much in the "big picture". What is the best way to do this?