summaryrefslogtreecommitdiff
path: root/helpers.go
diff options
context:
space:
mode:
Diffstat (limited to 'helpers.go')
-rw-r--r--helpers.go9
1 files changed, 9 insertions, 0 deletions
diff --git a/helpers.go b/helpers.go
index 618bec1..6bbb1f7 100644
--- a/helpers.go
+++ b/helpers.go
@@ -42,3 +42,12 @@ func (p *Packages) Unmarshal(data []byte) error {
return proto.Unmarshal(data, p)
}
+// marshal to wire
+func (m *Machine) Marshal() ([]byte, error) {
+ return proto.Marshal(m)
+}
+
+// unmarshal from wire
+func (m *Machine) Unmarshal(data []byte) error {
+ return proto.Unmarshal(data, m)
+}