Object-oriented programming sample code.