From: Christos KK Loverdos Date: Thu, 24 May 2012 12:48:57 +0000 (+0300) Subject: Add a debugging aid in API of external event model X-Git-Url: https://code.grnet.gr/git/aquarium/commitdiff_plain/a4ae6088354ab33f43e4c69032602d0e91853fca?ds=sidebyside Add a debugging aid in API of external event model --- diff --git a/src/main/scala/gr/grnet/aquarium/event/model/ExternalEventModel.scala b/src/main/scala/gr/grnet/aquarium/event/model/ExternalEventModel.scala index fff46b9..4530a7a 100644 --- a/src/main/scala/gr/grnet/aquarium/event/model/ExternalEventModel.scala +++ b/src/main/scala/gr/grnet/aquarium/event/model/ExternalEventModel.scala @@ -36,6 +36,7 @@ package gr.grnet.aquarium.event.model import gr.grnet.aquarium.util.makeBytes +import gr.grnet.aquarium.util.shortClassNameOf import gr.grnet.aquarium.util.json.JsonSupport import gr.grnet.aquarium.util.xml.XmlSupport @@ -57,6 +58,8 @@ trait ExternalEventModel extends EventModel with JsonSupport with XmlSupport { def toBytes: Array[Byte] = makeBytes(toJsonString) def withReceivedMillis(newReceivedMillis: Long): ExternalEventModel + + def toDebugString = "%s(userID=%s, id=%s)".format(shortClassNameOf(this), userID, id) } object ExternalEventModel {