Documentation ¶
Index ¶
- Variables
- type Article
- type FetchIter
- type Group
- type Part
- type Rover
- func (r *Rover) AddSink(sink Sink)
- func (r *Rover) Close()
- func (r *Rover) Do(expectCode int, format string, args ...interface{}) (string, error)
- func (r *Rover) Fetch(articleId ...int) ([]Article, error)
- func (r *Rover) FetchIter(articleId ...int) (*FetchIter, error)
- func (r *Rover) Group() string
- func (r *Rover) ParseArticle(line string) (Article, error)
- func (r *Rover) ReadProgress() int
- func (r *Rover) RemoveSink(sink Sink)
- func (r *Rover) SaveProgress(article int)
- func (r *Rover) Serve() error
- func (r *Rover) SetLogger(logger *log.Logger)
- func (r *Rover) Stop()
- func (r *Rover) SwitchGroup(group string) (Group, error)
- type RoverConfig
- type Sink
- type StdSink
- type YencDecoder
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrBadYenc error = fmt.Errorf("Only recieved bad Yencs.")
Functions ¶
This section is empty.
Types ¶
type Article ¶
type Part ¶
type Part struct {
Crc32, PartCrc32, ExpectedCrc32 uint32
LineSize uint32
TotalSize, PartSize uint32
Part, Total uint32
Begin, End uint32
Name string
Body []byte
}
func (*Part) ValidPartCrc ¶
type Rover ¶
type Rover struct {
// contains filtered or unexported fields
}
func NewRoverSsl ¶
func NewRoverSsl(addr string, conf RoverConfig) (*Rover, error)
func (*Rover) ReadProgress ¶
func (*Rover) RemoveSink ¶
func (*Rover) SaveProgress ¶
type RoverConfig ¶
type RoverConfig struct { Host string `json:"host"` SSL bool `json:"use_ssl"` Group string `json:"newsgroup"` AuthUser string `json:"auth_user"` AuthPass string `json:"auth_pass"` CheckEvery int `json:"check_every"` FlushEvery int `json:"flush_articles_every"` MaxArticles int `json:"max_buffered_articles"` StartAt int `json:"start_at_article"` StopAt int `json:"no_article_to_process"` Progress string `json:"progress"` }
type YencDecoder ¶
type YencDecoder struct {
// contains filtered or unexported fields
}
func NewYencDecoder ¶
func NewYencDecoder(reader io.Reader) *YencDecoder
func (*YencDecoder) Decode ¶
func (d *YencDecoder) Decode() (*Part, error)
Click to show internal directories.
Click to hide internal directories.