This commit is contained in:
bandl 2021-11-29 23:46:09 +08:00
parent f62a59b551
commit ef4cbb0cee
1 changed files with 2 additions and 2 deletions

View File

@ -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