Files
go-sam-go/stream.go

30 lines
415 B
Go
Raw Normal View History

2025-02-23 18:01:43 -05:00
package sam3
import (
"time"
"github.com/go-i2p/go-sam-go/stream"
)
// Represents a streaming session.
type StreamSession struct {
*stream.StreamSession
}
/*
func (s *StreamSession) Cancel() chan *StreamSession {
ch := make(chan *StreamSession)
ch <- s
return ch
}*/
func minNonzeroTime(a, b time.Time) time.Time {
if a.IsZero() {
return b
}
if b.IsZero() || a.Before(b) {
return a
}
return b
}