| 12345678910111213141516171819 |
- class GroovyExtensions {
- static void apply() {
- List.metaClass {
- findQuotedElement = { Map<String, String> conditions ->
- delegate.find { element ->
- conditions.every { condition, value -> element[condition] == value }
- }
- }
- findQuotedElements = { Map<String, String> conditions ->
- delegate.findAll { element ->
- conditions.every { condition, value -> element[condition] == value }
- }
- }
- }
- }
- }
|