Module omnipy.modules.raw.protocols
Overview
View Source
from typing import Protocol
class IsModifyContentsCallable(Protocol):
""""""
def __call__(self, data_file: str, **kwargs: object) -> str:
...
class IsModifyEachLineCallable(Protocol):
""""""
def __call__(self, line_no: int, line: str, **kwargs: object) -> str:
...
class IsModifyAllLinesCallable(Protocol):
""""""
def __call__(self, all_lines: list[str], **kwargs: object) -> list[str]:
...
Classes
IsModifyAllLinesCallable
View Source
class IsModifyAllLinesCallable(Protocol):
""""""
def __call__(self, all_lines: list[str], **kwargs: object) -> list[str]:
...
Methods
call
Call self as a function.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
all_lines |
list[str] |
||
kwargs |
object |
Returns:
Type | Description |
---|---|
list[str] |
View Source
def __call__(self, all_lines: list[str], **kwargs: object) -> list[str]:
...
IsModifyContentsCallable
View Source
class IsModifyContentsCallable(Protocol):
""""""
def __call__(self, data_file: str, **kwargs: object) -> str:
...
Methods
call
Call self as a function.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
data_file |
str |
||
kwargs |
object |
Returns:
Type | Description |
---|---|
str |
View Source
def __call__(self, data_file: str, **kwargs: object) -> str:
...
IsModifyEachLineCallable
View Source
class IsModifyEachLineCallable(Protocol):
""""""
def __call__(self, line_no: int, line: str, **kwargs: object) -> str:
...
Methods
call
Call self as a function.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
line_no |
int |
||
line |
str |
||
kwargs |
object |
Returns:
Type | Description |
---|---|
str |
View Source
def __call__(self, line_no: int, line: str, **kwargs: object) -> str:
...