(self, name, index, annotations, return_type, args, api_name)
| 402 | |
| 403 | class FunctionApi: |
| 404 | def __init__(self, name, index, annotations, return_type, args, api_name): |
| 405 | self.name = name |
| 406 | self.index = index |
| 407 | |
| 408 | self.min_version = None |
| 409 | self.annotations = [] |
| 410 | for annotation in annotations: |
| 411 | # String checks, because manual import breaks isinstance |
| 412 | if type(annotation).__name__ == "StealRef": |
| 413 | self.annotations.append(annotation) |
| 414 | elif type(annotation).__name__ == "MinVersion": |
| 415 | if self.min_version is not None: |
| 416 | raise ValueError("Two minimum versions specified!") |
| 417 | self.min_version = annotation |
| 418 | else: |
| 419 | raise ValueError(f"unknown annotation {annotation}") |
| 420 | |
| 421 | self.return_type = return_type |
| 422 | self.args = args |
| 423 | self.api_name = api_name |
| 424 | |
| 425 | def _argtypes_string(self): |
| 426 | if not self.args: |
nothing calls this directly
no outgoing calls
no test coverage detected