github.com/GeniusesGroup/libgo@v0.0.0-20220929090155-5ff932cb408e/srpc/frame-ping.go (about)

     1  /* For license and copyright information please see LEGAL file in repository */
     2  
     3  package srpc
     4  
     5  import "../syllab"
     6  
     7  /*
     8  type pingFrame struct {
     9  	ID int64 // Usually unix time
    10  }
    11  */
    12  type pingFrame []byte
    13  
    14  func (f pingFrame) ID() int64         { return syllab.GetInt64(f, 0) }
    15  func (f pingFrame) NextFrame() []byte { return f[8:] }