mirror of
https://github.com/nspcc-dev/neo-go.git
synced 2024-11-27 03:58:06 +00:00
19 lines
452 B
Go
19 lines
452 B
Go
package consensus
|
|
|
|
import "github.com/CityOfZion/neo-go/pkg/io"
|
|
|
|
// changeView represents dBFT ChangeView message.
|
|
type changeView struct {
|
|
NewViewNumber byte
|
|
Timestamp uint32
|
|
}
|
|
|
|
// EncodeBinary implements io.Serializable interface.
|
|
func (c *changeView) EncodeBinary(w *io.BinWriter) {
|
|
w.WriteLE(c.Timestamp)
|
|
}
|
|
|
|
// DecodeBinary implements io.Serializable interface.
|
|
func (c *changeView) DecodeBinary(r *io.BinReader) {
|
|
r.ReadLE(&c.Timestamp)
|
|
}
|