MCPcopy Create free account
hub / github.com/LagrangeDev/LagrangeGo / ElementsHasType

Function ElementsHasType

message/message.go:633–640  ·  view source on GitHub ↗
(elems []IMessageElement, t ElementType)

Source from the content-addressed store, hash-verified

631}
632
633func ElementsHasType(elems []IMessageElement, t ElementType) bool {
634 for _, elem := range elems {
635 if elem.Type() == t {
636 return true
637 }
638 }
639 return false
640}
641
642func PackElementsToBody(msgElems []IMessageElement) (msgBody *message.MessageBody) {
643 msgBody = &message.MessageBody{

Callers

nothing calls this directly

Calls 1

TypeMethod · 0.65

Tested by

no test coverage detected