allow
The allow decorators are used to specify when specific OnComplete operations are allowed after logic evaluation.
The OnComplete can be allowed on applicaiton creation via @allow.create
or on non-create calls via @allow.call
By defualt, all methods are allowed to be called with the NoOp
OnComplete (@allow.call('NoOp')
). Once a single @allow
decorator is used, @allow.call(NoOp)
must be explicitly set if it is desired.
Example
Constructors
new allow()
new allow():
allow
Returns
Methods
bareCall()
static
bareCall(onComplete
):decorator
When no the contract is called without an ABI method selector, allow this method logic to be evaluated for the given OnComplete
Parameters
• onComplete: "NoOp"
| "OptIn"
| "CloseOut"
| "ClearState"
| "UpdateApplication"
| "DeleteApplication"
Returns
Source
bareCreate()
static
bareCreate(onComplete
):decorator
When the contract is created without an ABI method selector, allow this method logic to be evaluated for the given OnComplete
Parameters
• onComplete: "NoOp"
| "OptIn"
| "CloseOut"
| "ClearState"
| "UpdateApplication"
| "DeleteApplication"
= 'NoOp'
Returns
Source
call()
static
call(onComplete
):decorator
Specify an allowed OnComplete when the method is called
Parameters
• onComplete: "NoOp"
| "OptIn"
| "CloseOut"
| "ClearState"
| "UpdateApplication"
| "DeleteApplication"
Returns
Source
create()
static
create(onComplete
):decorator
Specify an allowed OnComplete when the method is used for contract creation
Parameters
• onComplete: "NoOp"
| "OptIn"
| "CloseOut"
| "ClearState"
| "UpdateApplication"
| "DeleteApplication"
= 'NoOp'