The Decorator Function of Python has this simple template
@A
@B
def C():
It modify the C function to C=A(B(C));
Let's give a more specific example
@request("POST", "%(channel)d/sequence/%(args)s")
@response("%d")
def outputSequence(self, channel, args):
self.checkDigitalChannelExported(channel)
self.checkPostingValueAllowed()
self.checkDigitalChannel(channel)
(period, sequence) = args.split(",")
period = int(period)
GPIO.outputSequence(channel, period, sequence)
return int(sequence[-1])
So from the above, would the transformed function be
like request(response(outSequence(self, channel, args))?