Removed CPP interfaces added Array for counting references