diff --git a/pkg/structure/channelx/channelx.go b/pkg/structure/channelx/channelx.go index 63235f8..d83bbdf 100644 --- a/pkg/structure/channelx/channelx.go +++ b/pkg/structure/channelx/channelx.go @@ -11,7 +11,7 @@ type ChannelX struct { sizeByte int64 } -func MakeChannelX(length int) *ChannelX { +func MakeChannelX(length int) structure.ChannelXInterface { return &ChannelX{ channel: make(chan *structure.Value, length), sizeByte: 0, @@ -58,7 +58,7 @@ func (c *ChannelX) Length() int { return len(c.channel) } -func (c *ChannelX) CLean() structure.UpdateLength { +func (c *ChannelX) Clean() structure.UpdateLength { c.channel = make(chan *structure.Value, cap(c.channel)) up := c.sizeByte c.sizeByte = 0