package main

import "golang.org/x/time/rate"

type Task struct {
	Idx *PageUsers
	cli *Client
}

func NewTask() *Task {
	p := NewPageUsers(NewIdx([]UserTask{}))

	return &Task{
		Idx: p,
	}
}

type LikingUserTask struct {
	task        *Task
	taskId      string
	Ratelimiter *rate.Limiter // 需要和单个或两个的cli rate limit一致；
}

func NewLikingTask() {

}

func (l *LikingUserTask) Request() {
	users, err := l.task.Idx.Request("", "", l.task.cli.TweetLikingUsers)

	_, _ = users, err
}

type RetweeterTask struct {
	task        *Task
	taskId      string
	Ratelimiter *rate.Limiter // 需要和单个或两个的cli rate limit一致；
}

func NewRetweeterTask() {

}

func (r *RetweeterTask) Request() {
	users, err := r.task.Idx.Request("", "", r.task.cli.TweetLikingUsers)
	_, _ = users, err
}
