pass user defined clas to velicoty; the class should be public