Added objects and methods, final version.