OrderBook

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 9, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var OrderBookABI = OrderBookMetaData.ABI

OrderBookABI is the input ABI used to generate the binding from. Deprecated: Use OrderBookMetaData.ABI instead.

View Source
var OrderBookMetaData = &bind.MetaData{
	ABI: "[{\"type\":\"constructor\",\"inputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"receive\",\"stateMutability\":\"payable\"},{\"type\":\"function\",\"name\":\"PRICE_PRECISION\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"USDG_PRECISION\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"cancelDecreaseOrder\",\"inputs\":[{\"name\":\"_orderIndex\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"cancelIncreaseOrder\",\"inputs\":[{\"name\":\"_orderIndex\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"cancelMultiple\",\"inputs\":[{\"name\":\"_swapOrderIndexes\",\"type\":\"uint256[]\",\"internalType\":\"uint256[]\"},{\"name\":\"_increaseOrderIndexes\",\"type\":\"uint256[]\",\"internalType\":\"uint256[]\"},{\"name\":\"_decreaseOrderIndexes\",\"type\":\"uint256[]\",\"internalType\":\"uint256[]\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"cancelSwapOrder\",\"inputs\":[{\"name\":\"_orderIndex\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"createDecreaseOrder\",\"inputs\":[{\"name\":\"_indexToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_sizeDelta\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_collateralToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_collateralDelta\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_isLong\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"_triggerPrice\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_triggerAboveThreshold\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"payable\"},{\"type\":\"function\",\"name\":\"createIncreaseOrder\",\"inputs\":[{\"name\":\"_path\",\"type\":\"address[]\",\"internalType\":\"address[]\"},{\"name\":\"_amountIn\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_indexToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_minOut\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_sizeDelta\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_collateralToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_isLong\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"_triggerPrice\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_triggerAboveThreshold\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"_executionFee\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_shouldWrap\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"payable\"},{\"type\":\"function\",\"name\":\"createSwapOrder\",\"inputs\":[{\"name\":\"_path\",\"type\":\"address[]\",\"internalType\":\"address[]\"},{\"name\":\"_amountIn\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_minOut\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_triggerRatio\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_triggerAboveThreshold\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"_executionFee\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_shouldWrap\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"_shouldUnwrap\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"payable\"},{\"type\":\"function\",\"name\":\"decreaseOrders\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"account\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"collateralToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"collateralDelta\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"indexToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"sizeDelta\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"isLong\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"triggerPrice\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"decreaseOrdersIndex\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"executeDecreaseOrder\",\"inputs\":[{\"name\":\"_address\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_orderIndex\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_feeReceiver\",\"type\":\"address\",\"internalType\":\"addresspayable\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"executeIncreaseOrder\",\"inputs\":[{\"name\":\"_address\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_orderIndex\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_feeReceiver\",\"type\":\"address\",\"internalType\":\"addresspayable\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"executeSwapOrder\",\"inputs\":[{\"name\":\"_account\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_orderIndex\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_feeReceiver\",\"type\":\"address\",\"internalType\":\"addresspayable\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"getDecreaseOrder\",\"inputs\":[{\"name\":\"_account\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_orderIndex\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"collateralToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"collateralDelta\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"indexToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"sizeDelta\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"isLong\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"triggerPrice\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getIncreaseOrder\",\"inputs\":[{\"name\":\"_account\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_orderIndex\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"purchaseToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"purchaseTokenAmount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"collateralToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"indexToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"sizeDelta\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"isLong\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"triggerPrice\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getSwapOrder\",\"inputs\":[{\"name\":\"_account\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_orderIndex\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"path0\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"path1\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"path2\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"amountIn\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"minOut\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"triggerRatio\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"shouldUnwrap\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getUsdgMinPrice\",\"inputs\":[{\"name\":\"_otherToken\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"gov\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"increaseOrders\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"account\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"purchaseToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"purchaseTokenAmount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"collateralToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"indexToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"sizeDelta\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"isLong\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"triggerPrice\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"increaseOrdersIndex\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"initialize\",\"inputs\":[{\"name\":\"_router\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_vault\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_weth\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_usdg\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_minExecutionFee\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_minPurchaseTokenAmountUsd\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"isInitialized\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"minExecutionFee\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"minPurchaseTokenAmountUsd\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"router\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"setGov\",\"inputs\":[{\"name\":\"_gov\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setMinExecutionFee\",\"inputs\":[{\"name\":\"_minExecutionFee\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setMinPurchaseTokenAmountUsd\",\"inputs\":[{\"name\":\"_minPurchaseTokenAmountUsd\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"swapOrders\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"account\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"amountIn\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"minOut\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"triggerRatio\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"shouldUnwrap\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"swapOrdersIndex\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"updateDecreaseOrder\",\"inputs\":[{\"name\":\"_orderIndex\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_collateralDelta\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_sizeDelta\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_triggerPrice\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_triggerAboveThreshold\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"updateIncreaseOrder\",\"inputs\":[{\"name\":\"_orderIndex\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_sizeDelta\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_triggerPrice\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_triggerAboveThreshold\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"updateSwapOrder\",\"inputs\":[{\"name\":\"_orderIndex\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_minOut\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_triggerRatio\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_triggerAboveThreshold\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"usdg\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"validatePositionOrderPrice\",\"inputs\":[{\"name\":\"_triggerAboveThreshold\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"_triggerPrice\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"_indexToken\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_maximizePrice\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"_raise\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"validateSwapOrderPriceWithTriggerAboveThreshold\",\"inputs\":[{\"name\":\"_path\",\"type\":\"address[]\",\"internalType\":\"address[]\"},{\"name\":\"_triggerRatio\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"vault\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"weth\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"event\",\"name\":\"CancelDecreaseOrder\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"orderIndex\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"collateralToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"collateralDelta\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"indexToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"sizeDelta\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"isLong\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"triggerPrice\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CancelIncreaseOrder\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"orderIndex\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"purchaseToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"purchaseTokenAmount\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"collateralToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"indexToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"sizeDelta\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"isLong\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"triggerPrice\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CancelSwapOrder\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"orderIndex\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"path\",\"type\":\"address[]\",\"indexed\":false,\"internalType\":\"address[]\"},{\"name\":\"amountIn\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"minOut\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerRatio\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"shouldUnwrap\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CreateDecreaseOrder\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"orderIndex\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"collateralToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"collateralDelta\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"indexToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"sizeDelta\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"isLong\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"triggerPrice\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CreateIncreaseOrder\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"orderIndex\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"purchaseToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"purchaseTokenAmount\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"collateralToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"indexToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"sizeDelta\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"isLong\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"triggerPrice\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CreateSwapOrder\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"orderIndex\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"path\",\"type\":\"address[]\",\"indexed\":false,\"internalType\":\"address[]\"},{\"name\":\"amountIn\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"minOut\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerRatio\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"shouldUnwrap\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExecuteDecreaseOrder\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"orderIndex\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"collateralToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"collateralDelta\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"indexToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"sizeDelta\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"isLong\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"triggerPrice\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"executionPrice\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExecuteIncreaseOrder\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"orderIndex\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"purchaseToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"purchaseTokenAmount\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"collateralToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"indexToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"sizeDelta\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"isLong\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"triggerPrice\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"executionPrice\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExecuteSwapOrder\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"orderIndex\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"path\",\"type\":\"address[]\",\"indexed\":false,\"internalType\":\"address[]\"},{\"name\":\"amountIn\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"minOut\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"amountOut\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerRatio\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"shouldUnwrap\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Initialize\",\"inputs\":[{\"name\":\"router\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"vault\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"weth\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"usdg\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"minExecutionFee\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"minPurchaseTokenAmountUsd\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"UpdateDecreaseOrder\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"orderIndex\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"collateralToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"collateralDelta\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"indexToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"sizeDelta\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"isLong\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"triggerPrice\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"UpdateGov\",\"inputs\":[{\"name\":\"gov\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"UpdateIncreaseOrder\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"orderIndex\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"collateralToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"indexToken\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"isLong\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"sizeDelta\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerPrice\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"UpdateMinExecutionFee\",\"inputs\":[{\"name\":\"minExecutionFee\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"UpdateMinPurchaseTokenAmountUsd\",\"inputs\":[{\"name\":\"minPurchaseTokenAmountUsd\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"UpdateSwapOrder\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"ordexIndex\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"path\",\"type\":\"address[]\",\"indexed\":false,\"internalType\":\"address[]\"},{\"name\":\"amountIn\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"minOut\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerRatio\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"triggerAboveThreshold\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"shouldUnwrap\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"executionFee\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false}]",
}

OrderBookMetaData contains all meta data concerning the OrderBook contract.

Functions

This section is empty.

Types

type OrderBook

type OrderBook struct {
	OrderBookCaller     // Read-only binding to the contract
	OrderBookTransactor // Write-only binding to the contract
	OrderBookFilterer   // Log filterer for contract events
}

OrderBook is an auto generated Go binding around an Ethereum contract.

func NewOrderBook

func NewOrderBook(address common.Address, backend bind.ContractBackend) (*OrderBook, error)

NewOrderBook creates a new instance of OrderBook, bound to a specific deployed contract.

type OrderBookCaller

type OrderBookCaller struct {
	// contains filtered or unexported fields
}

OrderBookCaller is an auto generated read-only Go binding around an Ethereum contract.

func NewOrderBookCaller

func NewOrderBookCaller(address common.Address, caller bind.ContractCaller) (*OrderBookCaller, error)

NewOrderBookCaller creates a new read-only instance of OrderBook, bound to a specific deployed contract.

func (*OrderBookCaller) DecreaseOrders

func (_OrderBook *OrderBookCaller) DecreaseOrders(opts *bind.CallOpts, arg0 common.Address, arg1 *big.Int) (struct {
	Account               common.Address
	CollateralToken       common.Address
	CollateralDelta       *big.Int
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
}, error)

DecreaseOrders is a free data retrieval call binding the contract method 0xf2d2e01b.

Solidity: function decreaseOrders(address , uint256 ) view returns(address account, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookCaller) DecreaseOrdersIndex

func (_OrderBook *OrderBookCaller) DecreaseOrdersIndex(opts *bind.CallOpts, arg0 common.Address) (*big.Int, error)

DecreaseOrdersIndex is a free data retrieval call binding the contract method 0xd566d0ca.

Solidity: function decreaseOrdersIndex(address ) view returns(uint256)

func (*OrderBookCaller) GetDecreaseOrder

func (_OrderBook *OrderBookCaller) GetDecreaseOrder(opts *bind.CallOpts, _account common.Address, _orderIndex *big.Int) (struct {
	CollateralToken       common.Address
	CollateralDelta       *big.Int
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
}, error)

GetDecreaseOrder is a free data retrieval call binding the contract method 0x026032ee.

Solidity: function getDecreaseOrder(address _account, uint256 _orderIndex) view returns(address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookCaller) GetIncreaseOrder

func (_OrderBook *OrderBookCaller) GetIncreaseOrder(opts *bind.CallOpts, _account common.Address, _orderIndex *big.Int) (struct {
	PurchaseToken         common.Address
	PurchaseTokenAmount   *big.Int
	CollateralToken       common.Address
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
}, error)

GetIncreaseOrder is a free data retrieval call binding the contract method 0xd3bab1d1.

Solidity: function getIncreaseOrder(address _account, uint256 _orderIndex) view returns(address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookCaller) GetSwapOrder

func (_OrderBook *OrderBookCaller) GetSwapOrder(opts *bind.CallOpts, _account common.Address, _orderIndex *big.Int) (struct {
	Path0                 common.Address
	Path1                 common.Address
	Path2                 common.Address
	AmountIn              *big.Int
	MinOut                *big.Int
	TriggerRatio          *big.Int
	TriggerAboveThreshold bool
	ShouldUnwrap          bool
	ExecutionFee          *big.Int
}, error)

GetSwapOrder is a free data retrieval call binding the contract method 0xd0d40cd6.

Solidity: function getSwapOrder(address _account, uint256 _orderIndex) view returns(address path0, address path1, address path2, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookCaller) GetUsdgMinPrice

func (_OrderBook *OrderBookCaller) GetUsdgMinPrice(opts *bind.CallOpts, _otherToken common.Address) (*big.Int, error)

GetUsdgMinPrice is a free data retrieval call binding the contract method 0x9e23de5c.

Solidity: function getUsdgMinPrice(address _otherToken) view returns(uint256)

func (*OrderBookCaller) Gov

func (_OrderBook *OrderBookCaller) Gov(opts *bind.CallOpts) (common.Address, error)

Gov is a free data retrieval call binding the contract method 0x12d43a51.

Solidity: function gov() view returns(address)

func (*OrderBookCaller) IncreaseOrders

func (_OrderBook *OrderBookCaller) IncreaseOrders(opts *bind.CallOpts, arg0 common.Address, arg1 *big.Int) (struct {
	Account               common.Address
	PurchaseToken         common.Address
	PurchaseTokenAmount   *big.Int
	CollateralToken       common.Address
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
}, error)

IncreaseOrders is a free data retrieval call binding the contract method 0x2b7d6290.

Solidity: function increaseOrders(address , uint256 ) view returns(address account, address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookCaller) IncreaseOrdersIndex

