0

Having this class definition

class CefBrowser : public virtual CefBase 

How to cast from CefBrwoser * to CefBase * and reverse? assuming that both are not instanciable, they are loaded from C to CPP.

JNassim
  • 1
  • 2
  • 2
    Can you clarify how are you loading a class from C? I don't understand. – Baltasarq Jun 15 '13 at 13:31
  • They have been wrapped, from C dll, the problem is that i am upgrading the old Java wraper (2010) with the last CEF 1 (2013) but in the last version the CefBase interface become virtual, so old functions that haves CefBase * parameter can't accept derived classes any more, my first solution is to add another parameter long to send the pointer throw jni, finnally its working but i think that i should keep the question because i want to know if its possible to cast from virtual classes. i am more specialised in Java, so may be my question isn't clear – JNassim Jun 15 '13 at 14:32
  • This might be helpful - http://stackoverflow.com/questions/3747066/c-cannot-convert-from-base-a-to-derived-type-b-via-virtual-base-a – Jimbo Jun 15 '13 at 14:55

0 Answers0