-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: chrismaree <christopher.maree@gmail.com>
- Loading branch information
1 parent
e4aeac8
commit 0c2402f
Showing
3 changed files
with
72 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
// SPDX-License-Identifier: BUSL-1.1 | ||
pragma solidity 0.8.17; | ||
|
||
import {ImmutableController} from "../controllers/ImmutableController.sol"; | ||
import {ChainlinkSourceAdapter} from "../adapters/source-adapters/ChainlinkSourceAdapter.sol"; | ||
import {ChainlinkDestinationAdapter} from "../adapters/destination-adapters/ChainlinkDestinationAdapter.sol"; | ||
import {IAggregatorV3Source} from "../interfaces/chainlink/IAggregatorV3Source.sol"; | ||
|
||
contract OvalChainlinkImmutable is ImmutableController, ChainlinkSourceAdapter, ChainlinkDestinationAdapter { | ||
constructor( | ||
IAggregatorV3Source source, | ||
address[] memory unlockers, | ||
uint256 _lockWindow, | ||
uint256 _maxTraversal, | ||
address owner | ||
) | ||
ChainlinkSourceAdapter(source) | ||
ImmutableController(_lockWindow, _maxTraversal, unlockers) | ||
ChainlinkDestinationAdapter(source.decimals()) | ||
{} | ||
} | ||
|
||
contract MutableUnlockersOvalChainlinkFactory { | ||
function createImmutableOvalChainlink( | ||
IAggregatorV3Source source, | ||
uint256 lockWindow, | ||
uint256 maxTraversal, | ||
address owner, | ||
address[] memory unlockers | ||
) external returns (address) { | ||
return address(new OvalChainlinkImmutable(source, unlockers, lockWindow, maxTraversal, owner)); | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
// SPDX-License-Identifier: BUSL-1.1 | ||
pragma solidity 0.8.17; | ||
|
||
import {MutableUnlockersController} from "../controllers/MutableUnlockersController.sol"; | ||
import {ChainlinkSourceAdapter} from "../adapters/source-adapters/ChainlinkSourceAdapter.sol"; | ||
import {ChainlinkDestinationAdapter} from "../adapters/destination-adapters/ChainlinkDestinationAdapter.sol"; | ||
import {IAggregatorV3Source} from "../interfaces/chainlink/IAggregatorV3Source.sol"; | ||
|
||
contract OvalChainlinkMutableUnlocker is | ||
MutableUnlockersController, | ||
ChainlinkSourceAdapter, | ||
ChainlinkDestinationAdapter | ||
{ | ||
constructor( | ||
IAggregatorV3Source source, | ||
address[] memory unlockers, | ||
uint256 _lockWindow, | ||
uint256 _maxTraversal, | ||
address owner | ||
) | ||
ChainlinkSourceAdapter(source) | ||
MutableUnlockersController(_lockWindow, _maxTraversal, unlockers) | ||
ChainlinkDestinationAdapter(source.decimals()) | ||
{ | ||
_transferOwnership(owner); | ||
} | ||
} | ||
|
||
contract MutableUnlockersOvalChainlinkFactory { | ||
function createMutableUnlockerOvalChainlink( | ||
IAggregatorV3Source source, | ||
uint256 lockWindow, | ||
uint256 maxTraversal, | ||
address owner, | ||
address[] memory unlockers | ||
) external returns (address) { | ||
return address(new OvalChainlinkMutableUnlocker(source, unlockers, lockWindow, maxTraversal, owner)); | ||
} | ||
} |