tags:

views:

37

answers:

1

The following code sets a private method. So how private really is private?

public class Person {
 private String name
}

def u = new Person(name:"Ron")
println u.name
+2  A: 

By design Groovy should respect the private modifier, however the current implementation takes no account of it. You can find further details in the following Jira entries:

There are also further details in this question.

mfloryan