github.com/cs3org/reva/v2@v2.27.7/pkg/events/sse.go (about) 1 package events 2 3 import ( 4 "encoding/json" 5 ) 6 7 // SendSSE instructs the sse service to send one or multiple notifications 8 type SendSSE struct { 9 UserIDs []string 10 Type string 11 Message []byte 12 } 13 14 // Unmarshal to fulfill umarshaller interface 15 func (SendSSE) Unmarshal(v []byte) (interface{}, error) { 16 e := SendSSE{} 17 err := json.Unmarshal(v, &e) 18 return e, err 19 }