Commit b5a7a5cd authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent c93753be
...@@ -472,3 +472,15 @@ func (p *StoreObject) NEODecode(data []byte) (int, error) { ...@@ -472,3 +472,15 @@ func (p *StoreObject) NEODecode(data []byte) (int, error) {
p.Unlock = bool((data[16:])[0]) p.Unlock = bool((data[16:])[0])
return 17 /* + TODO variable part */, nil return 17 /* + TODO variable part */, nil
} }
func (p *AnswerStoreObject) NEODecode(data []byte) (int, error) {
p.Conflicting = bool((data[0:])[0])
p.Oid = BigEndian.Uint64(data[1:])
p.Serial = BigEndian.Uint64(data[9:])
return 17 /* + TODO variable part */, nil
}
func (p *AbortTransaction) NEODecode(data []byte) (int, error) {
p.Tid = BigEndian.Uint64(data[0:])
return 8 /* + TODO variable part */, nil
}
...@@ -431,7 +431,6 @@ type StoreObject struct { ...@@ -431,7 +431,6 @@ type StoreObject struct {
Unlock bool Unlock bool
} }
/*
type AnswerStoreObject struct { type AnswerStoreObject struct {
Conflicting bool Conflicting bool
Oid Oid Oid Oid
...@@ -443,6 +442,7 @@ type AbortTransaction struct { ...@@ -443,6 +442,7 @@ type AbortTransaction struct {
Tid Tid Tid Tid
} }
/*
// Ask to store a transaction. C -> S. // Ask to store a transaction. C -> S.
// Answer if transaction has been stored. S -> C. // Answer if transaction has been stored. S -> C.
type StoreTransaction struct { type StoreTransaction struct {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment