fixed C++ interface errors
tweaked to match new documentation