Extend the c++ stpm2 class to include links etc for generalisation