Car c= new Car(log); c.print() class Car{ def log public Car(log){ this.log=log } public void print(){ log.info "hello world" } }