Add pointer code to class example