OracleDenied.sol
OracleDenied
Inherits: Ownable, IOracleEvents
Author: @ShaneDuncan602, @oscarsernarosero, @TJ-Everett
This is an example on-chain oracle that maintains a denied list.
This is intended to be a model only. It stores the Denied list internally and returns bool true if address is in list.
State Variables
deniedAddresses
Functions
constructor
Constructor that only serves the purpose of notifying the indexer of its creation via event
name
Return the contract name
Returns
Name | Type | Description |
---|---|---|
<none> | string | name the name of the contract |
addToDeniedList
Add addresses to the denied list. Restricted to owner.
Parameters
Name | Type | Description |
---|---|---|
newDeniedAddrs | address[] | the addresses to add |
addAddressToDeniedList
Add single address to the denied list. Restricted to owner.
Parameters
Name | Type | Description |
---|---|---|
newDeniedAddr | address | the addresses to add |
removeFromDeniedList
Remove addresses from the Denied list. Restricted to owner.
Parameters
Name | Type | Description |
---|---|---|
removeDeniedAddrs | address[] | the addresses to remove |
isDenied
Check to see if address is in denied list
Parameters
Name | Type | Description |
---|---|---|
addr | address | the address to check |
Returns
Name | Type | Description |
---|---|---|
<none> | bool | denied returns true if in the denied list, false if not. |
isDeniedVerbose
Check to see if address is in denied list. Also emits events based on the results
Parameters
Name | Type | Description |
---|---|---|
addr | address | the address to check |
Returns
Name | Type | Description |
---|---|---|
<none> | bool | denied returns true if in the denied list, false if not. |