change temp code to use new obj-oriented interface