github.com/Mrs4s/go-cqhttp@v1.2.0/internal/msg/local.go (about) 1 package msg 2 3 import ( 4 "io" 5 6 "github.com/Mrs4s/MiraiGo/message" 7 ) 8 9 // Poke 拍一拍 10 type Poke struct { 11 Target int64 12 } 13 14 // Type 获取元素类型ID 15 func (e *Poke) Type() message.ElementType { 16 // Make message.IMessageElement Happy 17 return message.At 18 } 19 20 // LocalImage 本地图片 21 type LocalImage struct { 22 Stream io.ReadSeeker 23 File string 24 URL string 25 26 Flash bool 27 EffectID int32 28 } 29 30 // Type implements the message.IMessageElement. 31 func (e *LocalImage) Type() message.ElementType { 32 return message.Image 33 } 34 35 // LocalVideo 本地视频 36 type LocalVideo struct { 37 File string 38 Thumb io.ReadSeeker 39 } 40 41 // Type impl message.IMessageElement 42 func (e *LocalVideo) Type() message.ElementType { 43 return message.Video 44 }