func (_OrderBook *OrderBookCaller) IncreaseOrdersIndex(opts *bind.CallOpts, arg0 common.Address) (*big.Int, error)

IncreaseOrdersIndex is a free data retrieval call binding the contract method 0xaec22455.

Solidity: function increaseOrdersIndex(address ) view returns(uint256)

func (*OrderBookCaller) IsInitialized

func (_OrderBook *OrderBookCaller) IsInitialized(opts *bind.CallOpts) (bool, error)

IsInitialized is a free data retrieval call binding the contract method 0x392e53cd.

Solidity: function isInitialized() view returns(bool)

func (*OrderBookCaller) MinExecutionFee

func (_OrderBook *OrderBookCaller) MinExecutionFee(opts *bind.CallOpts) (*big.Int, error)

MinExecutionFee is a free data retrieval call binding the contract method 0x63ae2103.

Solidity: function minExecutionFee() view returns(uint256)

func (*OrderBookCaller) MinPurchaseTokenAmountUsd

func (_OrderBook *OrderBookCaller) MinPurchaseTokenAmountUsd(opts *bind.CallOpts) (*big.Int, error)

MinPurchaseTokenAmountUsd is a free data retrieval call binding the contract method 0x8de10c2e.

Solidity: function minPurchaseTokenAmountUsd() view returns(uint256)

func (*OrderBookCaller) PRICEPRECISION

func (_OrderBook *OrderBookCaller) PRICEPRECISION(opts *bind.CallOpts) (*big.Int, error)

PRICEPRECISION is a free data retrieval call binding the contract method 0x95082d25.

Solidity: function PRICE_PRECISION() view returns(uint256)

func (*OrderBookCaller) Router

func (_OrderBook *OrderBookCaller) Router(opts *bind.CallOpts) (common.Address, error)

Router is a free data retrieval call binding the contract method 0xf887ea40.

Solidity: function router() view returns(address)

func (*OrderBookCaller) SwapOrders

func (_OrderBook *OrderBookCaller) SwapOrders(opts *bind.CallOpts, arg0 common.Address, arg1 *big.Int) (struct {
	Account               common.Address
	AmountIn              *big.Int
	MinOut                *big.Int
	TriggerRatio          *big.Int
	TriggerAboveThreshold bool
	ShouldUnwrap          bool
	ExecutionFee          *big.Int
}, error)

SwapOrders is a free data retrieval call binding the contract method 0x79221fa2.

Solidity: function swapOrders(address , uint256 ) view returns(address account, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookCaller) SwapOrdersIndex

func (_OrderBook *OrderBookCaller) SwapOrdersIndex(opts *bind.CallOpts, arg0 common.Address) (*big.Int, error)

SwapOrdersIndex is a free data retrieval call binding the contract method 0x00cf066b.

Solidity: function swapOrdersIndex(address ) view returns(uint256)

func (*OrderBookCaller) USDGPRECISION

func (_OrderBook *OrderBookCaller) USDGPRECISION(opts *bind.CallOpts) (*big.Int, error)

USDGPRECISION is a free data retrieval call binding the contract method 0x4a686d67.

Solidity: function USDG_PRECISION() view returns(uint256)

func (*OrderBookCaller) Usdg

func (_OrderBook *OrderBookCaller) Usdg(opts *bind.CallOpts) (common.Address, error)

Usdg is a free data retrieval call binding the contract method 0xf5b91b7b.

Solidity: function usdg() view returns(address)

func (*OrderBookCaller) ValidatePositionOrderPrice

func (_OrderBook *OrderBookCaller) ValidatePositionOrderPrice(opts *bind.CallOpts, _triggerAboveThreshold bool, _triggerPrice *big.Int, _indexToken common.Address, _maximizePrice bool, _raise bool) (*big.Int, bool, error)

ValidatePositionOrderPrice is a free data retrieval call binding the contract method 0x4c54f0b0.

Solidity: function validatePositionOrderPrice(bool _triggerAboveThreshold, uint256 _triggerPrice, address _indexToken, bool _maximizePrice, bool _raise) view returns(uint256, bool)

func (*OrderBookCaller) ValidateSwapOrderPriceWithTriggerAboveThreshold

func (_OrderBook *OrderBookCaller) ValidateSwapOrderPriceWithTriggerAboveThreshold(opts *bind.CallOpts, _path []common.Address, _triggerRatio *big.Int) (bool, error)

ValidateSwapOrderPriceWithTriggerAboveThreshold is a free data retrieval call binding the contract method 0xc4a1821b.

Solidity: function validateSwapOrderPriceWithTriggerAboveThreshold(address[] _path, uint256 _triggerRatio) view returns(bool)

func (*OrderBookCaller) Vault

func (_OrderBook *OrderBookCaller) Vault(opts *bind.CallOpts) (common.Address, error)

Vault is a free data retrieval call binding the contract method 0xfbfa77cf.

Solidity: function vault() view returns(address)

func (*OrderBookCaller) Weth

func (_OrderBook *OrderBookCaller) Weth(opts *bind.CallOpts) (common.Address, error)

Weth is a free data retrieval call binding the contract method 0x3fc8cef3.

Solidity: function weth() view returns(address)

type OrderBookCallerRaw

type OrderBookCallerRaw struct {
	Contract *OrderBookCaller // Generic read-only contract binding to access the raw methods on
}

OrderBookCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.

func (*OrderBookCallerRaw) Call

