Add copy util function.