package subscribeplanrepository

import (
	"legalgo-BE-go/database"
	subscribeplandomain "legalgo-BE-go/internal/domain/subscribe_plan"
)

type accessor struct {
	db *database.DB
}

type SubscribePlan interface {
	Create(subscribeplandomain.SubscribePlan) error
	GetAll() ([]subscribeplandomain.SubscribePlan, error)
	GetByID(string) (*subscribeplandomain.SubscribePlan, error)
	GetDefault() (*subscribeplandomain.SubscribePlan, error)
	Update(subscribeplandomain.SubscribePlan) error
	Delete(string) error
}

func New(
	db *database.DB,
) SubscribePlan {
	return &accessor{db}
}
