phrase

package
Version: v0.0.0-...-3051362 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2020 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

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

Types

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

Jump to

Keyboard shortcuts

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