Created
August 3, 2012 00:08
-
-
Save smaldini/3242409 to your computer and use it in GitHub Desktop.
test
This file contains 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 SomeController{ | |
def testInlineListener = { | |
//register with 'logout' topic on 'app' default namespace | |
def listener = on("logout") {User user -> | |
println "test $user" | |
} | |
render "$listener registered" | |
} | |
def testInlineListener2 = { | |
//register a 'gorm' namespaced handler on 'afterInsert' topic. | |
def listener = on("gorm", "afterInsert") {Book book -> | |
println "test $book" | |
} | |
render "$listener registered" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment