Added implementation for addData