Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions src/core/data_verificator.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

class DataVerificator:
@staticmethod
def CheckOptionName(name: str):
def CheckOptionName(name: str) -> None:
if name is None:
RaiseError.OptionNameIsNone()

Expand All @@ -20,6 +20,7 @@ def CheckOptionName(name: str):
RaiseError.OptionNameIsEmpty()

# TODO: Add an extended verification of an option name
return

# --------------------------------------------------------------------
sm_InvalidCommentSymbols: str = "\n\r\0"
Expand All @@ -41,7 +42,7 @@ def IsValidCommentText(text: str) -> bool:

# --------------------------------------------------------------------
@staticmethod
def CheckCommentText(text: str):
def CheckCommentText(text: str) -> None:
assert text is not None
assert type(text) is str

Expand All @@ -51,15 +52,18 @@ def CheckCommentText(text: str):
RaiseError.CommentTextContainsInvalidSymbols()

# OK
return

# --------------------------------------------------------------------
@staticmethod
def CheckStringOfFilePath(text: str):
def CheckStringOfFilePath(text: str) -> None:
assert text is not None
assert type(text) is str

if text == "":
RaiseError.FilePathIsEmpty()

return


# //////////////////////////////////////////////////////////////////////////////
Loading