bookmarks/cheat/groovy.md
2018-03-13 19:17:13 +01:00

217 B

List class methods

<class>.metaClass.methods*.name.sort().unique()

Example

println new Person().metaClass.methods*.name.sort().unique()

Source http://groovy-almanac.org/list-the-methods-of-a-groovy-class/