mirror of
https://gitea.osmocom.org/sim-card/pysim.git
synced 2026-03-16 18:38:32 +03:00
pySim/profile: Change match_with_profile from static to class method
This was suggested by vyanitskiy during gerrit patch review in https://gerrit.osmocom.org/c/pysim/+/38049 in order to make the upcoming eUICC CardProfiles simpler. Change-Id: Ia7c049b31cb1c5c5bb682406d9dd7a73bcd43185
This commit is contained in:
@@ -137,9 +137,9 @@ class CardProfile:
|
||||
"""
|
||||
return data_hex
|
||||
|
||||
@staticmethod
|
||||
@classmethod
|
||||
@abc.abstractmethod
|
||||
def match_with_card(scc: SimCardCommands) -> bool:
|
||||
def match_with_card(cls, scc: SimCardCommands) -> bool:
|
||||
"""Check if the specific profile matches the card. This method is a
|
||||
placeholder that is overloaded by specific dirived classes. The method
|
||||
actively probes the card to make sure the profile class matches the
|
||||
|
||||
Reference in New Issue
Block a user