Back to

Package phrase

Latest Go to latest

The highest tagged major version is .

Published: Jun 19, 2020 | License: MIT | Module:


func DeletePhraseForCharacter

func DeletePhraseForCharacter(c *gin.Context)

func GetAllPhrasesForCharacter

func GetAllPhrasesForCharacter(c *gin.Context)

GetAllPhrasesForCharacter returns all phrases for a character wrapped in a json object

func GetPhrase

func GetPhrase(c *gin.Context)

func Initialize

func Initialize(phRepo repository.PhraseRepository)

func SaveNewPhrase

func SaveNewPhrase(c *gin.Context)

SaveNewPhrase saves a new phrase for the specified character

type DBPhraseRepository

type DBPhraseRepository struct {
	// contains filtered or unexported fields

func NewDBPhraseRepository

func NewDBPhraseRepository(db *gorm.DB) DBPhraseRepository

func (DBPhraseRepository) Delete

func (repo DBPhraseRepository) Delete(c *gin.Context, characterId int64, id int64) error

func (DBPhraseRepository) Get

func (repo DBPhraseRepository) Get(c *gin.Context, characterId int64, id int64) (model.Phrase, bool, error)

func (DBPhraseRepository) GetAllForCharacter

func (repo DBPhraseRepository) GetAllForCharacter(c *gin.Context, characterId int64) ([]model.Phrase, bool, error)

func (DBPhraseRepository) Save

func (repo DBPhraseRepository) Save(c *gin.Context, phCmd model.PhraseCommand) (model.Phrase, error)

Package Files

Documentation was rendered with GOOS=linux and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to identifier