Skip to content

Instantly share code, notes, and snippets.

@lankydan
Created May 15, 2019 10:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lankydan/8a8cb0c69be6ba68af697faadb91de65 to your computer and use it in GitHub Desktop.
Save lankydan/8a8cb0c69be6ba68af697faadb91de65 to your computer and use it in GitHub Desktop.
Verifying transactions with csv attachments - message contract
class MessageContract : Contract {
interface Commands : CommandData {
class Send(attachmentId: AttachmentId) : CommandWithAttachmentId(attachmentId), Commands
}
abstract class CommandWithAttachmentId(val attachmentId: AttachmentId) : CommandData {
override fun equals(other: Any?) = other?.javaClass == javaClass
override fun hashCode() = javaClass.name.hashCode()
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment