Jiri Simsa | 756772c | 2015-03-25 15:40:54 -0700 | [diff] [blame] | 1 | // Copyright 2015 The Vanadium Authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style |
| 3 | // license that can be found in the LICENSE file. |
| 4 | |
Benjamin Prosnitz | 809246c | 2014-10-29 14:24:11 -0700 | [diff] [blame] | 5 | package channel |
| 6 | |
| 7 | type Request struct { |
Todd Wang | bb6afc0 | 2014-11-21 11:24:20 -0800 | [diff] [blame] | 8 | Type string |
Benjamin Prosnitz | 86d5228 | 2014-12-19 15:48:38 -0800 | [diff] [blame] | 9 | Seq uint32 |
Todd Wang | bb6afc0 | 2014-11-21 11:24:20 -0800 | [diff] [blame] | 10 | Body any |
Benjamin Prosnitz | 809246c | 2014-10-29 14:24:11 -0700 | [diff] [blame] | 11 | } |
| 12 | |
| 13 | type Response struct { |
Benjamin Prosnitz | 86d5228 | 2014-12-19 15:48:38 -0800 | [diff] [blame] | 14 | ReqSeq uint32 |
Todd Wang | bb6afc0 | 2014-11-21 11:24:20 -0800 | [diff] [blame] | 15 | Err string // TODO(bprosnitz) change this back to error when it is possible to do so. (issue 368) |
| 16 | Body any |
Benjamin Prosnitz | 809246c | 2014-10-29 14:24:11 -0700 | [diff] [blame] | 17 | } |
| 18 | |
Todd Wang | b5f66fa | 2014-12-17 18:16:49 -0800 | [diff] [blame] | 19 | type Message union { |
Todd Wang | bb6afc0 | 2014-11-21 11:24:20 -0800 | [diff] [blame] | 20 | Request Request |
| 21 | Response Response |
| 22 | } |