Expanding on Properties

robbyoconnor's picture

It it worth nothing that in groovy, properties already exist. let’s give an example:


class Book {
String title;
}
def gina = new Book();
gina.title = "Groovy In Action";
println gina.title;

Groovy basically generates the getters/setters behind the scenes, but in essence these are for all intensive purposes — properties. I felt that this needed to be addressed.

Organization: OpenMRS Original: Source