C++ error ‘cannot instantiate abstract class’ when building the code of SpineBushing plugin (original for OpenSim v2.4)
Posted: Thu Dec 28, 2017 12:43 pm
Dear all,
I am trying to build a SpineBushing plugin ( https://simtk.org/projects/spinebushing). It was created for OpenSim 2.4, so I have to rebuild it for the current v3.3. However, I met errors like below. It seems that current OpenSim library does not support the old code anymore. Does anybody know what could I do. Thanks!
Error 1 error C2259: 'OpenSim::SpineBushingTest' : cannot instantiate abstract class
Error 2 error C2248: 'OpenSim::Force::copyData' : cannot access private member declared in
Error 3 error C3861: 'setType': identifier not found
Error 4 error C2039: 'setup' : is not a member of 'OpenSim::Force'
Error 5 error C2039: 'createSystem' : is not a member of 'OpenSim::Force'
6 IntelliSense: object of abstract class type "OpenSim::SpineBushingTest" is not allowed:
pure virtual function "OpenSim::Force::clone" has no overrider
pure virtual function "OpenSim::Force::getConcreteClassName" has no overrider
7 IntelliSense: function "OpenSim::Force::copyData" (declared at line 221 of "C:\OpenSim 3.3\sdk\include\OpenSim/Simulation/Model/Force.h") is inaccessible
8 IntelliSense: identifier "setType" is undefined
9 IntelliSense: class "OpenSim::Force" has no member "setup"
10 IntelliSense: class "OpenSim::Force" has no member "createSystem"
Best regards,
Echo
I am trying to build a SpineBushing plugin ( https://simtk.org/projects/spinebushing). It was created for OpenSim 2.4, so I have to rebuild it for the current v3.3. However, I met errors like below. It seems that current OpenSim library does not support the old code anymore. Does anybody know what could I do. Thanks!
Error 1 error C2259: 'OpenSim::SpineBushingTest' : cannot instantiate abstract class
Error 2 error C2248: 'OpenSim::Force::copyData' : cannot access private member declared in
Error 3 error C3861: 'setType': identifier not found
Error 4 error C2039: 'setup' : is not a member of 'OpenSim::Force'
Error 5 error C2039: 'createSystem' : is not a member of 'OpenSim::Force'
6 IntelliSense: object of abstract class type "OpenSim::SpineBushingTest" is not allowed:
pure virtual function "OpenSim::Force::clone" has no overrider
pure virtual function "OpenSim::Force::getConcreteClassName" has no overrider
7 IntelliSense: function "OpenSim::Force::copyData" (declared at line 221 of "C:\OpenSim 3.3\sdk\include\OpenSim/Simulation/Model/Force.h") is inaccessible
8 IntelliSense: identifier "setType" is undefined
9 IntelliSense: class "OpenSim::Force" has no member "setup"
10 IntelliSense: class "OpenSim::Force" has no member "createSystem"
Best regards,
Echo