// Code generated by goctl. DO NOT EDIT.
// goctl 1.10.1
// Source: users.proto

package server

import (
	"context"

	"juwan-backend/app/users/rpc/internal/logic"
	"juwan-backend/app/users/rpc/internal/svc"
	"juwan-backend/app/users/rpc/pb"
)

type UsercenterServer struct {
	svcCtx *svc.ServiceContext
	pb.UnimplementedUsercenterServer
}

func NewUsercenterServer(svcCtx *svc.ServiceContext) *UsercenterServer {
	return &UsercenterServer{
		svcCtx: svcCtx,
	}
}

// -----------------------users-----------------------
func (s *UsercenterServer) AddUsers(ctx context.Context, in *pb.AddUsersReq) (*pb.AddUsersResp, error) {
	l := logic.NewAddUsersLogic(ctx, s.svcCtx)
	return l.AddUsers(in)
}

func (s *UsercenterServer) UpdateUsers(ctx context.Context, in *pb.UpdateUsersReq) (*pb.UpdateUsersResp, error) {
	l := logic.NewUpdateUsersLogic(ctx, s.svcCtx)
	return l.UpdateUsers(in)
}

func (s *UsercenterServer) DelUsers(ctx context.Context, in *pb.DelUsersReq) (*pb.DelUsersResp, error) {
	l := logic.NewDelUsersLogic(ctx, s.svcCtx)
	return l.DelUsers(in)
}

func (s *UsercenterServer) GetUsersById(ctx context.Context, in *pb.GetUsersByIdReq) (*pb.GetUsersByIdResp, error) {
	l := logic.NewGetUsersByIdLogic(ctx, s.svcCtx)
	return l.GetUsersById(in)
}

func (s *UsercenterServer) GetUsersByIds(ctx context.Context, in *pb.GetUsersByIdsReq) (*pb.GetUsersByIdsResp, error) {
	l := logic.NewGetUsersByIdsLogic(ctx, s.svcCtx)
	return l.GetUsersByIds(in)
}

func (s *UsercenterServer) SearchUsers(ctx context.Context, in *pb.SearchUsersReq) (*pb.SearchUsersResp, error) {
	l := logic.NewSearchUsersLogic(ctx, s.svcCtx)
	return l.SearchUsers(in)
}

func (s *UsercenterServer) GetUserByUsername(ctx context.Context, in *pb.GetUserByUsernameReq) (*pb.GetUserByUsernameResp, error) {
	l := logic.NewGetUserByUsernameLogic(ctx, s.svcCtx)
	return l.GetUserByUsername(in)
}

func (s *UsercenterServer) Login(ctx context.Context, in *pb.LoginReq) (*pb.LoginResp, error) {
	l := logic.NewLoginLogic(ctx, s.svcCtx)
	return l.Login(in)
}

func (s *UsercenterServer) Register(ctx context.Context, in *pb.RegisterReq) (*pb.RegisterResp, error) {
	l := logic.NewRegisterLogic(ctx, s.svcCtx)
	return l.Register(in)
}

func (s *UsercenterServer) ValidateToken(ctx context.Context, in *pb.ValidateTokenReq) (*pb.ValidateTokenResp, error) {
	l := logic.NewValidateTokenLogic(ctx, s.svcCtx)
	return l.ValidateToken(in)
}

func (s *UsercenterServer) CheckPermission(ctx context.Context, in *pb.CheckPermissionReq) (*pb.CheckPermissionResp, error) {
	l := logic.NewCheckPermissionLogic(ctx, s.svcCtx)
	return l.CheckPermission(in)
}

func (s *UsercenterServer) Logout(ctx context.Context, in *pb.LogoutReq) (*pb.LogoutResp, error) {
	l := logic.NewLogoutLogic(ctx, s.svcCtx)
	return l.Logout(in)
}

func (s *UsercenterServer) ResetPassword(ctx context.Context, in *pb.ResetPasswordReq) (*pb.ResetPasswordResp, error) {
	l := logic.NewResetPasswordLogic(ctx, s.svcCtx)
	return l.ResetPassword(in)
}

func (s *UsercenterServer) SwitchRole(ctx context.Context, in *pb.SwitchRoleReq) (*pb.SwitchRoleResp, error) {
	l := logic.NewSwitchRoleLogic(ctx, s.svcCtx)
	return l.SwitchRole(in)
}

// -----------------------userFollows-----------------------
func (s *UsercenterServer) AddUserFollows(ctx context.Context, in *pb.AddUserFollowsReq) (*pb.AddUserFollowsResp, error) {
	l := logic.NewAddUserFollowsLogic(ctx, s.svcCtx)
	return l.AddUserFollows(in)
}

func (s *UsercenterServer) UpdateUserFollows(ctx context.Context, in *pb.UpdateUserFollowsReq) (*pb.UpdateUserFollowsResp, error) {
	l := logic.NewUpdateUserFollowsLogic(ctx, s.svcCtx)
	return l.UpdateUserFollows(in)
}

func (s *UsercenterServer) DelUserFollows(ctx context.Context, in *pb.DelUserFollowsReq) (*pb.DelUserFollowsResp, error) {
	l := logic.NewDelUserFollowsLogic(ctx, s.svcCtx)
	return l.DelUserFollows(in)
}

func (s *UsercenterServer) GetUserFollowsById(ctx context.Context, in *pb.GetUserFollowsByIdReq) (*pb.GetUserFollowsByIdResp, error) {
	l := logic.NewGetUserFollowsByIdLogic(ctx, s.svcCtx)
	return l.GetUserFollowsById(in)
}

func (s *UsercenterServer) SearchUserFollows(ctx context.Context, in *pb.SearchUserFollowsReq) (*pb.SearchUserFollowsResp, error) {
	l := logic.NewSearchUserFollowsLogic(ctx, s.svcCtx)
	return l.SearchUserFollows(in)
}

// -----------------------userPreferences-----------------------
func (s *UsercenterServer) AddUserPreferences(ctx context.Context, in *pb.AddUserPreferencesReq) (*pb.AddUserPreferencesResp, error) {
	l := logic.NewAddUserPreferencesLogic(ctx, s.svcCtx)
	return l.AddUserPreferences(in)
}

func (s *UsercenterServer) UpdateUserPreferences(ctx context.Context, in *pb.UpdateUserPreferencesReq) (*pb.UpdateUserPreferencesResp, error) {
	l := logic.NewUpdateUserPreferencesLogic(ctx, s.svcCtx)
	return l.UpdateUserPreferences(in)
}

func (s *UsercenterServer) DelUserPreferences(ctx context.Context, in *pb.DelUserPreferencesReq) (*pb.DelUserPreferencesResp, error) {
	l := logic.NewDelUserPreferencesLogic(ctx, s.svcCtx)
	return l.DelUserPreferences(in)
}

func (s *UsercenterServer) GetUserPreferencesById(ctx context.Context, in *pb.GetUserPreferencesByIdReq) (*pb.GetUserPreferencesByIdResp, error) {
	l := logic.NewGetUserPreferencesByIdLogic(ctx, s.svcCtx)
	return l.GetUserPreferencesById(in)
}

func (s *UsercenterServer) SearchUserPreferences(ctx context.Context, in *pb.SearchUserPreferencesReq) (*pb.SearchUserPreferencesResp, error) {
	l := logic.NewSearchUserPreferencesLogic(ctx, s.svcCtx)
	return l.SearchUserPreferences(in)
}
