topics

package
v0.0.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 1, 2025 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MapCreateTopicPrototypeToDomain

func MapCreateTopicPrototypeToDomain(topic *desc.CreateTopicsRequest_TopicPrototype) models.Topic

func MapDomainTopicToProto

func MapDomainTopicToProto(topic models.Topic) *desc.Topic

func MapUpdateTopicPrototypeToUpdatedTopic

func MapUpdateTopicPrototypeToUpdatedTopic(topic *desc.UpdateTopicsRequest_TopicPrototype) (models.UpdatedTopic, error)

Types

type Implementation

type Implementation struct {
	desc.UnimplementedTopicServiceServer
	// contains filtered or unexported fields
}

func New

func New(topicService TopicService) *Implementation

func (*Implementation) CreateTopics

func (*Implementation) DeleteTopics

func (*Implementation) GetTopics

func (*Implementation) UpdateTopics

type TopicService

type TopicService interface {
	GetTopics(ctx context.Context, ids []int64) ([]models.Topic, error)
	InsertTopics(ctx context.Context, tasks []models.Topic) ([]int64, error)
	UpdateTopics(ctx context.Context, tasks []models.UpdatedTopic) error
	DeleteTopics(ctx context.Context, ids []int64) error
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL