fix comments

This commit is contained in:
Leonard Lyubich 2020-05-11 17:44:59 +03:00
parent e01fb0cc62
commit b2543c0739
2 changed files with 4 additions and 0 deletions

View file

@ -122,10 +122,12 @@ func (m *Request) SetInfo(info NodeInfo) {
m.Info = info
}
// Size returns the size necessary for a binary representation of the state.
func (x Request_State) Size() int {
return 4
}
// Bytes returns a binary representation of the state.
func (x Request_State) Bytes() []byte {
data := make([]byte, x.Size())

View file

@ -22,10 +22,12 @@ func (nt NodeRole) String() string {
}
}
// Size returns the size necessary for a binary representation of the NodeRole.
func (nt NodeRole) Size() int {
return 4
}
// Bytes returns a binary representation of the NodeRole.
func (nt NodeRole) Bytes() []byte {
data := make([]byte, nt.Size())