Compute implied arguments for your functions
Project description
Recommended example usage
import superfilter
from argskwargs import argskwargs
@superfilter
def myfilter():
return argskwargs(foo="foobar", message="Hello World!")
@myfilter
def myfunction(foo, message):
print(message)
return foo
myfunction() # Arguments are supplied by 'myfilter'
Usage with other decorators
import superfilter
from argskwargs import argskwargs
@superfilter
def myfilter(cls):
return argskwargs(cls, foo="foobar", message="Hello World!")
class MyClass:
@classmethod
@myfilter # Decorate with myfilter first
def myfunction(cls, foo, message):
print(message)
return foo
MyClass.myfunction()
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
superfilter-1.0.0.tar.gz
(1.8 kB
view hashes)