Add dispose method.