demote NewStream

This commit is contained in:
sm
2014-03-02 22:47:28 -08:00
parent ecace73aed
commit ae82433a8f
3 changed files with 11 additions and 9 deletions
+4 -4
View File
@@ -1,4 +1,4 @@
package main
package bandwidth
import (
"container/list"
@@ -29,7 +29,7 @@ type stream struct {
max time.Duration
}
func NewStream(seconds []int) *stream {
func newStream(seconds []int) *stream {
extents := []time.Duration{}
for _, s := range seconds {
extents = append(extents, time.Duration(-s)*time.Second)
@@ -113,8 +113,8 @@ func NewBandwidth(seconds []int, dt time.Duration) (*Bandwidth, error) {
Tx: make(chan []float64),
dt: dt,
Quit: make(chan interface{}),
rxstream: NewStream(seconds),
txstream: NewStream(seconds),
rxstream: newStream(seconds),
txstream: newStream(seconds),
}
return r, nil
}