tags:

views:

37

answers:

1

I used following code.

class Bike{
 def manufacturer;

 private getManufacturer(){
  manufacturer
 }

}

But I was able invoke getter method from another class.

+1  A: 

You can't using the private modifier. This is scheduled for Groovy 2.0 I believe

Related questions:

tim_yates