Implement callback on C++ level.