service

package
v0.0.0-...-f3969ab Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RecordService

type RecordService interface {
	CreateRecord(*pb.CreateRecordRequest) (*pb.CreateRecordResponse, error)
	GetOriginUrl(*pb.GetOriginUrlRequest) (*pb.GetOriginUrlResponse, error)
}

func CreateRecordServiceWith

func CreateRecordServiceWith(
	recordRepository repository.RecordRepository,
	logger *logrus.Logger,
) RecordService

type UrlService

type UrlService interface {
	GetOriginUrl(shortenedId string) (*string, *pb.RecordStatus, error)
	CreateRecord(originUrl string, expireAt time.Time) (*string, error)
}

func CreateUrlServiceWith

func CreateUrlServiceWith(
	urlRepository repository.UrlRepository,
	logger *logrus.Logger,
) UrlService

Jump to

Keyboard shortcuts

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