Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ImageProcessService ¶
type ImageProcessService interface {
CreateThumbnails(ctx context.Context, photoFile *entities.PhotoFile, data []byte, orientation int) error
}
func NewImageProcessService ¶
func NewImageProcessService(thumbRepo infrastructures.PhotoStorageAdapter) ImageProcessService
type OAuthService ¶
type OAuthService interface { PublishUserAccessToken(ctx context.Context, client *entities.OauthClient, userID string) (string, int64, error) PublishCCAccessToken(ctx context.Context, client *entities.OauthClient) (string, int64, error) GetSession(ctx context.Context, accessToken string) (*entities.OauthSession, error) AuthByRefreshToken(ctx context.Context, clientID, refreshToken string) (*entities.UserAuth, error) UpsertUserAuth(ctx context.Context, clientID, userID string, now time.Time) (string, error) AuthCode(ctx context.Context, client *entities.OauthClient, code, redirectURL string) (*entities.OAuthCode, error) PublishAuthCode(ctx context.Context, clientID, userID, redirectURL string) (string, error) AuthClient(ctx context.Context, clientID, clientSecret string) (*entities.OauthClient, error) CreateClientWithClientSecret(ctx context.Context, client *entities.OauthClient, clientSecret string) error CreateClient(ctx context.Context, client *entities.OauthClient) (*entities.OauthClient, string, error) ValidateToCreateClient(ctx context.Context, client *entities.OauthClient) error GetUserClient(ctx context.Context, clientID string) (*entities.OauthClient, error) GetOAuthClientRedirectURLsByOAuthClientID(ctx context.Context, clientID string) (entities.OAuthClientRedirectURLList, error) ValidateRedirectURL(ctx context.Context, clientID, redirectURL string) error }
func NewOAuthService ¶
func NewOAuthService( passwordService PasswordService, authAdapter infrastructures.OAuthAdapter, ) OAuthService
type PasswordService ¶
type PasswordService interface { HashPassword(password string) (string, error) MatchPassword(password string, hash string) (bool, error) GeneratePassword(length int) (string, error) }
func NewPasswordService ¶
func NewPasswordService() PasswordService
type PhotoService ¶
type PhotoService interface { ShouldSkipToRegisterPhoto(ctx context.Context, filePath, fileHash string) (bool, error) RegisterPhoto(ctx context.Context, filePath, fileHash string) (*entities.Photo, error) }
func NewPhotoService ¶
func NewPhotoService(photoRepo infrastructures.PhotoAdapter, photoStorage infrastructures.PhotoStorageAdapter) PhotoService
type UserService ¶
func NewUserService ¶
func NewUserService( userAdapter infrastructures.UserAdapter, passwordService PasswordService, ) UserService
Click to show internal directories.
Click to hide internal directories.