package ports

import (
	"github.com/jobs-scraper/internal/dto"
	"github.com/jobs-scraper/internal/pkg/domain"
)

type JobQueries struct {
	GetJobs JobQueryHandler
}

// GetJobQuery represents the command to create a job
type GetJobQuery struct {
	Location   string             `schema:"location"`
	Keywords   string             `schema:"keywords"`
	FWT        string             `schema:"fwt"`
	Provider   domain.JobProvider `schema:"provider"`
	PageNumber int                `schema:"pageNumber"`
	PageSize   int                `schema:"pageSize"`
}

// JobQueryHandler defines the interface for handling job queries
type JobQueryHandler interface {
	Handle(query GetJobQuery) ([]dto.JobDTO, int, error)
}
