How to retrieve the arguments needed for a function call?
Ayush Kumar
Member, Moderator, Employee Posts: 442
✭✭✭✭
Answers
-
To know what a function/property does and what all arguments are needed for a function, retrieve the doc-string for a function.
Example: If one wants to figure out what arguments does the method
ConvertToUnitSystem
requires, use the followingmy_quantity.ConvertToUnitSystem.__doc__
Output:
'ConvertToUnitSystem(self: Quantity, unitSystem: str, quantityName: str) -> Quantity \n'
5