Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DbPort ¶
type DbPort interface { // SetLogger sets logging call-back function SetLogger(LogFunc func(ctx context.Context, logData *pb_logging.LogData) (*pb_logging.LoggingResult, error)) // GetUsersByFilter returns the users that match the given filter. GetUsersByFilter(ctx context.Context, userFilter me.UserFilter) (me.Users, error) // SaveUser insert a new user or update the existing one in the database. SaveUser(ctx context.Context, user me.User) (me.User, error) // DeleteUser soft-deletes the given user in the database. DeleteUser(ctx context.Context, user me.User) (me.User, error) // GetUserPasswordByUserId returns active password of the given user. GetUserPasswordByUserId(ctx context.Context, userId uuid.UUID) (me.UserPassword, error) // ChangePassword changes the poassword of the given user in the database. ChangePassword(ctx context.Context, userPassword me.UserPassword) (me.UserPassword, error) }
DbPort is a port for Hexagonal Architecture Pattern. It is used to communicate with the database.
type RedisPort ¶
type RedisPort interface { // SetLogger sets logging call-back function SetLogger(LogFunc func(ctx context.Context, logData *pb_logging.LogData) (*pb_logging.LoggingResult, error)) // DeleteUserPasswordByUserId hard-deletes the given user id in the redis. DeleteUserPasswordByUserId(ctx context.Context, userId uuid.UUID) error // GetUserPasswordByUserId returns active password of the given user. GetUserPasswordByUserId(ctx context.Context, userId uuid.UUID) (me.UserPassword, error) // ChangePassword changes the poassword of the given user in the redis. ChangePassword(ctx context.Context, userPassword me.UserPassword) error }
RedisPort is a port for Hexagonal Architecture Pattern. It is used to communicate with the redis.
Click to show internal directories.
Click to hide internal directories.