Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Article ¶
type Article struct {
MessageID string
Subject string
From string
Date time.Time
Body []byte
Bytes int
Group string
PartNumber int
TotalParts int
FileName string
}
func NewArticle ¶
type Post ¶
type Post struct {
FilePath string
Articles []article.Article
Status PostStatus
Error error
Retries int
// contains filtered or unexported fields
}
Post represents a file to be posted
type PostStatus ¶
type PostStatus int
PostStatus represents the status of a post
const ( PostStatusPending PostStatus = iota PostStatusPosted PostStatusVerified PostStatusFailed )
type Poster ¶
type Poster interface {
// Post posts files from a directory to Usenet
Post(ctx context.Context, files []string, rootDir string, outputDir string) error
// GetStats returns posting statistics
GetStats() Stats
}
Poster defines the interface for posting articles to Usenet
type ProgressManager ¶
type ProgressManager struct {
// contains filtered or unexported fields
}
ProgressManager handles progress tracking and display
func NewFileProgress ¶
func NewFileProgress( description string, totalBytes int64, articlesTotal int64, ) *ProgressManager
NewFileProgress creates a new progress bar for a file
func (*ProgressManager) FinishFileProgress ¶
func (pm *ProgressManager) FinishFileProgress()
FinishFileProgress completes the progress bar for a file
func (*ProgressManager) UpdateFileProgress ¶
func (pm *ProgressManager) UpdateFileProgress(bytesProcessed int64, articlesProcessed int64, articleErrors int64)
UpdateFileProgress updates the progress bar for a file
Click to show internal directories.
Click to hide internal directories.