Register model library in C++