Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Repository ¶
type Repository interface { Create(user *model.UserModel) (*model.UserModel, error) Find() ([]*model.UserModel, error) FindByID(id string) (*model.UserModel, error) Update(user *model.UserModel, id string) (*model.UserModel, error) Delete(id string) error }
Repository represent the repositories
func NewCassandraRepository ¶
func NewCassandraRepository(sess *gocql.Session) Repository
NewCassandraRepository will create an object that represent the Repository interface
type Service ¶
type Service interface { Create(user *form.UserForm) (*model.UserModel, int, error) Find() ([]*model.UserModel, int, error) FindByID(id string) (*model.UserModel, int, error) Update(user *form.UserForm, id string) (*model.UserModel, int, error) Delete(id string) (int, error) }
Service represent the services
func NewService ¶
func NewService(log *logrus.Entry, r Repository) Service
NewService will create an object that represent the Service interface
Click to show internal directories.
Click to hide internal directories.