You've already forked RekomenciBackend
fast init
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
from abc import abstractmethod
|
||||
from typing import Protocol
|
||||
|
||||
from template_project.application.access_token.entity import AccessTokenId
|
||||
|
||||
|
||||
type RawAccessToken = str
|
||||
|
||||
|
||||
class AccessTokenCryptographer(Protocol):
|
||||
@abstractmethod
|
||||
def crypto(self, access_token_id: AccessTokenId) -> RawAccessToken:
|
||||
raise NotImplementedError
|
||||
|
||||
@abstractmethod
|
||||
def decrypto(self, raw_access_token: RawAccessToken) -> AccessTokenId:
|
||||
raise NotImplementedError
|
||||
Reference in New Issue
Block a user