This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class BarMixin { | |
| } | |
| Date.mixin(BarMixin) | |
| 100.times { | |
| println "#${it + 1}" | |
| def bar = new Date() | |
| bar.toString() | |
| sleep 100 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public String convertToString(GPathResult doc) { | |
| def defaultNamespace = doc.lookupNamespace('') | |
| if (defaultNamespace) { | |
| def docWithNamespace = { | |
| mkp.declareNamespace("": defaultNamespace) | |
| out << doc | |
| } | |
| return new StreamingMarkupBuilder().bind(docWithNamespace) | |
| } else { |