func (_OrderBook *OrderBookCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error

Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.

type OrderBookCallerSession

type OrderBookCallerSession struct {
	Contract *OrderBookCaller // Generic contract caller binding to set the session for
	CallOpts bind.CallOpts    // Call options to use throughout this session
}

OrderBookCallerSession is an auto generated read-only Go binding around an Ethereum contract, with pre-set call options.

func (*OrderBookCallerSession) DecreaseOrders

func (_OrderBook *OrderBookCallerSession) DecreaseOrders(arg0 common.Address, arg1 *big.Int) (struct {
	Account               common.Address
	CollateralToken       common.Address
	CollateralDelta       *big.Int
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
}, error)

DecreaseOrders is a free data retrieval call binding the contract method 0xf2d2e01b.

Solidity: function decreaseOrders(address , uint256 ) view returns(address account, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookCallerSession) DecreaseOrdersIndex

func (_OrderBook *OrderBookCallerSession) DecreaseOrdersIndex(arg0 common.Address) (*big.Int, error)

DecreaseOrdersIndex is a free data retrieval call binding the contract method 0xd566d0ca.

Solidity: function decreaseOrdersIndex(address ) view returns(uint256)

func (*OrderBookCallerSession) GetDecreaseOrder

func (_OrderBook *OrderBookCallerSession) GetDecreaseOrder(_account common.Address, _orderIndex *big.Int) (struct {
	CollateralToken       common.Address
	CollateralDelta       *big.Int
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
}, error)

GetDecreaseOrder is a free data retrieval call binding the contract method 0x026032ee.

Solidity: function getDecreaseOrder(address _account, uint256 _orderIndex) view returns(address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookCallerSession) GetIncreaseOrder

func (_OrderBook *OrderBookCallerSession) GetIncreaseOrder(_account common.Address, _orderIndex *big.Int) (struct {
	PurchaseToken         common.Address
	PurchaseTokenAmount   *big.Int
	CollateralToken       common.Address
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
}, error)

GetIncreaseOrder is a free data retrieval call binding the contract method 0xd3bab1d1.

Solidity: function getIncreaseOrder(address _account, uint256 _orderIndex) view returns(address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookCallerSession) GetSwapOrder

func (_OrderBook *OrderBookCallerSession) GetSwapOrder(_account common.Address, _orderIndex *big.Int) (struct {
	Path0                 common.Address
	Path1                 common.Address
	Path2                 common.Address
	AmountIn              *big.Int
	MinOut                *big.Int
	TriggerRatio          *big.Int
	TriggerAboveThreshold bool
	ShouldUnwrap          bool
	ExecutionFee          *big.Int
}, error)

GetSwapOrder is a free data retrieval call binding the contract method 0xd0d40cd6.

Solidity: function getSwapOrder(address _account, uint256 _orderIndex) view returns(address path0, address path1, address path2, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookCallerSession) GetUsdgMinPrice

func (_OrderBook *OrderBookCallerSession) GetUsdgMinPrice(_otherToken common.Address) (*big.Int, error)

GetUsdgMinPrice is a free data retrieval call binding the contract method 0x9e23de5c.

Solidity: function getUsdgMinPrice(address _otherToken) view returns(uint256)

func (*OrderBookCallerSession) Gov

func (_OrderBook *OrderBookCallerSession) Gov() (common.Address, error)

Gov is a free data retrieval call binding the contract method 0x12d43a51.

Solidity: function gov() view returns(address)

func (*OrderBookCallerSession) IncreaseOrders

func (_OrderBook *OrderBookCallerSession) IncreaseOrders(arg0 common.Address, arg1 *big.Int) (struct {
	Account               common.Address
	PurchaseToken         common.Address
	PurchaseTokenAmount   *big.Int
	CollateralToken       common.Address
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
}, error)

IncreaseOrders is a free data retrieval call binding the contract method 0x2b7d6290.

Solidity: function increaseOrders(address , uint256 ) view returns(address account, address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookCallerSession) IncreaseOrdersIndex

func (_OrderBook *OrderBookCallerSession) IncreaseOrdersIndex(arg0 common.Address) (*big.Int, error)

IncreaseOrdersIndex is a free data retrieval call binding the contract method 0xaec22455.

Solidity: function increaseOrdersIndex(address ) view returns(uint256)

func (*OrderBookCallerSession) IsInitialized

func (_OrderBook *OrderBookCallerSession) IsInitialized() (bool, error)

IsInitialized is a free data retrieval call binding the contract method 0x392e53cd.

Solidity: function isInitialized() view returns(bool)

func (*OrderBookCallerSession) MinExecutionFee

func (_OrderBook *OrderBookCallerSession) MinExecutionFee() (*big.Int, error)

MinExecutionFee is a free data retrieval call binding the contract method 0x63ae2103.

Solidity: function minExecutionFee() view returns(uint256)

func (*OrderBookCallerSession) MinPurchaseTokenAmountUsd

func (_OrderBook *OrderBookCallerSession) MinPurchaseTokenAmountUsd() (*big.Int, error)

MinPurchaseTokenAmountUsd is a free data retrieval call binding the contract method 0x8de10c2e.

Solidity: function minPurchaseTokenAmountUsd() view returns(uint256)

func (*OrderBookCallerSession) PRICEPRECISION

func (_OrderBook *OrderBookCallerSession) PRICEPRECISION() (*big.Int, error)

PRICEPRECISION is a free data retrieval call binding the contract method 0x95082d25.

Solidity: function PRICE_PRECISION() view returns(uint256)

func (*OrderBookCallerSession) Router

func (_OrderBook *OrderBookCallerSession) Router() (common.Address, error)

Router is a free data retrieval call binding the contract method 0xf887ea40.

Solidity: function router() view returns(address)

func (*OrderBookCallerSession) SwapOrders

func (_OrderBook *OrderBookCallerSession) SwapOrders(arg0 common.Address, arg1 *big.Int) (struct {
	Account               common.Address
	AmountIn              *big.Int
	MinOut                *big.Int
	TriggerRatio          *big.Int
	TriggerAboveThreshold bool
	ShouldUnwrap          bool
	ExecutionFee          *big.Int
}, error)

SwapOrders is a free data retrieval call binding the contract method 0x79221fa2.

Solidity: function swapOrders(address , uint256 ) view returns(address account, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookCallerSession) SwapOrdersIndex

func (_OrderBook *OrderBookCallerSession) SwapOrdersIndex(arg0 common.Address) (*big.Int, error)

SwapOrdersIndex is a free data retrieval call binding the contract method 0x00cf066b.

Solidity: function swapOrdersIndex(address ) view returns(uint256)

func (*OrderBookCallerSession) USDGPRECISION

func (_OrderBook *OrderBookCallerSession) USDGPRECISION() (*big.Int, error)

USDGPRECISION is a free data retrieval call binding the contract method 0x4a686d67.

Solidity: function USDG_PRECISION() view returns(uint256)

func (*OrderBookCallerSession) Usdg

func (_OrderBook *OrderBookCallerSession) Usdg() (common.Address, error)

Usdg is a free data retrieval call binding the contract method 0xf5b91b7b.

Solidity: function usdg() view returns(address)

func (*OrderBookCallerSession) ValidatePositionOrderPrice

func (_OrderBook *OrderBookCallerSession) ValidatePositionOrderPrice(_triggerAboveThreshold bool, _triggerPrice *big.Int, _indexToken common.Address, _maximizePrice bool, _raise bool) (*big.Int, bool, error)

ValidatePositionOrderPrice is a free data retrieval call binding the contract method 0x4c54f0b0.

Solidity: function validatePositionOrderPrice(bool _triggerAboveThreshold, uint256 _triggerPrice, address _indexToken, bool _maximizePrice, bool _raise) view returns(uint256, bool)

func (*OrderBookCallerSession) ValidateSwapOrderPriceWithTriggerAboveThreshold

func (_OrderBook *OrderBookCallerSession) ValidateSwapOrderPriceWithTriggerAboveThreshold(_path []common.Address, _triggerRatio *big.Int) (bool, error)

ValidateSwapOrderPriceWithTriggerAboveThreshold is a free data retrieval call binding the contract method 0xc4a1821b.

Solidity: function validateSwapOrderPriceWithTriggerAboveThreshold(address[] _path, uint256 _triggerRatio) view returns(bool)

func (*OrderBookCallerSession) Vault

func (_OrderBook *OrderBookCallerSession) Vault() (common.Address, error)

Vault is a free data retrieval call binding the contract method 0xfbfa77cf.

Solidity: function vault() view returns(address)

func (*OrderBookCallerSession) Weth

func (_OrderBook *OrderBookCallerSession) Weth() (common.Address, error)

Weth is a free data retrieval call binding the contract method 0x3fc8cef3.

Solidity: function weth() view returns(address)

type OrderBookCancelDecreaseOrder

type OrderBookCancelDecreaseOrder struct {
	Account               common.Address
	OrderIndex            *big.Int
	CollateralToken       common.Address
	CollateralDelta       *big.Int
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
	Raw                   types.Log // Blockchain specific contextual infos
}

OrderBookCancelDecreaseOrder represents a CancelDecreaseOrder event raised by the OrderBook contract.

type OrderBookCancelDecreaseOrderIterator

type OrderBookCancelDecreaseOrderIterator struct {
	Event *OrderBookCancelDecreaseOrder // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookCancelDecreaseOrderIterator is returned from FilterCancelDecreaseOrder and is used to iterate over the raw logs and unpacked data for CancelDecreaseOrder events raised by the OrderBook contract.

func (*OrderBookCancelDecreaseOrderIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookCancelDecreaseOrderIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookCancelDecreaseOrderIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookCancelIncreaseOrder

type OrderBookCancelIncreaseOrder struct {
	Account               common.Address
	OrderIndex            *big.Int
	PurchaseToken         common.Address
	PurchaseTokenAmount   *big.Int
	CollateralToken       common.Address
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
	Raw                   types.Log // Blockchain specific contextual infos
}

OrderBookCancelIncreaseOrder represents a CancelIncreaseOrder event raised by the OrderBook contract.

type OrderBookCancelIncreaseOrderIterator

type OrderBookCancelIncreaseOrderIterator struct {
	Event *OrderBookCancelIncreaseOrder // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookCancelIncreaseOrderIterator is returned from FilterCancelIncreaseOrder and is used to iterate over the raw logs and unpacked data for CancelIncreaseOrder events raised by the OrderBook contract.

func (*OrderBookCancelIncreaseOrderIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookCancelIncreaseOrderIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookCancelIncreaseOrderIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookCancelSwapOrder

type OrderBookCancelSwapOrder struct {
	Account               common.Address
	OrderIndex            *big.Int
	Path                  []common.Address
	AmountIn              *big.Int
	MinOut                *big.Int
	TriggerRatio          *big.Int
	TriggerAboveThreshold bool
	ShouldUnwrap          bool
	ExecutionFee          *big.Int
	Raw                   types.Log // Blockchain specific contextual infos
}

OrderBookCancelSwapOrder represents a CancelSwapOrder event raised by the OrderBook contract.

type OrderBookCancelSwapOrderIterator

type OrderBookCancelSwapOrderIterator struct {
	Event *OrderBookCancelSwapOrder // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookCancelSwapOrderIterator is returned from FilterCancelSwapOrder and is used to iterate over the raw logs and unpacked data for CancelSwapOrder events raised by the OrderBook contract.

func (*OrderBookCancelSwapOrderIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookCancelSwapOrderIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookCancelSwapOrderIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookCreateDecreaseOrder

type OrderBookCreateDecreaseOrder struct {
	Account               common.Address
	OrderIndex            *big.Int
	CollateralToken       common.Address
	CollateralDelta       *big.Int
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
	Raw                   types.Log // Blockchain specific contextual infos
}

OrderBookCreateDecreaseOrder represents a CreateDecreaseOrder event raised by the OrderBook contract.

type OrderBookCreateDecreaseOrderIterator

type OrderBookCreateDecreaseOrderIterator struct {
	Event *OrderBookCreateDecreaseOrder // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookCreateDecreaseOrderIterator is returned from FilterCreateDecreaseOrder and is used to iterate over the raw logs and unpacked data for CreateDecreaseOrder events raised by the OrderBook contract.

func (*OrderBookCreateDecreaseOrderIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookCreateDecreaseOrderIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookCreateDecreaseOrderIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookCreateIncreaseOrder

type OrderBookCreateIncreaseOrder struct {
	Account               common.Address
	OrderIndex            *big.Int
	PurchaseToken         common.Address
	PurchaseTokenAmount   *big.Int
	CollateralToken       common.Address
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
	Raw                   types.Log // Blockchain specific contextual infos
}

OrderBookCreateIncreaseOrder represents a CreateIncreaseOrder event raised by the OrderBook contract.

type OrderBookCreateIncreaseOrderIterator

type OrderBookCreateIncreaseOrderIterator struct {
	Event *OrderBookCreateIncreaseOrder // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookCreateIncreaseOrderIterator is returned from FilterCreateIncreaseOrder and is used to iterate over the raw logs and unpacked data for CreateIncreaseOrder events raised by the OrderBook contract.

func (*OrderBookCreateIncreaseOrderIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookCreateIncreaseOrderIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookCreateIncreaseOrderIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookCreateSwapOrder

type OrderBookCreateSwapOrder struct {
	Account               common.Address
	OrderIndex            *big.Int
	Path                  []common.Address
	AmountIn              *big.Int
	MinOut                *big.Int
	TriggerRatio          *big.Int
	TriggerAboveThreshold bool
	ShouldUnwrap          bool
	ExecutionFee          *big.Int
	Raw                   types.Log // Blockchain specific contextual infos
}

OrderBookCreateSwapOrder represents a CreateSwapOrder event raised by the OrderBook contract.

type OrderBookCreateSwapOrderIterator

type OrderBookCreateSwapOrderIterator struct {
	Event *OrderBookCreateSwapOrder // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookCreateSwapOrderIterator is returned from FilterCreateSwapOrder and is used to iterate over the raw logs and unpacked data for CreateSwapOrder events raised by the OrderBook contract.

func (*OrderBookCreateSwapOrderIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookCreateSwapOrderIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookCreateSwapOrderIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookExecuteDecreaseOrder

type OrderBookExecuteDecreaseOrder struct {
	Account               common.Address
	OrderIndex            *big.Int
	CollateralToken       common.Address
	CollateralDelta       *big.Int
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
	ExecutionPrice        *big.Int
	Raw                   types.Log // Blockchain specific contextual infos
}

OrderBookExecuteDecreaseOrder represents a ExecuteDecreaseOrder event raised by the OrderBook contract.

type OrderBookExecuteDecreaseOrderIterator

type OrderBookExecuteDecreaseOrderIterator struct {
	Event *OrderBookExecuteDecreaseOrder // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookExecuteDecreaseOrderIterator is returned from FilterExecuteDecreaseOrder and is used to iterate over the raw logs and unpacked data for ExecuteDecreaseOrder events raised by the OrderBook contract.

func (*OrderBookExecuteDecreaseOrderIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookExecuteDecreaseOrderIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookExecuteDecreaseOrderIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookExecuteIncreaseOrder

type OrderBookExecuteIncreaseOrder struct {
	Account               common.Address
	OrderIndex            *big.Int
	PurchaseToken         common.Address
	PurchaseTokenAmount   *big.Int
	CollateralToken       common.Address
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
	ExecutionPrice        *big.Int
	Raw                   types.Log // Blockchain specific contextual infos
}

OrderBookExecuteIncreaseOrder represents a ExecuteIncreaseOrder event raised by the OrderBook contract.

type OrderBookExecuteIncreaseOrderIterator

type OrderBookExecuteIncreaseOrderIterator struct {
	Event *OrderBookExecuteIncreaseOrder // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookExecuteIncreaseOrderIterator is returned from FilterExecuteIncreaseOrder and is used to iterate over the raw logs and unpacked data for ExecuteIncreaseOrder events raised by the OrderBook contract.

func (*OrderBookExecuteIncreaseOrderIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookExecuteIncreaseOrderIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookExecuteIncreaseOrderIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookExecuteSwapOrder

type OrderBookExecuteSwapOrder struct {
	Account               common.Address
	OrderIndex            *big.Int
	Path                  []common.Address
	AmountIn              *big.Int
	MinOut                *big.Int
	AmountOut             *big.Int
	TriggerRatio          *big.Int
	TriggerAboveThreshold bool
	ShouldUnwrap          bool
	ExecutionFee          *big.Int
	Raw                   types.Log // Blockchain specific contextual infos
}

OrderBookExecuteSwapOrder represents a ExecuteSwapOrder event raised by the OrderBook contract.

type OrderBookExecuteSwapOrderIterator

type OrderBookExecuteSwapOrderIterator struct {
	Event *OrderBookExecuteSwapOrder // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookExecuteSwapOrderIterator is returned from FilterExecuteSwapOrder and is used to iterate over the raw logs and unpacked data for ExecuteSwapOrder events raised by the OrderBook contract.

func (*OrderBookExecuteSwapOrderIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookExecuteSwapOrderIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookExecuteSwapOrderIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookFilterer

type OrderBookFilterer struct {
	// contains filtered or unexported fields
}

OrderBookFilterer is an auto generated log filtering Go binding around an Ethereum contract events.

func NewOrderBookFilterer

func NewOrderBookFilterer(address common.Address, filterer bind.ContractFilterer) (*OrderBookFilterer, error)

NewOrderBookFilterer creates a new log filterer instance of OrderBook, bound to a specific deployed contract.

func (*OrderBookFilterer) FilterCancelDecreaseOrder

func (_OrderBook *OrderBookFilterer) FilterCancelDecreaseOrder(opts *bind.FilterOpts, account []common.Address) (*OrderBookCancelDecreaseOrderIterator, error)

FilterCancelDecreaseOrder is a free log retrieval operation binding the contract event 0x1154174c82984656b028c8021671988f60a346497e56fe02554761184f82a075.

Solidity: event CancelDecreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookFilterer) FilterCancelIncreaseOrder

func (_OrderBook *OrderBookFilterer) FilterCancelIncreaseOrder(opts *bind.FilterOpts, account []common.Address) (*OrderBookCancelIncreaseOrderIterator, error)

FilterCancelIncreaseOrder is a free log retrieval operation binding the contract event 0xd500f34e0ec655b7614ae42e1d9c666d5e4dde909a1297829f8c5ecf00805d32.

Solidity: event CancelIncreaseOrder(address indexed account, uint256 orderIndex, address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookFilterer) FilterCancelSwapOrder

func (_OrderBook *OrderBookFilterer) FilterCancelSwapOrder(opts *bind.FilterOpts, account []common.Address) (*OrderBookCancelSwapOrderIterator, error)

FilterCancelSwapOrder is a free log retrieval operation binding the contract event 0xefd66d4f9c2f880c70aedeb5b26a44fb474cea07e5d6c533f2d27c303d5d9453.

Solidity: event CancelSwapOrder(address indexed account, uint256 orderIndex, address[] path, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookFilterer) FilterCreateDecreaseOrder

func (_OrderBook *OrderBookFilterer) FilterCreateDecreaseOrder(opts *bind.FilterOpts, account []common.Address) (*OrderBookCreateDecreaseOrderIterator, error)

FilterCreateDecreaseOrder is a free log retrieval operation binding the contract event 0x48ee333d2a65cc45fdb83bc012920d89181c3377390cd239d2b63f2bef67a02d.

Solidity: event CreateDecreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookFilterer) FilterCreateIncreaseOrder

func (_OrderBook *OrderBookFilterer) FilterCreateIncreaseOrder(opts *bind.FilterOpts, account []common.Address) (*OrderBookCreateIncreaseOrderIterator, error)

FilterCreateIncreaseOrder is a free log retrieval operation binding the contract event 0xb27b9afe3043b93788c40cfc3cc73f5d928a2e40f3ba01820b246426de8fa1b9.

Solidity: event CreateIncreaseOrder(address indexed account, uint256 orderIndex, address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookFilterer) FilterCreateSwapOrder

func (_OrderBook *OrderBookFilterer) FilterCreateSwapOrder(opts *bind.FilterOpts, account []common.Address) (*OrderBookCreateSwapOrderIterator, error)

FilterCreateSwapOrder is a free log retrieval operation binding the contract event 0xdf06bb56ffc4029dc0b62b68bb5bbadea93a38b530cefc9b81afb742a6555d88.

Solidity: event CreateSwapOrder(address indexed account, uint256 orderIndex, address[] path, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookFilterer) FilterExecuteDecreaseOrder

func (_OrderBook *OrderBookFilterer) FilterExecuteDecreaseOrder(opts *bind.FilterOpts, account []common.Address) (*OrderBookExecuteDecreaseOrderIterator, error)

FilterExecuteDecreaseOrder is a free log retrieval operation binding the contract event 0x9a382661d6573da86db000471303be6f0b2b1bb66089b08e3c16a85d7b6e94f8.

Solidity: event ExecuteDecreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee, uint256 executionPrice)

func (*OrderBookFilterer) FilterExecuteIncreaseOrder

func (_OrderBook *OrderBookFilterer) FilterExecuteIncreaseOrder(opts *bind.FilterOpts, account []common.Address) (*OrderBookExecuteIncreaseOrderIterator, error)

FilterExecuteIncreaseOrder is a free log retrieval operation binding the contract event 0x7fb1c74d1ea6aa1c9c585e17ce8274c8ff98745e85e7459b73f87d784494f58e.

Solidity: event ExecuteIncreaseOrder(address indexed account, uint256 orderIndex, address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee, uint256 executionPrice)

func (*OrderBookFilterer) FilterExecuteSwapOrder

func (_OrderBook *OrderBookFilterer) FilterExecuteSwapOrder(opts *bind.FilterOpts, account []common.Address) (*OrderBookExecuteSwapOrderIterator, error)

FilterExecuteSwapOrder is a free log retrieval operation binding the contract event 0x7e1fe496989eea92b738a562dbf9c0ae6aa6fcf3f1ef09e95ee4f7603721706b.

Solidity: event ExecuteSwapOrder(address indexed account, uint256 orderIndex, address[] path, uint256 amountIn, uint256 minOut, uint256 amountOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookFilterer) FilterInitialize

func (_OrderBook *OrderBookFilterer) FilterInitialize(opts *bind.FilterOpts) (*OrderBookInitializeIterator, error)

FilterInitialize is a free log retrieval operation binding the contract event 0xcfb7ef8749fafc8da2af1ba3d025479ffc4e58f7dc420113e112512a3bda5963.

Solidity: event Initialize(address router, address vault, address weth, address usdg, uint256 minExecutionFee, uint256 minPurchaseTokenAmountUsd)

func (*OrderBookFilterer) FilterUpdateDecreaseOrder

func (_OrderBook *OrderBookFilterer) FilterUpdateDecreaseOrder(opts *bind.FilterOpts, account []common.Address) (*OrderBookUpdateDecreaseOrderIterator, error)

FilterUpdateDecreaseOrder is a free log retrieval operation binding the contract event 0x75781255bc71c83f89f29e5a2599f2c174a562d2cd8f2e818a47f132e7280498.

Solidity: event UpdateDecreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold)

func (*OrderBookFilterer) FilterUpdateGov

func (_OrderBook *OrderBookFilterer) FilterUpdateGov(opts *bind.FilterOpts) (*OrderBookUpdateGovIterator, error)

FilterUpdateGov is a free log retrieval operation binding the contract event 0xe24c39186e9137521953beaa8446e71f55b8f12296984f9d4273ceb1af728d90.

Solidity: event UpdateGov(address gov)

func (*OrderBookFilterer) FilterUpdateIncreaseOrder

func (_OrderBook *OrderBookFilterer) FilterUpdateIncreaseOrder(opts *bind.FilterOpts, account []common.Address) (*OrderBookUpdateIncreaseOrderIterator, error)

FilterUpdateIncreaseOrder is a free log retrieval operation binding the contract event 0x0a0360dd5c354235bbf8d386ba3b24ef8134088e0785677de1504df219d9149a.

Solidity: event UpdateIncreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, address indexToken, bool isLong, uint256 sizeDelta, uint256 triggerPrice, bool triggerAboveThreshold)

func (*OrderBookFilterer) FilterUpdateMinExecutionFee

func (_OrderBook *OrderBookFilterer) FilterUpdateMinExecutionFee(opts *bind.FilterOpts) (*OrderBookUpdateMinExecutionFeeIterator, error)

FilterUpdateMinExecutionFee is a free log retrieval operation binding the contract event 0xbde5eafdc37b81830d70124cddccaaa6d034e71dda3c8fc18a959ca76a7cbcfc.

Solidity: event UpdateMinExecutionFee(uint256 minExecutionFee)

func (*OrderBookFilterer) FilterUpdateMinPurchaseTokenAmountUsd

func (_OrderBook *OrderBookFilterer) FilterUpdateMinPurchaseTokenAmountUsd(opts *bind.FilterOpts) (*OrderBookUpdateMinPurchaseTokenAmountUsdIterator, error)

FilterUpdateMinPurchaseTokenAmountUsd is a free log retrieval operation binding the contract event 0xe46d9daf6d25f7615efa1d0183b90ac6759d85014b598e409aadf0fd918d59a6.

Solidity: event UpdateMinPurchaseTokenAmountUsd(uint256 minPurchaseTokenAmountUsd)

func (*OrderBookFilterer) FilterUpdateSwapOrder

func (_OrderBook *OrderBookFilterer) FilterUpdateSwapOrder(opts *bind.FilterOpts, account []common.Address) (*OrderBookUpdateSwapOrderIterator, error)

FilterUpdateSwapOrder is a free log retrieval operation binding the contract event 0xa7f9f4a25eb76f5ec01b1a429d95d6a00833f0f137c88827c58799a1c1ff0dfe.

Solidity: event UpdateSwapOrder(address indexed account, uint256 ordexIndex, address[] path, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookFilterer) ParseCancelDecreaseOrder

func (_OrderBook *OrderBookFilterer) ParseCancelDecreaseOrder(log types.Log) (*OrderBookCancelDecreaseOrder, error)

ParseCancelDecreaseOrder is a log parse operation binding the contract event 0x1154174c82984656b028c8021671988f60a346497e56fe02554761184f82a075.

Solidity: event CancelDecreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookFilterer) ParseCancelIncreaseOrder

func (_OrderBook *OrderBookFilterer) ParseCancelIncreaseOrder(log types.Log) (*OrderBookCancelIncreaseOrder, error)

ParseCancelIncreaseOrder is a log parse operation binding the contract event 0xd500f34e0ec655b7614ae42e1d9c666d5e4dde909a1297829f8c5ecf00805d32.

Solidity: event CancelIncreaseOrder(address indexed account, uint256 orderIndex, address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookFilterer) ParseCancelSwapOrder

func (_OrderBook *OrderBookFilterer) ParseCancelSwapOrder(log types.Log) (*OrderBookCancelSwapOrder, error)

ParseCancelSwapOrder is a log parse operation binding the contract event 0xefd66d4f9c2f880c70aedeb5b26a44fb474cea07e5d6c533f2d27c303d5d9453.

Solidity: event CancelSwapOrder(address indexed account, uint256 orderIndex, address[] path, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookFilterer) ParseCreateDecreaseOrder

func (_OrderBook *OrderBookFilterer) ParseCreateDecreaseOrder(log types.Log) (*OrderBookCreateDecreaseOrder, error)

ParseCreateDecreaseOrder is a log parse operation binding the contract event 0x48ee333d2a65cc45fdb83bc012920d89181c3377390cd239d2b63f2bef67a02d.

Solidity: event CreateDecreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookFilterer) ParseCreateIncreaseOrder

func (_OrderBook *OrderBookFilterer) ParseCreateIncreaseOrder(log types.Log) (*OrderBookCreateIncreaseOrder, error)

ParseCreateIncreaseOrder is a log parse operation binding the contract event 0xb27b9afe3043b93788c40cfc3cc73f5d928a2e40f3ba01820b246426de8fa1b9.

Solidity: event CreateIncreaseOrder(address indexed account, uint256 orderIndex, address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookFilterer) ParseCreateSwapOrder

func (_OrderBook *OrderBookFilterer) ParseCreateSwapOrder(log types.Log) (*OrderBookCreateSwapOrder, error)

ParseCreateSwapOrder is a log parse operation binding the contract event 0xdf06bb56ffc4029dc0b62b68bb5bbadea93a38b530cefc9b81afb742a6555d88.

Solidity: event CreateSwapOrder(address indexed account, uint256 orderIndex, address[] path, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookFilterer) ParseExecuteDecreaseOrder

func (_OrderBook *OrderBookFilterer) ParseExecuteDecreaseOrder(log types.Log) (*OrderBookExecuteDecreaseOrder, error)

ParseExecuteDecreaseOrder is a log parse operation binding the contract event 0x9a382661d6573da86db000471303be6f0b2b1bb66089b08e3c16a85d7b6e94f8.

Solidity: event ExecuteDecreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee, uint256 executionPrice)

func (*OrderBookFilterer) ParseExecuteIncreaseOrder

func (_OrderBook *OrderBookFilterer) ParseExecuteIncreaseOrder(log types.Log) (*OrderBookExecuteIncreaseOrder, error)

ParseExecuteIncreaseOrder is a log parse operation binding the contract event 0x7fb1c74d1ea6aa1c9c585e17ce8274c8ff98745e85e7459b73f87d784494f58e.

Solidity: event ExecuteIncreaseOrder(address indexed account, uint256 orderIndex, address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee, uint256 executionPrice)

func (*OrderBookFilterer) ParseExecuteSwapOrder

func (_OrderBook *OrderBookFilterer) ParseExecuteSwapOrder(log types.Log) (*OrderBookExecuteSwapOrder, error)

ParseExecuteSwapOrder is a log parse operation binding the contract event 0x7e1fe496989eea92b738a562dbf9c0ae6aa6fcf3f1ef09e95ee4f7603721706b.

Solidity: event ExecuteSwapOrder(address indexed account, uint256 orderIndex, address[] path, uint256 amountIn, uint256 minOut, uint256 amountOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookFilterer) ParseInitialize

func (_OrderBook *OrderBookFilterer) ParseInitialize(log types.Log) (*OrderBookInitialize, error)

ParseInitialize is a log parse operation binding the contract event 0xcfb7ef8749fafc8da2af1ba3d025479ffc4e58f7dc420113e112512a3bda5963.

Solidity: event Initialize(address router, address vault, address weth, address usdg, uint256 minExecutionFee, uint256 minPurchaseTokenAmountUsd)

func (*OrderBookFilterer) ParseUpdateDecreaseOrder

func (_OrderBook *OrderBookFilterer) ParseUpdateDecreaseOrder(log types.Log) (*OrderBookUpdateDecreaseOrder, error)

ParseUpdateDecreaseOrder is a log parse operation binding the contract event 0x75781255bc71c83f89f29e5a2599f2c174a562d2cd8f2e818a47f132e7280498.

Solidity: event UpdateDecreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold)

func (*OrderBookFilterer) ParseUpdateGov

func (_OrderBook *OrderBookFilterer) ParseUpdateGov(log types.Log) (*OrderBookUpdateGov, error)

ParseUpdateGov is a log parse operation binding the contract event 0xe24c39186e9137521953beaa8446e71f55b8f12296984f9d4273ceb1af728d90.

Solidity: event UpdateGov(address gov)

func (*OrderBookFilterer) ParseUpdateIncreaseOrder

func (_OrderBook *OrderBookFilterer) ParseUpdateIncreaseOrder(log types.Log) (*OrderBookUpdateIncreaseOrder, error)

ParseUpdateIncreaseOrder is a log parse operation binding the contract event 0x0a0360dd5c354235bbf8d386ba3b24ef8134088e0785677de1504df219d9149a.

Solidity: event UpdateIncreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, address indexToken, bool isLong, uint256 sizeDelta, uint256 triggerPrice, bool triggerAboveThreshold)

func (*OrderBookFilterer) ParseUpdateMinExecutionFee

func (_OrderBook *OrderBookFilterer) ParseUpdateMinExecutionFee(log types.Log) (*OrderBookUpdateMinExecutionFee, error)

ParseUpdateMinExecutionFee is a log parse operation binding the contract event 0xbde5eafdc37b81830d70124cddccaaa6d034e71dda3c8fc18a959ca76a7cbcfc.

Solidity: event UpdateMinExecutionFee(uint256 minExecutionFee)

func (*OrderBookFilterer) ParseUpdateMinPurchaseTokenAmountUsd

func (_OrderBook *OrderBookFilterer) ParseUpdateMinPurchaseTokenAmountUsd(log types.Log) (*OrderBookUpdateMinPurchaseTokenAmountUsd, error)

ParseUpdateMinPurchaseTokenAmountUsd is a log parse operation binding the contract event 0xe46d9daf6d25f7615efa1d0183b90ac6759d85014b598e409aadf0fd918d59a6.

Solidity: event UpdateMinPurchaseTokenAmountUsd(uint256 minPurchaseTokenAmountUsd)

func (*OrderBookFilterer) ParseUpdateSwapOrder

func (_OrderBook *OrderBookFilterer) ParseUpdateSwapOrder(log types.Log) (*OrderBookUpdateSwapOrder, error)

ParseUpdateSwapOrder is a log parse operation binding the contract event 0xa7f9f4a25eb76f5ec01b1a429d95d6a00833f0f137c88827c58799a1c1ff0dfe.

Solidity: event UpdateSwapOrder(address indexed account, uint256 ordexIndex, address[] path, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookFilterer) WatchCancelDecreaseOrder

func (_OrderBook *OrderBookFilterer) WatchCancelDecreaseOrder(opts *bind.WatchOpts, sink chan<- *OrderBookCancelDecreaseOrder, account []common.Address) (event.Subscription, error)

WatchCancelDecreaseOrder is a free log subscription operation binding the contract event 0x1154174c82984656b028c8021671988f60a346497e56fe02554761184f82a075.

Solidity: event CancelDecreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookFilterer) WatchCancelIncreaseOrder

func (_OrderBook *OrderBookFilterer) WatchCancelIncreaseOrder(opts *bind.WatchOpts, sink chan<- *OrderBookCancelIncreaseOrder, account []common.Address) (event.Subscription, error)

WatchCancelIncreaseOrder is a free log subscription operation binding the contract event 0xd500f34e0ec655b7614ae42e1d9c666d5e4dde909a1297829f8c5ecf00805d32.

Solidity: event CancelIncreaseOrder(address indexed account, uint256 orderIndex, address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookFilterer) WatchCancelSwapOrder

func (_OrderBook *OrderBookFilterer) WatchCancelSwapOrder(opts *bind.WatchOpts, sink chan<- *OrderBookCancelSwapOrder, account []common.Address) (event.Subscription, error)

WatchCancelSwapOrder is a free log subscription operation binding the contract event 0xefd66d4f9c2f880c70aedeb5b26a44fb474cea07e5d6c533f2d27c303d5d9453.

Solidity: event CancelSwapOrder(address indexed account, uint256 orderIndex, address[] path, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookFilterer) WatchCreateDecreaseOrder

func (_OrderBook *OrderBookFilterer) WatchCreateDecreaseOrder(opts *bind.WatchOpts, sink chan<- *OrderBookCreateDecreaseOrder, account []common.Address) (event.Subscription, error)

WatchCreateDecreaseOrder is a free log subscription operation binding the contract event 0x48ee333d2a65cc45fdb83bc012920d89181c3377390cd239d2b63f2bef67a02d.

Solidity: event CreateDecreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookFilterer) WatchCreateIncreaseOrder

func (_OrderBook *OrderBookFilterer) WatchCreateIncreaseOrder(opts *bind.WatchOpts, sink chan<- *OrderBookCreateIncreaseOrder, account []common.Address) (event.Subscription, error)

WatchCreateIncreaseOrder is a free log subscription operation binding the contract event 0xb27b9afe3043b93788c40cfc3cc73f5d928a2e40f3ba01820b246426de8fa1b9.

Solidity: event CreateIncreaseOrder(address indexed account, uint256 orderIndex, address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookFilterer) WatchCreateSwapOrder

func (_OrderBook *OrderBookFilterer) WatchCreateSwapOrder(opts *bind.WatchOpts, sink chan<- *OrderBookCreateSwapOrder, account []common.Address) (event.Subscription, error)

WatchCreateSwapOrder is a free log subscription operation binding the contract event 0xdf06bb56ffc4029dc0b62b68bb5bbadea93a38b530cefc9b81afb742a6555d88.

Solidity: event CreateSwapOrder(address indexed account, uint256 orderIndex, address[] path, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookFilterer) WatchExecuteDecreaseOrder

func (_OrderBook *OrderBookFilterer) WatchExecuteDecreaseOrder(opts *bind.WatchOpts, sink chan<- *OrderBookExecuteDecreaseOrder, account []common.Address) (event.Subscription, error)

WatchExecuteDecreaseOrder is a free log subscription operation binding the contract event 0x9a382661d6573da86db000471303be6f0b2b1bb66089b08e3c16a85d7b6e94f8.

Solidity: event ExecuteDecreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee, uint256 executionPrice)

func (*OrderBookFilterer) WatchExecuteIncreaseOrder

func (_OrderBook *OrderBookFilterer) WatchExecuteIncreaseOrder(opts *bind.WatchOpts, sink chan<- *OrderBookExecuteIncreaseOrder, account []common.Address) (event.Subscription, error)

WatchExecuteIncreaseOrder is a free log subscription operation binding the contract event 0x7fb1c74d1ea6aa1c9c585e17ce8274c8ff98745e85e7459b73f87d784494f58e.

Solidity: event ExecuteIncreaseOrder(address indexed account, uint256 orderIndex, address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee, uint256 executionPrice)

func (*OrderBookFilterer) WatchExecuteSwapOrder

func (_OrderBook *OrderBookFilterer) WatchExecuteSwapOrder(opts *bind.WatchOpts, sink chan<- *OrderBookExecuteSwapOrder, account []common.Address) (event.Subscription, error)

WatchExecuteSwapOrder is a free log subscription operation binding the contract event 0x7e1fe496989eea92b738a562dbf9c0ae6aa6fcf3f1ef09e95ee4f7603721706b.

Solidity: event ExecuteSwapOrder(address indexed account, uint256 orderIndex, address[] path, uint256 amountIn, uint256 minOut, uint256 amountOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookFilterer) WatchInitialize

func (_OrderBook *OrderBookFilterer) WatchInitialize(opts *bind.WatchOpts, sink chan<- *OrderBookInitialize) (event.Subscription, error)

WatchInitialize is a free log subscription operation binding the contract event 0xcfb7ef8749fafc8da2af1ba3d025479ffc4e58f7dc420113e112512a3bda5963.

Solidity: event Initialize(address router, address vault, address weth, address usdg, uint256 minExecutionFee, uint256 minPurchaseTokenAmountUsd)

func (*OrderBookFilterer) WatchUpdateDecreaseOrder

func (_OrderBook *OrderBookFilterer) WatchUpdateDecreaseOrder(opts *bind.WatchOpts, sink chan<- *OrderBookUpdateDecreaseOrder, account []common.Address) (event.Subscription, error)

WatchUpdateDecreaseOrder is a free log subscription operation binding the contract event 0x75781255bc71c83f89f29e5a2599f2c174a562d2cd8f2e818a47f132e7280498.

Solidity: event UpdateDecreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold)

func (*OrderBookFilterer) WatchUpdateGov

func (_OrderBook *OrderBookFilterer) WatchUpdateGov(opts *bind.WatchOpts, sink chan<- *OrderBookUpdateGov) (event.Subscription, error)

WatchUpdateGov is a free log subscription operation binding the contract event 0xe24c39186e9137521953beaa8446e71f55b8f12296984f9d4273ceb1af728d90.

Solidity: event UpdateGov(address gov)

func (*OrderBookFilterer) WatchUpdateIncreaseOrder

func (_OrderBook *OrderBookFilterer) WatchUpdateIncreaseOrder(opts *bind.WatchOpts, sink chan<- *OrderBookUpdateIncreaseOrder, account []common.Address) (event.Subscription, error)

WatchUpdateIncreaseOrder is a free log subscription operation binding the contract event 0x0a0360dd5c354235bbf8d386ba3b24ef8134088e0785677de1504df219d9149a.

Solidity: event UpdateIncreaseOrder(address indexed account, uint256 orderIndex, address collateralToken, address indexToken, bool isLong, uint256 sizeDelta, uint256 triggerPrice, bool triggerAboveThreshold)

func (*OrderBookFilterer) WatchUpdateMinExecutionFee

func (_OrderBook *OrderBookFilterer) WatchUpdateMinExecutionFee(opts *bind.WatchOpts, sink chan<- *OrderBookUpdateMinExecutionFee) (event.Subscription, error)

WatchUpdateMinExecutionFee is a free log subscription operation binding the contract event 0xbde5eafdc37b81830d70124cddccaaa6d034e71dda3c8fc18a959ca76a7cbcfc.

Solidity: event UpdateMinExecutionFee(uint256 minExecutionFee)

func (*OrderBookFilterer) WatchUpdateMinPurchaseTokenAmountUsd

func (_OrderBook *OrderBookFilterer) WatchUpdateMinPurchaseTokenAmountUsd(opts *bind.WatchOpts, sink chan<- *OrderBookUpdateMinPurchaseTokenAmountUsd) (event.Subscription, error)

WatchUpdateMinPurchaseTokenAmountUsd is a free log subscription operation binding the contract event 0xe46d9daf6d25f7615efa1d0183b90ac6759d85014b598e409aadf0fd918d59a6.

Solidity: event UpdateMinPurchaseTokenAmountUsd(uint256 minPurchaseTokenAmountUsd)

func (*OrderBookFilterer) WatchUpdateSwapOrder

func (_OrderBook *OrderBookFilterer) WatchUpdateSwapOrder(opts *bind.WatchOpts, sink chan<- *OrderBookUpdateSwapOrder, account []common.Address) (event.Subscription, error)

WatchUpdateSwapOrder is a free log subscription operation binding the contract event 0xa7f9f4a25eb76f5ec01b1a429d95d6a00833f0f137c88827c58799a1c1ff0dfe.

Solidity: event UpdateSwapOrder(address indexed account, uint256 ordexIndex, address[] path, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

type OrderBookInitialize

type OrderBookInitialize struct {
	Router                    common.Address
	Vault                     common.Address
	Weth                      common.Address
	Usdg                      common.Address
	MinExecutionFee           *big.Int
	MinPurchaseTokenAmountUsd *big.Int
	Raw                       types.Log // Blockchain specific contextual infos
}

OrderBookInitialize represents a Initialize event raised by the OrderBook contract.

type OrderBookInitializeIterator

type OrderBookInitializeIterator struct {
	Event *OrderBookInitialize // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookInitializeIterator is returned from FilterInitialize and is used to iterate over the raw logs and unpacked data for Initialize events raised by the OrderBook contract.

func (*OrderBookInitializeIterator) Close

func (it *OrderBookInitializeIterator) Close() error

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookInitializeIterator) Error

func (it *OrderBookInitializeIterator) Error() error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookInitializeIterator) Next

func (it *OrderBookInitializeIterator) Next() bool

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookRaw

type OrderBookRaw struct {
	Contract *OrderBook // Generic contract binding to access the raw methods on
}

OrderBookRaw is an auto generated low-level Go binding around an Ethereum contract.

func (*OrderBookRaw) Call

func (_OrderBook *OrderBookRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error

Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.

func (*OrderBookRaw) Transact

func (_OrderBook *OrderBookRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)

Transact invokes the (paid) contract method with params as input values.

func (*OrderBookRaw) Transfer

func (_OrderBook *OrderBookRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)

Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.

type OrderBookSession

type OrderBookSession struct {
	Contract     *OrderBook        // Generic contract binding to set the session for
	CallOpts     bind.CallOpts     // Call options to use throughout this session
	TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
}

OrderBookSession is an auto generated Go binding around an Ethereum contract, with pre-set call and transact options.

func (*OrderBookSession) CancelDecreaseOrder

func (_OrderBook *OrderBookSession) CancelDecreaseOrder(_orderIndex *big.Int) (*types.Transaction, error)

CancelDecreaseOrder is a paid mutator transaction binding the contract method 0x9e71b0f0.

Solidity: function cancelDecreaseOrder(uint256 _orderIndex) returns()

func (*OrderBookSession) CancelIncreaseOrder

func (_OrderBook *OrderBookSession) CancelIncreaseOrder(_orderIndex *big.Int) (*types.Transaction, error)

CancelIncreaseOrder is a paid mutator transaction binding the contract method 0x47e0bbd0.

Solidity: function cancelIncreaseOrder(uint256 _orderIndex) returns()

func (*OrderBookSession) CancelMultiple

func (_OrderBook *OrderBookSession) CancelMultiple(_swapOrderIndexes []*big.Int, _increaseOrderIndexes []*big.Int, _decreaseOrderIndexes []*big.Int) (*types.Transaction, error)

CancelMultiple is a paid mutator transaction binding the contract method 0x807c5600.

Solidity: function cancelMultiple(uint256[] _swapOrderIndexes, uint256[] _increaseOrderIndexes, uint256[] _decreaseOrderIndexes) returns()

func (*OrderBookSession) CancelSwapOrder

func (_OrderBook *OrderBookSession) CancelSwapOrder(_orderIndex *big.Int) (*types.Transaction, error)

CancelSwapOrder is a paid mutator transaction binding the contract method 0xf882ac07.

Solidity: function cancelSwapOrder(uint256 _orderIndex) returns()

func (*OrderBookSession) CreateDecreaseOrder

func (_OrderBook *OrderBookSession) CreateDecreaseOrder(_indexToken common.Address, _sizeDelta *big.Int, _collateralToken common.Address, _collateralDelta *big.Int, _isLong bool, _triggerPrice *big.Int, _triggerAboveThreshold bool) (*types.Transaction, error)

CreateDecreaseOrder is a paid mutator transaction binding the contract method 0xc16cde8a.

Solidity: function createDecreaseOrder(address _indexToken, uint256 _sizeDelta, address _collateralToken, uint256 _collateralDelta, bool _isLong, uint256 _triggerPrice, bool _triggerAboveThreshold) payable returns()

func (*OrderBookSession) CreateIncreaseOrder

func (_OrderBook *OrderBookSession) CreateIncreaseOrder(_path []common.Address, _amountIn *big.Int, _indexToken common.Address, _minOut *big.Int, _sizeDelta *big.Int, _collateralToken common.Address, _isLong bool, _triggerPrice *big.Int, _triggerAboveThreshold bool, _executionFee *big.Int, _shouldWrap bool) (*types.Transaction, error)

CreateIncreaseOrder is a paid mutator transaction binding the contract method 0xb142a4b0.

Solidity: function createIncreaseOrder(address[] _path, uint256 _amountIn, address _indexToken, uint256 _minOut, uint256 _sizeDelta, address _collateralToken, bool _isLong, uint256 _triggerPrice, bool _triggerAboveThreshold, uint256 _executionFee, bool _shouldWrap) payable returns()

func (*OrderBookSession) CreateSwapOrder

func (_OrderBook *OrderBookSession) CreateSwapOrder(_path []common.Address, _amountIn *big.Int, _minOut *big.Int, _triggerRatio *big.Int, _triggerAboveThreshold bool, _executionFee *big.Int, _shouldWrap bool, _shouldUnwrap bool) (*types.Transaction, error)

CreateSwapOrder is a paid mutator transaction binding the contract method 0x269ae6c2.

Solidity: function createSwapOrder(address[] _path, uint256 _amountIn, uint256 _minOut, uint256 _triggerRatio, bool _triggerAboveThreshold, uint256 _executionFee, bool _shouldWrap, bool _shouldUnwrap) payable returns()

func (*OrderBookSession) DecreaseOrders

func (_OrderBook *OrderBookSession) DecreaseOrders(arg0 common.Address, arg1 *big.Int) (struct {
	Account               common.Address
	CollateralToken       common.Address
	CollateralDelta       *big.Int
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
}, error)

DecreaseOrders is a free data retrieval call binding the contract method 0xf2d2e01b.

Solidity: function decreaseOrders(address , uint256 ) view returns(address account, address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookSession) DecreaseOrdersIndex

func (_OrderBook *OrderBookSession) DecreaseOrdersIndex(arg0 common.Address) (*big.Int, error)

DecreaseOrdersIndex is a free data retrieval call binding the contract method 0xd566d0ca.

Solidity: function decreaseOrdersIndex(address ) view returns(uint256)

func (*OrderBookSession) ExecuteDecreaseOrder

func (_OrderBook *OrderBookSession) ExecuteDecreaseOrder(_address common.Address, _orderIndex *big.Int, _feeReceiver common.Address) (*types.Transaction, error)

ExecuteDecreaseOrder is a paid mutator transaction binding the contract method 0x11d9444a.

Solidity: function executeDecreaseOrder(address _address, uint256 _orderIndex, address _feeReceiver) returns()

func (*OrderBookSession) ExecuteIncreaseOrder

func (_OrderBook *OrderBookSession) ExecuteIncreaseOrder(_address common.Address, _orderIndex *big.Int, _feeReceiver common.Address) (*types.Transaction, error)

ExecuteIncreaseOrder is a paid mutator transaction binding the contract method 0xd38ab519.

Solidity: function executeIncreaseOrder(address _address, uint256 _orderIndex, address _feeReceiver) returns()

func (*OrderBookSession) ExecuteSwapOrder

func (_OrderBook *OrderBookSession) ExecuteSwapOrder(_account common.Address, _orderIndex *big.Int, _feeReceiver common.Address) (*types.Transaction, error)

ExecuteSwapOrder is a paid mutator transaction binding the contract method 0x07c7edc3.

Solidity: function executeSwapOrder(address _account, uint256 _orderIndex, address _feeReceiver) returns()

func (*OrderBookSession) GetDecreaseOrder

func (_OrderBook *OrderBookSession) GetDecreaseOrder(_account common.Address, _orderIndex *big.Int) (struct {
	CollateralToken       common.Address
	CollateralDelta       *big.Int
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
}, error)

GetDecreaseOrder is a free data retrieval call binding the contract method 0x026032ee.

Solidity: function getDecreaseOrder(address _account, uint256 _orderIndex) view returns(address collateralToken, uint256 collateralDelta, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookSession) GetIncreaseOrder

func (_OrderBook *OrderBookSession) GetIncreaseOrder(_account common.Address, _orderIndex *big.Int) (struct {
	PurchaseToken         common.Address
	PurchaseTokenAmount   *big.Int
	CollateralToken       common.Address
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
}, error)

GetIncreaseOrder is a free data retrieval call binding the contract method 0xd3bab1d1.

Solidity: function getIncreaseOrder(address _account, uint256 _orderIndex) view returns(address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookSession) GetSwapOrder

func (_OrderBook *OrderBookSession) GetSwapOrder(_account common.Address, _orderIndex *big.Int) (struct {
	Path0                 common.Address
	Path1                 common.Address
	Path2                 common.Address
	AmountIn              *big.Int
	MinOut                *big.Int
	TriggerRatio          *big.Int
	TriggerAboveThreshold bool
	ShouldUnwrap          bool
	ExecutionFee          *big.Int
}, error)

GetSwapOrder is a free data retrieval call binding the contract method 0xd0d40cd6.

Solidity: function getSwapOrder(address _account, uint256 _orderIndex) view returns(address path0, address path1, address path2, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookSession) GetUsdgMinPrice

func (_OrderBook *OrderBookSession) GetUsdgMinPrice(_otherToken common.Address) (*big.Int, error)

GetUsdgMinPrice is a free data retrieval call binding the contract method 0x9e23de5c.

Solidity: function getUsdgMinPrice(address _otherToken) view returns(uint256)

func (*OrderBookSession) Gov

func (_OrderBook *OrderBookSession) Gov() (common.Address, error)

Gov is a free data retrieval call binding the contract method 0x12d43a51.

Solidity: function gov() view returns(address)

func (*OrderBookSession) IncreaseOrders

func (_OrderBook *OrderBookSession) IncreaseOrders(arg0 common.Address, arg1 *big.Int) (struct {
	Account               common.Address
	PurchaseToken         common.Address
	PurchaseTokenAmount   *big.Int
	CollateralToken       common.Address
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	ExecutionFee          *big.Int
}, error)

IncreaseOrders is a free data retrieval call binding the contract method 0x2b7d6290.

Solidity: function increaseOrders(address , uint256 ) view returns(address account, address purchaseToken, uint256 purchaseTokenAmount, address collateralToken, address indexToken, uint256 sizeDelta, bool isLong, uint256 triggerPrice, bool triggerAboveThreshold, uint256 executionFee)

func (*OrderBookSession) IncreaseOrdersIndex

func (_OrderBook *OrderBookSession) IncreaseOrdersIndex(arg0 common.Address) (*big.Int, error)

IncreaseOrdersIndex is a free data retrieval call binding the contract method 0xaec22455.

Solidity: function increaseOrdersIndex(address ) view returns(uint256)

func (*OrderBookSession) Initialize

func (_OrderBook *OrderBookSession) Initialize(_router common.Address, _vault common.Address, _weth common.Address, _usdg common.Address, _minExecutionFee *big.Int, _minPurchaseTokenAmountUsd *big.Int) (*types.Transaction, error)

Initialize is a paid mutator transaction binding the contract method 0xd7c41c79.

Solidity: function initialize(address _router, address _vault, address _weth, address _usdg, uint256 _minExecutionFee, uint256 _minPurchaseTokenAmountUsd) returns()

func (*OrderBookSession) IsInitialized

func (_OrderBook *OrderBookSession) IsInitialized() (bool, error)

IsInitialized is a free data retrieval call binding the contract method 0x392e53cd.

Solidity: function isInitialized() view returns(bool)

func (*OrderBookSession) MinExecutionFee

func (_OrderBook *OrderBookSession) MinExecutionFee() (*big.Int, error)

MinExecutionFee is a free data retrieval call binding the contract method 0x63ae2103.

Solidity: function minExecutionFee() view returns(uint256)

func (*OrderBookSession) MinPurchaseTokenAmountUsd

func (_OrderBook *OrderBookSession) MinPurchaseTokenAmountUsd() (*big.Int, error)

MinPurchaseTokenAmountUsd is a free data retrieval call binding the contract method 0x8de10c2e.

Solidity: function minPurchaseTokenAmountUsd() view returns(uint256)

func (*OrderBookSession) PRICEPRECISION

func (_OrderBook *OrderBookSession) PRICEPRECISION() (*big.Int, error)

PRICEPRECISION is a free data retrieval call binding the contract method 0x95082d25.

Solidity: function PRICE_PRECISION() view returns(uint256)

func (*OrderBookSession) Receive

func (_OrderBook *OrderBookSession) Receive() (*types.Transaction, error)

Receive is a paid mutator transaction binding the contract receive function.

Solidity: receive() payable returns()

func (*OrderBookSession) Router

func (_OrderBook *OrderBookSession) Router() (common.Address, error)

Router is a free data retrieval call binding the contract method 0xf887ea40.

Solidity: function router() view returns(address)

func (*OrderBookSession) SetGov

func (_OrderBook *OrderBookSession) SetGov(_gov common.Address) (*types.Transaction, error)

SetGov is a paid mutator transaction binding the contract method 0xcfad57a2.

Solidity: function setGov(address _gov) returns()

func (*OrderBookSession) SetMinExecutionFee

func (_OrderBook *OrderBookSession) SetMinExecutionFee(_minExecutionFee *big.Int) (*types.Transaction, error)

SetMinExecutionFee is a paid mutator transaction binding the contract method 0xfc2cee62.

Solidity: function setMinExecutionFee(uint256 _minExecutionFee) returns()

func (*OrderBookSession) SetMinPurchaseTokenAmountUsd

func (_OrderBook *OrderBookSession) SetMinPurchaseTokenAmountUsd(_minPurchaseTokenAmountUsd *big.Int) (*types.Transaction, error)

SetMinPurchaseTokenAmountUsd is a paid mutator transaction binding the contract method 0x0d5cc938.

Solidity: function setMinPurchaseTokenAmountUsd(uint256 _minPurchaseTokenAmountUsd) returns()

func (*OrderBookSession) SwapOrders

func (_OrderBook *OrderBookSession) SwapOrders(arg0 common.Address, arg1 *big.Int) (struct {
	Account               common.Address
	AmountIn              *big.Int
	MinOut                *big.Int
	TriggerRatio          *big.Int
	TriggerAboveThreshold bool
	ShouldUnwrap          bool
	ExecutionFee          *big.Int
}, error)

SwapOrders is a free data retrieval call binding the contract method 0x79221fa2.

Solidity: function swapOrders(address , uint256 ) view returns(address account, uint256 amountIn, uint256 minOut, uint256 triggerRatio, bool triggerAboveThreshold, bool shouldUnwrap, uint256 executionFee)

func (*OrderBookSession) SwapOrdersIndex

func (_OrderBook *OrderBookSession) SwapOrdersIndex(arg0 common.Address) (*big.Int, error)

SwapOrdersIndex is a free data retrieval call binding the contract method 0x00cf066b.

Solidity: function swapOrdersIndex(address ) view returns(uint256)

func (*OrderBookSession) USDGPRECISION

func (_OrderBook *OrderBookSession) USDGPRECISION() (*big.Int, error)

USDGPRECISION is a free data retrieval call binding the contract method 0x4a686d67.

Solidity: function USDG_PRECISION() view returns(uint256)

func (*OrderBookSession) UpdateDecreaseOrder

func (_OrderBook *OrderBookSession) UpdateDecreaseOrder(_orderIndex *big.Int, _collateralDelta *big.Int, _sizeDelta *big.Int, _triggerPrice *big.Int, _triggerAboveThreshold bool) (*types.Transaction, error)

UpdateDecreaseOrder is a paid mutator transaction binding the contract method 0xa397ea54.

Solidity: function updateDecreaseOrder(uint256 _orderIndex, uint256 _collateralDelta, uint256 _sizeDelta, uint256 _triggerPrice, bool _triggerAboveThreshold) returns()

func (*OrderBookSession) UpdateIncreaseOrder

func (_OrderBook *OrderBookSession) UpdateIncreaseOrder(_orderIndex *big.Int, _sizeDelta *big.Int, _triggerPrice *big.Int, _triggerAboveThreshold bool) (*types.Transaction, error)

UpdateIncreaseOrder is a paid mutator transaction binding the contract method 0x9983ee1b.

Solidity: function updateIncreaseOrder(uint256 _orderIndex, uint256 _sizeDelta, uint256 _triggerPrice, bool _triggerAboveThreshold) returns()

func (*OrderBookSession) UpdateSwapOrder

func (_OrderBook *OrderBookSession) UpdateSwapOrder(_orderIndex *big.Int, _minOut *big.Int, _triggerRatio *big.Int, _triggerAboveThreshold bool) (*types.Transaction, error)

UpdateSwapOrder is a paid mutator transaction binding the contract method 0xc86b0f7d.

Solidity: function updateSwapOrder(uint256 _orderIndex, uint256 _minOut, uint256 _triggerRatio, bool _triggerAboveThreshold) returns()

func (*OrderBookSession) Usdg

func (_OrderBook *OrderBookSession) Usdg() (common.Address, error)

Usdg is a free data retrieval call binding the contract method 0xf5b91b7b.

Solidity: function usdg() view returns(address)

func (*OrderBookSession) ValidatePositionOrderPrice

func (_OrderBook *OrderBookSession) ValidatePositionOrderPrice(_triggerAboveThreshold bool, _triggerPrice *big.Int, _indexToken common.Address, _maximizePrice bool, _raise bool) (*big.Int, bool, error)

ValidatePositionOrderPrice is a free data retrieval call binding the contract method 0x4c54f0b0.

Solidity: function validatePositionOrderPrice(bool _triggerAboveThreshold, uint256 _triggerPrice, address _indexToken, bool _maximizePrice, bool _raise) view returns(uint256, bool)

func (*OrderBookSession) ValidateSwapOrderPriceWithTriggerAboveThreshold

func (_OrderBook *OrderBookSession) ValidateSwapOrderPriceWithTriggerAboveThreshold(_path []common.Address, _triggerRatio *big.Int) (bool, error)

ValidateSwapOrderPriceWithTriggerAboveThreshold is a free data retrieval call binding the contract method 0xc4a1821b.

Solidity: function validateSwapOrderPriceWithTriggerAboveThreshold(address[] _path, uint256 _triggerRatio) view returns(bool)

func (*OrderBookSession) Vault

func (_OrderBook *OrderBookSession) Vault() (common.Address, error)

Vault is a free data retrieval call binding the contract method 0xfbfa77cf.

Solidity: function vault() view returns(address)

func (*OrderBookSession) Weth

func (_OrderBook *OrderBookSession) Weth() (common.Address, error)

Weth is a free data retrieval call binding the contract method 0x3fc8cef3.

Solidity: function weth() view returns(address)

type OrderBookTransactor

type OrderBookTransactor struct {
	// contains filtered or unexported fields
}

OrderBookTransactor is an auto generated write-only Go binding around an Ethereum contract.

func NewOrderBookTransactor

func NewOrderBookTransactor(address common.Address, transactor bind.ContractTransactor) (*OrderBookTransactor, error)

NewOrderBookTransactor creates a new write-only instance of OrderBook, bound to a specific deployed contract.

func (*OrderBookTransactor) CancelDecreaseOrder

func (_OrderBook *OrderBookTransactor) CancelDecreaseOrder(opts *bind.TransactOpts, _orderIndex *big.Int) (*types.Transaction, error)

CancelDecreaseOrder is a paid mutator transaction binding the contract method 0x9e71b0f0.

Solidity: function cancelDecreaseOrder(uint256 _orderIndex) returns()

func (*OrderBookTransactor) CancelIncreaseOrder

func (_OrderBook *OrderBookTransactor) CancelIncreaseOrder(opts *bind.TransactOpts, _orderIndex *big.Int) (*types.Transaction, error)

CancelIncreaseOrder is a paid mutator transaction binding the contract method 0x47e0bbd0.

Solidity: function cancelIncreaseOrder(uint256 _orderIndex) returns()

func (*OrderBookTransactor) CancelMultiple

func (_OrderBook *OrderBookTransactor) CancelMultiple(opts *bind.TransactOpts, _swapOrderIndexes []*big.Int, _increaseOrderIndexes []*big.Int, _decreaseOrderIndexes []*big.Int) (*types.Transaction, error)

CancelMultiple is a paid mutator transaction binding the contract method 0x807c5600.

Solidity: function cancelMultiple(uint256[] _swapOrderIndexes, uint256[] _increaseOrderIndexes, uint256[] _decreaseOrderIndexes) returns()

func (*OrderBookTransactor) CancelSwapOrder

func (_OrderBook *OrderBookTransactor) CancelSwapOrder(opts *bind.TransactOpts, _orderIndex *big.Int) (*types.Transaction, error)

CancelSwapOrder is a paid mutator transaction binding the contract method 0xf882ac07.

Solidity: function cancelSwapOrder(uint256 _orderIndex) returns()

func (*OrderBookTransactor) CreateDecreaseOrder

func (_OrderBook *OrderBookTransactor) CreateDecreaseOrder(opts *bind.TransactOpts, _indexToken common.Address, _sizeDelta *big.Int, _collateralToken common.Address, _collateralDelta *big.Int, _isLong bool, _triggerPrice *big.Int, _triggerAboveThreshold bool) (*types.Transaction, error)

CreateDecreaseOrder is a paid mutator transaction binding the contract method 0xc16cde8a.

Solidity: function createDecreaseOrder(address _indexToken, uint256 _sizeDelta, address _collateralToken, uint256 _collateralDelta, bool _isLong, uint256 _triggerPrice, bool _triggerAboveThreshold) payable returns()

func (*OrderBookTransactor) CreateIncreaseOrder

func (_OrderBook *OrderBookTransactor) CreateIncreaseOrder(opts *bind.TransactOpts, _path []common.Address, _amountIn *big.Int, _indexToken common.Address, _minOut *big.Int, _sizeDelta *big.Int, _collateralToken common.Address, _isLong bool, _triggerPrice *big.Int, _triggerAboveThreshold bool, _executionFee *big.Int, _shouldWrap bool) (*types.Transaction, error)

CreateIncreaseOrder is a paid mutator transaction binding the contract method 0xb142a4b0.

Solidity: function createIncreaseOrder(address[] _path, uint256 _amountIn, address _indexToken, uint256 _minOut, uint256 _sizeDelta, address _collateralToken, bool _isLong, uint256 _triggerPrice, bool _triggerAboveThreshold, uint256 _executionFee, bool _shouldWrap) payable returns()

func (*OrderBookTransactor) CreateSwapOrder

func (_OrderBook *OrderBookTransactor) CreateSwapOrder(opts *bind.TransactOpts, _path []common.Address, _amountIn *big.Int, _minOut *big.Int, _triggerRatio *big.Int, _triggerAboveThreshold bool, _executionFee *big.Int, _shouldWrap bool, _shouldUnwrap bool) (*types.Transaction, error)

CreateSwapOrder is a paid mutator transaction binding the contract method 0x269ae6c2.

Solidity: function createSwapOrder(address[] _path, uint256 _amountIn, uint256 _minOut, uint256 _triggerRatio, bool _triggerAboveThreshold, uint256 _executionFee, bool _shouldWrap, bool _shouldUnwrap) payable returns()

func (*OrderBookTransactor) ExecuteDecreaseOrder

func (_OrderBook *OrderBookTransactor) ExecuteDecreaseOrder(opts *bind.TransactOpts, _address common.Address, _orderIndex *big.Int, _feeReceiver common.Address) (*types.Transaction, error)

ExecuteDecreaseOrder is a paid mutator transaction binding the contract method 0x11d9444a.

Solidity: function executeDecreaseOrder(address _address, uint256 _orderIndex, address _feeReceiver) returns()

func (*OrderBookTransactor) ExecuteIncreaseOrder

func (_OrderBook *OrderBookTransactor) ExecuteIncreaseOrder(opts *bind.TransactOpts, _address common.Address, _orderIndex *big.Int, _feeReceiver common.Address) (*types.Transaction, error)

ExecuteIncreaseOrder is a paid mutator transaction binding the contract method 0xd38ab519.

Solidity: function executeIncreaseOrder(address _address, uint256 _orderIndex, address _feeReceiver) returns()

func (*OrderBookTransactor) ExecuteSwapOrder

func (_OrderBook *OrderBookTransactor) ExecuteSwapOrder(opts *bind.TransactOpts, _account common.Address, _orderIndex *big.Int, _feeReceiver common.Address) (*types.Transaction, error)

ExecuteSwapOrder is a paid mutator transaction binding the contract method 0x07c7edc3.

Solidity: function executeSwapOrder(address _account, uint256 _orderIndex, address _feeReceiver) returns()

func (*OrderBookTransactor) Initialize

func (_OrderBook *OrderBookTransactor) Initialize(opts *bind.TransactOpts, _router common.Address, _vault common.Address, _weth common.Address, _usdg common.Address, _minExecutionFee *big.Int, _minPurchaseTokenAmountUsd *big.Int) (*types.Transaction, error)

Initialize is a paid mutator transaction binding the contract method 0xd7c41c79.

Solidity: function initialize(address _router, address _vault, address _weth, address _usdg, uint256 _minExecutionFee, uint256 _minPurchaseTokenAmountUsd) returns()

func (*OrderBookTransactor) Receive

func (_OrderBook *OrderBookTransactor) Receive(opts *bind.TransactOpts) (*types.Transaction, error)

Receive is a paid mutator transaction binding the contract receive function.

Solidity: receive() payable returns()

func (*OrderBookTransactor) SetGov

func (_OrderBook *OrderBookTransactor) SetGov(opts *bind.TransactOpts, _gov common.Address) (*types.Transaction, error)

SetGov is a paid mutator transaction binding the contract method 0xcfad57a2.

Solidity: function setGov(address _gov) returns()

func (*OrderBookTransactor) SetMinExecutionFee

func (_OrderBook *OrderBookTransactor) SetMinExecutionFee(opts *bind.TransactOpts, _minExecutionFee *big.Int) (*types.Transaction, error)

SetMinExecutionFee is a paid mutator transaction binding the contract method 0xfc2cee62.

Solidity: function setMinExecutionFee(uint256 _minExecutionFee) returns()

func (*OrderBookTransactor) SetMinPurchaseTokenAmountUsd

func (_OrderBook *OrderBookTransactor) SetMinPurchaseTokenAmountUsd(opts *bind.TransactOpts, _minPurchaseTokenAmountUsd *big.Int) (*types.Transaction, error)

SetMinPurchaseTokenAmountUsd is a paid mutator transaction binding the contract method 0x0d5cc938.

Solidity: function setMinPurchaseTokenAmountUsd(uint256 _minPurchaseTokenAmountUsd) returns()

func (*OrderBookTransactor) UpdateDecreaseOrder

func (_OrderBook *OrderBookTransactor) UpdateDecreaseOrder(opts *bind.TransactOpts, _orderIndex *big.Int, _collateralDelta *big.Int, _sizeDelta *big.Int, _triggerPrice *big.Int, _triggerAboveThreshold bool) (*types.Transaction, error)

UpdateDecreaseOrder is a paid mutator transaction binding the contract method 0xa397ea54.

Solidity: function updateDecreaseOrder(uint256 _orderIndex, uint256 _collateralDelta, uint256 _sizeDelta, uint256 _triggerPrice, bool _triggerAboveThreshold) returns()

func (*OrderBookTransactor) UpdateIncreaseOrder

func (_OrderBook *OrderBookTransactor) UpdateIncreaseOrder(opts *bind.TransactOpts, _orderIndex *big.Int, _sizeDelta *big.Int, _triggerPrice *big.Int, _triggerAboveThreshold bool) (*types.Transaction, error)

UpdateIncreaseOrder is a paid mutator transaction binding the contract method 0x9983ee1b.

Solidity: function updateIncreaseOrder(uint256 _orderIndex, uint256 _sizeDelta, uint256 _triggerPrice, bool _triggerAboveThreshold) returns()

func (*OrderBookTransactor) UpdateSwapOrder

func (_OrderBook *OrderBookTransactor) UpdateSwapOrder(opts *bind.TransactOpts, _orderIndex *big.Int, _minOut *big.Int, _triggerRatio *big.Int, _triggerAboveThreshold bool) (*types.Transaction, error)

UpdateSwapOrder is a paid mutator transaction binding the contract method 0xc86b0f7d.

Solidity: function updateSwapOrder(uint256 _orderIndex, uint256 _minOut, uint256 _triggerRatio, bool _triggerAboveThreshold) returns()

type OrderBookTransactorRaw

type OrderBookTransactorRaw struct {
	Contract *OrderBookTransactor // Generic write-only contract binding to access the raw methods on
}

OrderBookTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.

func (*OrderBookTransactorRaw) Transact

func (_OrderBook *OrderBookTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)

Transact invokes the (paid) contract method with params as input values.

func (*OrderBookTransactorRaw) Transfer

func (_OrderBook *OrderBookTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)

Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.

type OrderBookTransactorSession

type OrderBookTransactorSession struct {
	Contract     *OrderBookTransactor // Generic contract transactor binding to set the session for
	TransactOpts bind.TransactOpts    // Transaction auth options to use throughout this session
}

OrderBookTransactorSession is an auto generated write-only Go binding around an Ethereum contract, with pre-set transact options.

func (*OrderBookTransactorSession) CancelDecreaseOrder

func (_OrderBook *OrderBookTransactorSession) CancelDecreaseOrder(_orderIndex *big.Int) (*types.Transaction, error)

CancelDecreaseOrder is a paid mutator transaction binding the contract method 0x9e71b0f0.

Solidity: function cancelDecreaseOrder(uint256 _orderIndex) returns()

func (*OrderBookTransactorSession) CancelIncreaseOrder

func (_OrderBook *OrderBookTransactorSession) CancelIncreaseOrder(_orderIndex *big.Int) (*types.Transaction, error)

CancelIncreaseOrder is a paid mutator transaction binding the contract method 0x47e0bbd0.

Solidity: function cancelIncreaseOrder(uint256 _orderIndex) returns()

func (*OrderBookTransactorSession) CancelMultiple

func (_OrderBook *OrderBookTransactorSession) CancelMultiple(_swapOrderIndexes []*big.Int, _increaseOrderIndexes []*big.Int, _decreaseOrderIndexes []*big.Int) (*types.Transaction, error)

CancelMultiple is a paid mutator transaction binding the contract method 0x807c5600.

Solidity: function cancelMultiple(uint256[] _swapOrderIndexes, uint256[] _increaseOrderIndexes, uint256[] _decreaseOrderIndexes) returns()

func (*OrderBookTransactorSession) CancelSwapOrder

func (_OrderBook *OrderBookTransactorSession) CancelSwapOrder(_orderIndex *big.Int) (*types.Transaction, error)

CancelSwapOrder is a paid mutator transaction binding the contract method 0xf882ac07.

Solidity: function cancelSwapOrder(uint256 _orderIndex) returns()

func (*OrderBookTransactorSession) CreateDecreaseOrder

func (_OrderBook *OrderBookTransactorSession) CreateDecreaseOrder(_indexToken common.Address, _sizeDelta *big.Int, _collateralToken common.Address, _collateralDelta *big.Int, _isLong bool, _triggerPrice *big.Int, _triggerAboveThreshold bool) (*types.Transaction, error)

CreateDecreaseOrder is a paid mutator transaction binding the contract method 0xc16cde8a.

Solidity: function createDecreaseOrder(address _indexToken, uint256 _sizeDelta, address _collateralToken, uint256 _collateralDelta, bool _isLong, uint256 _triggerPrice, bool _triggerAboveThreshold) payable returns()

func (*OrderBookTransactorSession) CreateIncreaseOrder

func (_OrderBook *OrderBookTransactorSession) CreateIncreaseOrder(_path []common.Address, _amountIn *big.Int, _indexToken common.Address, _minOut *big.Int, _sizeDelta *big.Int, _collateralToken common.Address, _isLong bool, _triggerPrice *big.Int, _triggerAboveThreshold bool, _executionFee *big.Int, _shouldWrap bool) (*types.Transaction, error)

CreateIncreaseOrder is a paid mutator transaction binding the contract method 0xb142a4b0.

Solidity: function createIncreaseOrder(address[] _path, uint256 _amountIn, address _indexToken, uint256 _minOut, uint256 _sizeDelta, address _collateralToken, bool _isLong, uint256 _triggerPrice, bool _triggerAboveThreshold, uint256 _executionFee, bool _shouldWrap) payable returns()

func (*OrderBookTransactorSession) CreateSwapOrder

func (_OrderBook *OrderBookTransactorSession) CreateSwapOrder(_path []common.Address, _amountIn *big.Int, _minOut *big.Int, _triggerRatio *big.Int, _triggerAboveThreshold bool, _executionFee *big.Int, _shouldWrap bool, _shouldUnwrap bool) (*types.Transaction, error)

CreateSwapOrder is a paid mutator transaction binding the contract method 0x269ae6c2.

Solidity: function createSwapOrder(address[] _path, uint256 _amountIn, uint256 _minOut, uint256 _triggerRatio, bool _triggerAboveThreshold, uint256 _executionFee, bool _shouldWrap, bool _shouldUnwrap) payable returns()

func (*OrderBookTransactorSession) ExecuteDecreaseOrder

func (_OrderBook *OrderBookTransactorSession) ExecuteDecreaseOrder(_address common.Address, _orderIndex *big.Int, _feeReceiver common.Address) (*types.Transaction, error)

ExecuteDecreaseOrder is a paid mutator transaction binding the contract method 0x11d9444a.

Solidity: function executeDecreaseOrder(address _address, uint256 _orderIndex, address _feeReceiver) returns()

func (*OrderBookTransactorSession) ExecuteIncreaseOrder

func (_OrderBook *OrderBookTransactorSession) ExecuteIncreaseOrder(_address common.Address, _orderIndex *big.Int, _feeReceiver common.Address) (*types.Transaction, error)

ExecuteIncreaseOrder is a paid mutator transaction binding the contract method 0xd38ab519.

Solidity: function executeIncreaseOrder(address _address, uint256 _orderIndex, address _feeReceiver) returns()

func (*OrderBookTransactorSession) ExecuteSwapOrder

func (_OrderBook *OrderBookTransactorSession) ExecuteSwapOrder(_account common.Address, _orderIndex *big.Int, _feeReceiver common.Address) (*types.Transaction, error)

ExecuteSwapOrder is a paid mutator transaction binding the contract method 0x07c7edc3.

Solidity: function executeSwapOrder(address _account, uint256 _orderIndex, address _feeReceiver) returns()

func (*OrderBookTransactorSession) Initialize

func (_OrderBook *OrderBookTransactorSession) Initialize(_router common.Address, _vault common.Address, _weth common.Address, _usdg common.Address, _minExecutionFee *big.Int, _minPurchaseTokenAmountUsd *big.Int) (*types.Transaction, error)

Initialize is a paid mutator transaction binding the contract method 0xd7c41c79.

Solidity: function initialize(address _router, address _vault, address _weth, address _usdg, uint256 _minExecutionFee, uint256 _minPurchaseTokenAmountUsd) returns()

func (*OrderBookTransactorSession) Receive

func (_OrderBook *OrderBookTransactorSession) Receive() (*types.Transaction, error)

Receive is a paid mutator transaction binding the contract receive function.

Solidity: receive() payable returns()

func (*OrderBookTransactorSession) SetGov

func (_OrderBook *OrderBookTransactorSession) SetGov(_gov common.Address) (*types.Transaction, error)

SetGov is a paid mutator transaction binding the contract method 0xcfad57a2.

Solidity: function setGov(address _gov) returns()

func (*OrderBookTransactorSession) SetMinExecutionFee

func (_OrderBook *OrderBookTransactorSession) SetMinExecutionFee(_minExecutionFee *big.Int) (*types.Transaction, error)

SetMinExecutionFee is a paid mutator transaction binding the contract method 0xfc2cee62.

Solidity: function setMinExecutionFee(uint256 _minExecutionFee) returns()

func (*OrderBookTransactorSession) SetMinPurchaseTokenAmountUsd

func (_OrderBook *OrderBookTransactorSession) SetMinPurchaseTokenAmountUsd(_minPurchaseTokenAmountUsd *big.Int) (*types.Transaction, error)

SetMinPurchaseTokenAmountUsd is a paid mutator transaction binding the contract method 0x0d5cc938.

Solidity: function setMinPurchaseTokenAmountUsd(uint256 _minPurchaseTokenAmountUsd) returns()

func (*OrderBookTransactorSession) UpdateDecreaseOrder

func (_OrderBook *OrderBookTransactorSession) UpdateDecreaseOrder(_orderIndex *big.Int, _collateralDelta *big.Int, _sizeDelta *big.Int, _triggerPrice *big.Int, _triggerAboveThreshold bool) (*types.Transaction, error)

UpdateDecreaseOrder is a paid mutator transaction binding the contract method 0xa397ea54.

Solidity: function updateDecreaseOrder(uint256 _orderIndex, uint256 _collateralDelta, uint256 _sizeDelta, uint256 _triggerPrice, bool _triggerAboveThreshold) returns()

func (*OrderBookTransactorSession) UpdateIncreaseOrder

func (_OrderBook *OrderBookTransactorSession) UpdateIncreaseOrder(_orderIndex *big.Int, _sizeDelta *big.Int, _triggerPrice *big.Int, _triggerAboveThreshold bool) (*types.Transaction, error)

UpdateIncreaseOrder is a paid mutator transaction binding the contract method 0x9983ee1b.

Solidity: function updateIncreaseOrder(uint256 _orderIndex, uint256 _sizeDelta, uint256 _triggerPrice, bool _triggerAboveThreshold) returns()

func (*OrderBookTransactorSession) UpdateSwapOrder

func (_OrderBook *OrderBookTransactorSession) UpdateSwapOrder(_orderIndex *big.Int, _minOut *big.Int, _triggerRatio *big.Int, _triggerAboveThreshold bool) (*types.Transaction, error)

UpdateSwapOrder is a paid mutator transaction binding the contract method 0xc86b0f7d.

Solidity: function updateSwapOrder(uint256 _orderIndex, uint256 _minOut, uint256 _triggerRatio, bool _triggerAboveThreshold) returns()

type OrderBookUpdateDecreaseOrder

type OrderBookUpdateDecreaseOrder struct {
	Account               common.Address
	OrderIndex            *big.Int
	CollateralToken       common.Address
	CollateralDelta       *big.Int
	IndexToken            common.Address
	SizeDelta             *big.Int
	IsLong                bool
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	Raw                   types.Log // Blockchain specific contextual infos
}

OrderBookUpdateDecreaseOrder represents a UpdateDecreaseOrder event raised by the OrderBook contract.

type OrderBookUpdateDecreaseOrderIterator

type OrderBookUpdateDecreaseOrderIterator struct {
	Event *OrderBookUpdateDecreaseOrder // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookUpdateDecreaseOrderIterator is returned from FilterUpdateDecreaseOrder and is used to iterate over the raw logs and unpacked data for UpdateDecreaseOrder events raised by the OrderBook contract.

func (*OrderBookUpdateDecreaseOrderIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookUpdateDecreaseOrderIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookUpdateDecreaseOrderIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookUpdateGov

type OrderBookUpdateGov struct {
	Gov common.Address
	Raw types.Log // Blockchain specific contextual infos
}

OrderBookUpdateGov represents a UpdateGov event raised by the OrderBook contract.

type OrderBookUpdateGovIterator

type OrderBookUpdateGovIterator struct {
	Event *OrderBookUpdateGov // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookUpdateGovIterator is returned from FilterUpdateGov and is used to iterate over the raw logs and unpacked data for UpdateGov events raised by the OrderBook contract.

func (*OrderBookUpdateGovIterator) Close

func (it *OrderBookUpdateGovIterator) Close() error

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookUpdateGovIterator) Error

func (it *OrderBookUpdateGovIterator) Error() error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookUpdateGovIterator) Next

func (it *OrderBookUpdateGovIterator) Next() bool

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookUpdateIncreaseOrder

type OrderBookUpdateIncreaseOrder struct {
	Account               common.Address
	OrderIndex            *big.Int
	CollateralToken       common.Address
	IndexToken            common.Address
	IsLong                bool
	SizeDelta             *big.Int
	TriggerPrice          *big.Int
	TriggerAboveThreshold bool
	Raw                   types.Log // Blockchain specific contextual infos
}

OrderBookUpdateIncreaseOrder represents a UpdateIncreaseOrder event raised by the OrderBook contract.

type OrderBookUpdateIncreaseOrderIterator

type OrderBookUpdateIncreaseOrderIterator struct {
	Event *OrderBookUpdateIncreaseOrder // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookUpdateIncreaseOrderIterator is returned from FilterUpdateIncreaseOrder and is used to iterate over the raw logs and unpacked data for UpdateIncreaseOrder events raised by the OrderBook contract.

func (*OrderBookUpdateIncreaseOrderIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookUpdateIncreaseOrderIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookUpdateIncreaseOrderIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookUpdateMinExecutionFee

type OrderBookUpdateMinExecutionFee struct {
	MinExecutionFee *big.Int
	Raw             types.Log // Blockchain specific contextual infos
}

OrderBookUpdateMinExecutionFee represents a UpdateMinExecutionFee event raised by the OrderBook contract.

type OrderBookUpdateMinExecutionFeeIterator

type OrderBookUpdateMinExecutionFeeIterator struct {
	Event *OrderBookUpdateMinExecutionFee // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookUpdateMinExecutionFeeIterator is returned from FilterUpdateMinExecutionFee and is used to iterate over the raw logs and unpacked data for UpdateMinExecutionFee events raised by the OrderBook contract.

func (*OrderBookUpdateMinExecutionFeeIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookUpdateMinExecutionFeeIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookUpdateMinExecutionFeeIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookUpdateMinPurchaseTokenAmountUsd

type OrderBookUpdateMinPurchaseTokenAmountUsd struct {
	MinPurchaseTokenAmountUsd *big.Int
	Raw                       types.Log // Blockchain specific contextual infos
}

OrderBookUpdateMinPurchaseTokenAmountUsd represents a UpdateMinPurchaseTokenAmountUsd event raised by the OrderBook contract.

type OrderBookUpdateMinPurchaseTokenAmountUsdIterator

type OrderBookUpdateMinPurchaseTokenAmountUsdIterator struct {
	Event *OrderBookUpdateMinPurchaseTokenAmountUsd // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookUpdateMinPurchaseTokenAmountUsdIterator is returned from FilterUpdateMinPurchaseTokenAmountUsd and is used to iterate over the raw logs and unpacked data for UpdateMinPurchaseTokenAmountUsd events raised by the OrderBook contract.

func (*OrderBookUpdateMinPurchaseTokenAmountUsdIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookUpdateMinPurchaseTokenAmountUsdIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookUpdateMinPurchaseTokenAmountUsdIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type OrderBookUpdateSwapOrder

type OrderBookUpdateSwapOrder struct {
	Account               common.Address
	OrdexIndex            *big.Int
	Path                  []common.Address
	AmountIn              *big.Int
	MinOut                *big.Int
	TriggerRatio          *big.Int
	TriggerAboveThreshold bool
	ShouldUnwrap          bool
	ExecutionFee          *big.Int
	Raw                   types.Log // Blockchain specific contextual infos
}

OrderBookUpdateSwapOrder represents a UpdateSwapOrder event raised by the OrderBook contract.

type OrderBookUpdateSwapOrderIterator

type OrderBookUpdateSwapOrderIterator struct {
	Event *OrderBookUpdateSwapOrder // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

OrderBookUpdateSwapOrderIterator is returned from FilterUpdateSwapOrder and is used to iterate over the raw logs and unpacked data for UpdateSwapOrder events raised by the OrderBook contract.

func (*OrderBookUpdateSwapOrderIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*OrderBookUpdateSwapOrderIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*OrderBookUpdateSwapOrderIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL