{
  "abi": [
    {
      "inputs": [
        {
          "internalType": "contract IEToken",
          "name": "eToken",
          "type": "address"
        },
        {
          "internalType": "uint256",
          "name": "paymentAmount",
          "type": "uint256"
        }
      ],
      "name": "insolventEToken",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "uint256",
          "name": "paymentAmount",
          "type": "uint256"
        }
      ],
      "name": "outOfCash",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    }
  ],
  "ast": {
    "absolutePath": "interfaces/IInsolvencyHook.sol",
    "exportedSymbols": {
      "IEToken": [
        132
      ],
      "IInsolvencyHook": [
        216
      ]
    },
    "id": 217,
    "license": "Apache-2.0",
    "nodeType": "SourceUnit",
    "nodes": [
      {
        "id": 197,
        "literals": [
          "solidity",
          "^",
          "0.8",
          ".0"
        ],
        "nodeType": "PragmaDirective",
        "src": "39:23:5"
      },
      {
        "absolutePath": "interfaces/IEToken.sol",
        "file": "./IEToken.sol",
        "id": 199,
        "nameLocation": "-1:-1:-1",
        "nodeType": "ImportDirective",
        "scope": 217,
        "sourceUnit": 133,
        "src": "64:38:5",
        "symbolAliases": [
          {
            "foreign": {
              "id": 198,
              "name": "IEToken",
              "nodeType": "Identifier",
              "overloadedDeclarations": [],
              "src": "72:7:5",
              "typeDescriptions": {}
            },
            "nameLocation": "-1:-1:-1"
          }
        ],
        "unitAlias": ""
      },
      {
        "abstract": false,
        "baseContracts": [],
        "contractDependencies": [],
        "contractKind": "interface",
        "documentation": {
          "id": 200,
          "nodeType": "StructuredDocumentation",
          "src": "104:163:5",
          "text": " @title IInsolvencyHook interface\n @dev Interface for insolvency hook, the contract that manages the insolvency situation of the pool\n @author Ensuro"
        },
        "fullyImplemented": false,
        "id": 216,
        "linearizedBaseContracts": [
          216
        ],
        "name": "IInsolvencyHook",
        "nameLocation": "278:15:5",
        "nodeType": "ContractDefinition",
        "nodes": [
          {
            "documentation": {
              "id": 201,
              "nodeType": "StructuredDocumentation",
              "src": "298:279:5",
              "text": " @dev This is called from PolicyPool when doesn't have enought money for payment.\n      After the call, there should be enought money in PolicyPool.currency().balanceOf(_policyPool) to\n      do the payment\n @param paymentAmount The amount of the payment"
            },
            "functionSelector": "ee842dda",
            "id": 206,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "outOfCash",
            "nameLocation": "589:9:5",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 204,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 203,
                  "mutability": "mutable",
                  "name": "paymentAmount",
                  "nameLocation": "607:13:5",
                  "nodeType": "VariableDeclaration",
                  "scope": 206,
                  "src": "599:21:5",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 202,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "599:7:5",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "visibility": "internal"
                }
              ],
              "src": "598:23:5"
            },
            "returnParameters": {
              "id": 205,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "630:0:5"
            },
            "scope": 216,
            "src": "580:51:5",
            "stateMutability": "nonpayable",
            "virtual": false,
            "visibility": "external"
          },
          {
            "documentation": {
              "id": 207,
              "nodeType": "StructuredDocumentation",
              "src": "635:296:5",
              "text": " @dev This is called from EToken when doesn't have enought totalSupply to cover the SCR\n      The hook might choose not to do anything or solve the insolvency with a deposit\n @param eToken The token that suffers insolvency\n @param paymentAmount The amount of the payment"
            },
            "functionSelector": "9950de50",
            "id": 215,
            "implemented": false,
            "kind": "function",
            "modifiers": [],
            "name": "insolventEToken",
            "nameLocation": "943:15:5",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 213,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 210,
                  "mutability": "mutable",
                  "name": "eToken",
                  "nameLocation": "967:6:5",
                  "nodeType": "VariableDeclaration",
                  "scope": 215,
                  "src": "959:14:5",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_contract$_IEToken_$132",
                    "typeString": "contract IEToken"
                  },
                  "typeName": {
                    "id": 209,
                    "nodeType": "UserDefinedTypeName",
                    "pathNode": {
                      "id": 208,
                      "name": "IEToken",
                      "nodeType": "IdentifierPath",
                      "referencedDeclaration": 132,
                      "src": "959:7:5"
                    },
                    "referencedDeclaration": 132,
                    "src": "959:7:5",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_IEToken_$132",
                      "typeString": "contract IEToken"
                    }
                  },
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 212,
                  "mutability": "mutable",
                  "name": "paymentAmount",
                  "nameLocation": "983:13:5",
                  "nodeType": "VariableDeclaration",
                  "scope": 215,
                  "src": "975:21:5",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 211,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "975:7:5",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "visibility": "internal"
                }
              ],
              "src": "958:39:5"
            },
            "returnParameters": {
              "id": 214,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "1006:0:5"
            },
            "scope": 216,
            "src": "934:73:5",
            "stateMutability": "nonpayable",
            "virtual": false,
            "visibility": "external"
          }
        ],
        "scope": 217,
        "src": "268:741:5",
        "usedErrors": []
      }
    ],
    "src": "39:971:5"
  },
  "contractName": "IInsolvencyHook",
  "dependencies": [
    "IERC20",
    "IEToken"
  ],
  "offset": [
    268,
    1009
  ],
  "sha1": "3650e13e8e1bdfbfba8b74523f61056766c056c5",
  "source": "// SPDX-License-Identifier: Apache-2.0\npragma solidity ^0.8.0;\n\nimport {IEToken} from \"./IEToken.sol\";\n\n/**\n * @title IInsolvencyHook interface\n * @dev Interface for insolvency hook, the contract that manages the insolvency situation of the pool\n * @author Ensuro\n */\ninterface IInsolvencyHook {\n  /**\n   * @dev This is called from PolicyPool when doesn't have enought money for payment.\n   *      After the call, there should be enought money in PolicyPool.currency().balanceOf(_policyPool) to\n   *      do the payment\n   * @param paymentAmount The amount of the payment\n   */\n  function outOfCash(uint256 paymentAmount) external;\n\n  /**\n   * @dev This is called from EToken when doesn't have enought totalSupply to cover the SCR\n   *      The hook might choose not to do anything or solve the insolvency with a deposit\n   * @param eToken The token that suffers insolvency\n   * @param paymentAmount The amount of the payment\n   */\n  function insolventEToken(IEToken eToken, uint256 paymentAmount) external;\n}\n",
  "type": "interface"
}