I'm trying to write an interface such as...
interface MyInterface
{
MyObject Set(REGISTER register, PIN pin);
}
Both REGISTER and PIN are enums. The problem I'm running into is that REGISTER is defined in my MyBaseClass and PIN is defined in MyDerivedClass. I can live with using something like MyBaseClass.REGISTER in the interface, but that won't work for PIN. Every derivation of MyBaseClass will have a different enumeration for PIN. I found this other answer on SO, which seems to partially solve the problem, but it's not clear how I should then implement the function in MyDerivedClass. Does anyone have a solution for this?