{
  "contractName": "TokenCapGC",
  "abi": [
    {
      "constant": true,
      "inputs": [
        {
          "name": "",
          "type": "address"
        },
        {
          "name": "_paramsHash",
          "type": "bytes32"
        },
        {
          "name": "",
          "type": "bytes"
        }
      ],
      "name": "post",
      "outputs": [
        {
          "name": "",
          "type": "bool"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [
        {
          "name": "_token",
          "type": "address"
        },
        {
          "name": "_cap",
          "type": "uint256"
        }
      ],
      "name": "getParametersHash",
      "outputs": [
        {
          "name": "",
          "type": "bytes32"
        }
      ],
      "payable": false,
      "stateMutability": "pure",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [
        {
          "name": "",
          "type": "address"
        },
        {
          "name": "",
          "type": "bytes32"
        },
        {
          "name": "",
          "type": "bytes"
        }
      ],
      "name": "pre",
      "outputs": [
        {
          "name": "",
          "type": "bool"
        }
      ],
      "payable": false,
      "stateMutability": "pure",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [
        {
          "name": "_token",
          "type": "address"
        },
        {
          "name": "_cap",
          "type": "uint256"
        }
      ],
      "name": "setParameters",
      "outputs": [
        {
          "name": "",
          "type": "bytes32"
        }
      ],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [
        {
          "name": "",
          "type": "bytes32"
        }
      ],
      "name": "params",
      "outputs": [
        {
          "name": "token",
          "type": "address"
        },
        {
          "name": "cap",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    }
  ],
  "bytecode": "0x6060604052341561000f57600080fd5b6103958061001e6000396000f30060606040526004361061006c5763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416631ab9b33a811461007157806378fc063c146100ea57806389eaee6a1461011e578063c419816114610183578063dc6ab527146101a5575b600080fd5b341561007c57600080fd5b6100d660048035600160a060020a03169060248035919060649060443590810190830135806020601f820181900481020160405190810160405281815292919060208401838380828437509496506101dd95505050505050565b604051901515815260200160405180910390f35b34156100f557600080fd5b61010c600160a060020a03600435166024356102aa565b60405190815260200160405180910390f35b341561012957600080fd5b6100d660048035600160a060020a03169060248035919060649060443590810190830135806020601f820181900481020160405190810160405281815292919060208401838380828437509496506102e695505050505050565b341561018e57600080fd5b61010c600160a060020a03600435166024356102ef565b34156101b057600080fd5b6101bb600435610344565b604051600160a060020a03909216825260208201526040908101905180910390f35b600082815260208190526040812054600160a060020a0316158015906102925750600083815260208190526040808220600181015490549092600160a060020a03909116916318160ddd919051602001526040518163ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401602060405180830381600087803b151561027557600080fd5b6102c65a03f1151561028657600080fd5b50505060405180519050115b1561029f575060006102a3565b5060015b9392505050565b60008282604051600160a060020a03929092166c0100000000000000000000000002825260148201526034016040518091039020905092915050565b60019392505050565b6000806102fc84846102aa565b60008181526020819052604090208054600160a060020a03871673ffffffffffffffffffffffffffffffffffffffff1990911617815560010184905591508190505092915050565b60006020819052908152604090208054600190910154600160a060020a0390911690825600a165627a7a723058204003f98aa344bca2ca1df7a7620f61bd50c70b8a4cfab1ec09e95270ea0673d40029",
  "deployedBytecode": "0x60606040526004361061006c5763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416631ab9b33a811461007157806378fc063c146100ea57806389eaee6a1461011e578063c419816114610183578063dc6ab527146101a5575b600080fd5b341561007c57600080fd5b6100d660048035600160a060020a03169060248035919060649060443590810190830135806020601f820181900481020160405190810160405281815292919060208401838380828437509496506101dd95505050505050565b604051901515815260200160405180910390f35b34156100f557600080fd5b61010c600160a060020a03600435166024356102aa565b60405190815260200160405180910390f35b341561012957600080fd5b6100d660048035600160a060020a03169060248035919060649060443590810190830135806020601f820181900481020160405190810160405281815292919060208401838380828437509496506102e695505050505050565b341561018e57600080fd5b61010c600160a060020a03600435166024356102ef565b34156101b057600080fd5b6101bb600435610344565b604051600160a060020a03909216825260208201526040908101905180910390f35b600082815260208190526040812054600160a060020a0316158015906102925750600083815260208190526040808220600181015490549092600160a060020a03909116916318160ddd919051602001526040518163ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401602060405180830381600087803b151561027557600080fd5b6102c65a03f1151561028657600080fd5b50505060405180519050115b1561029f575060006102a3565b5060015b9392505050565b60008282604051600160a060020a03929092166c0100000000000000000000000002825260148201526034016040518091039020905092915050565b60019392505050565b6000806102fc84846102aa565b60008181526020819052604090208054600160a060020a03871673ffffffffffffffffffffffffffffffffffffffff1990911617815560010184905591508190505092915050565b60006020819052908152604090208054600190910154600160a060020a0390911690825600a165627a7a723058204003f98aa344bca2ca1df7a7620f61bd50c70b8a4cfab1ec09e95270ea0673d40029",
  "sourceMap": "201:1933:12:-;;;;;;;;;;;;;;;;;",
  "deployedSourceMap": "201:1933:12:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1842:290;;;;;;;;;;;;;-1:-1:-1;;;;;1842:290:12;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;1842:290:12;;-1:-1:-1;1842:290:12;;-1:-1:-1;;;;;;1842:290:12;;;;;;;;;;;;;;;;;;1225:138;;;;;;;;;;-1:-1:-1;;;;;1225:138:12;;;;;;;;;;;;;;;;;;;;;;1555:92;;;;;;;;;;;;;-1:-1:-1;;;;;1555:92:12;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;1555:92:12;;-1:-1:-1;1555:92:12;;-1:-1:-1;;;;;;1555:92:12;716:258;;;;;;;;;;-1:-1:-1;;;;;716:258:12;;;;;;;444:43;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;444:43:12;;;;;;;;;;;;;;;;;;;;1842:290;1913:4;1934:19;;;;;;;;;;:25;-1:-1:-1;;;;;1934:25:12;:45;;;;1933:131;;-1:-1:-1;2040:6:12;:19;;;;;;;;;;;:23;;;;1998:25;;2040:23;;-1:-1:-1;;;;;1998:25:12;;;;:37;;2040:6;1998:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:65;1933:131;1929:176;;;-1:-1:-1;2087:5:12;2080:12;;1929:176;-1:-1:-1;2121:4:12;1842:290;;;;;;:::o;1225:138::-;1305:7;1342:6;1350:4;1332:23;;-1:-1:-1;;;;;1332:23:12;;;;;;;;;;;;;;;;;;;;;1324:32;;1225:138;;;;:::o;1555:92::-;1636:4;1555:92;;;;;:::o;716:258::-;787:7;806:18;827:31;845:6;853:4;827:17;:31::i;:::-;868:6;:18;;;;;;;;;;:33;;-1:-1:-1;;;;;868:33:12;;-1:-1:-1;;868:33:12;;;;;;;911:22;:29;;;806:52;-1:-1:-1;806:52:12;;-1:-1:-1;716:258:12;;;;;:::o;444:43::-;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;444:43:12;;;;;:::o",
  "source": "pragma solidity ^0.4.18;\n\nimport \"zeppelin-solidity/contracts/token/StandardToken.sol\";\n\n\n/**\n * @title Token Cap Global Constraint\n * @dev A simple global constraint to cap the number of tokens.\n */\n\ncontract TokenCapGC {\n    // A set of parameters, on which the cap will be checked:\n    struct Parameters {\n        StandardToken token;\n        uint cap;\n    }\n\n    // Mapping from the hash of the parameters to the parameters themselves:\n    mapping (bytes32=>Parameters) public params;\n\n\n    /**\n     * @dev adding a new set of parameters\n     * @param  _token the token to add to the params.\n     * @param _cap the cap to check the total supply against.\n     * @return the calculated parameters hash\n     */\n    function setParameters(StandardToken _token, uint _cap) public returns(bytes32) {\n        bytes32 paramsHash = getParametersHash(_token, _cap);\n        params[paramsHash].token = _token;\n        params[paramsHash].cap = _cap;\n        return paramsHash;\n    }\n\n    /**\n     * @dev calculate and returns the hash of the given parameters\n     * @param  _token the token to add to the params.\n     * @param _cap the cap to check the total supply against.\n     * @return the calculated parameters hash\n     */\n    function getParametersHash(StandardToken _token, uint _cap) public pure returns(bytes32) {\n        return (keccak256(_token, _cap));\n    }\n\n    /**\n     * @dev check the constraint after the action.\n     * This global constraint only checks the state after the action, so here we just return true:\n     * @return true\n     */\n    function pre(address, bytes32, bytes) public pure returns(bool) {\n        return true;\n    }\n\n    /**\n     * @dev check the total supply cap.\n     * @param  _paramsHash the parameters hash to check the total supply cap against.\n     * @return bool which represents a success\n     */\n    function post(address, bytes32 _paramsHash, bytes) public view returns(bool) {\n        if ((params[_paramsHash].token != StandardToken(0)) &&\n            ( params[_paramsHash].token.totalSupply() > params[_paramsHash].cap)) {\n            return false;\n          }\n        return true;\n    }\n}\n",
  "sourcePath": "/home/travis/build/dev-matan-tsuberi/daostack/contracts/globalConstraints/TokenCapGC.sol",
  "ast": {
    "attributes": {
      "absolutePath": "/home/travis/build/dev-matan-tsuberi/daostack/contracts/globalConstraints/TokenCapGC.sol",
      "exportedSymbols": {
        "TokenCapGC": [
          6006
        ]
      }
    },
    "children": [
      {
        "attributes": {
          "literals": [
            "solidity",
            "^",
            "0.4",
            ".18"
          ]
        },
        "id": 5892,
        "name": "PragmaDirective",
        "src": "0:24:12"
      },
      {
        "attributes": {
          "SourceUnit": 10856,
          "absolutePath": "zeppelin-solidity/contracts/token/StandardToken.sol",
          "file": "zeppelin-solidity/contracts/token/StandardToken.sol",
          "scope": 6007,
          "symbolAliases": [
            null
          ],
          "unitAlias": ""
        },
        "id": 5893,
        "name": "ImportDirective",
        "src": "26:61:12"
      },
      {
        "attributes": {
          "baseContracts": [
            null
          ],
          "contractDependencies": [
            null
          ],
          "contractKind": "contract",
          "documentation": "@title Token Cap Global Constraint\n@dev A simple global constraint to cap the number of tokens.",
          "fullyImplemented": true,
          "linearizedBaseContracts": [
            6006
          ],
          "name": "TokenCapGC",
          "scope": 6007
        },
        "children": [
          {
            "attributes": {
              "canonicalName": "TokenCapGC.Parameters",
              "name": "Parameters",
              "scope": 6006,
              "visibility": "public"
            },
            "children": [
              {
                "attributes": {
                  "constant": false,
                  "name": "token",
                  "scope": 5898,
                  "stateVariable": false,
                  "storageLocation": "default",
                  "type": "contract StandardToken",
                  "value": null,
                  "visibility": "internal"
                },
                "children": [
                  {
                    "attributes": {
                      "contractScope": null,
                      "name": "StandardToken",
                      "referencedDeclaration": 10855,
                      "type": "contract StandardToken"
                    },
                    "id": 5894,
                    "name": "UserDefinedTypeName",
                    "src": "317:13:12"
                  }
                ],
                "id": 5895,
                "name": "VariableDeclaration",
                "src": "317:19:12"
              },
              {
                "attributes": {
                  "constant": false,
                  "name": "cap",
                  "scope": 5898,
                  "stateVariable": false,
                  "storageLocation": "default",
                  "type": "uint256",
                  "value": null,
                  "visibility": "internal"
                },
                "children": [
                  {
                    "attributes": {
                      "name": "uint",
                      "type": "uint256"
                    },
                    "id": 5896,
                    "name": "ElementaryTypeName",
                    "src": "346:4:12"
                  }
                ],
                "id": 5897,
                "name": "VariableDeclaration",
                "src": "346:8:12"
              }
            ],
            "id": 5898,
            "name": "StructDefinition",
            "src": "289:72:12"
          },
          {
            "attributes": {
              "constant": false,
              "name": "params",
              "scope": 6006,
              "stateVariable": true,
              "storageLocation": "default",
              "type": "mapping(bytes32 => struct TokenCapGC.Parameters storage ref)",
              "value": null,
              "visibility": "public"
            },
            "children": [
              {
                "attributes": {
                  "type": "mapping(bytes32 => struct TokenCapGC.Parameters storage ref)"
                },
                "children": [
                  {
                    "attributes": {
                      "name": "bytes32",
                      "type": "bytes32"
                    },
                    "id": 5899,
                    "name": "ElementaryTypeName",
                    "src": "453:7:12"
                  },
                  {
                    "attributes": {
                      "contractScope": null,
                      "name": "Parameters",
                      "referencedDeclaration": 5898,
                      "type": "struct TokenCapGC.Parameters storage pointer"
                    },
                    "id": 5900,
                    "name": "UserDefinedTypeName",
                    "src": "462:10:12"
                  }
                ],
                "id": 5901,
                "name": "Mapping",
                "src": "444:29:12"
              }
            ],
            "id": 5902,
            "name": "VariableDeclaration",
            "src": "444:43:12"
          },
          {
            "attributes": {
              "constant": false,
              "implemented": true,
              "isConstructor": false,
              "modifiers": [
                null
              ],
              "name": "setParameters",
              "payable": false,
              "scope": 6006,
              "stateMutability": "nonpayable",
              "superFunction": null,
              "visibility": "public"
            },
            "children": [
              {
                "children": [
                  {
                    "attributes": {
                      "constant": false,
                      "name": "_token",
                      "scope": 5935,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "contract StandardToken",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "contractScope": null,
                          "name": "StandardToken",
                          "referencedDeclaration": 10855,
                          "type": "contract StandardToken"
                        },
                        "id": 5903,
                        "name": "UserDefinedTypeName",
                        "src": "739:13:12"
                      }
                    ],
                    "id": 5904,
                    "name": "VariableDeclaration",
                    "src": "739:20:12"
                  },
                  {
                    "attributes": {
                      "constant": false,
                      "name": "_cap",
                      "scope": 5935,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "uint256",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "uint",
                          "type": "uint256"
                        },
                        "id": 5905,
                        "name": "ElementaryTypeName",
                        "src": "761:4:12"
                      }
                    ],
                    "id": 5906,
                    "name": "VariableDeclaration",
                    "src": "761:9:12"
                  }
                ],
                "id": 5907,
                "name": "ParameterList",
                "src": "738:33:12"
              },
              {
                "children": [
                  {
                    "attributes": {
                      "constant": false,
                      "name": "",
                      "scope": 5935,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "bytes32",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "bytes32",
                          "type": "bytes32"
                        },
                        "id": 5908,
                        "name": "ElementaryTypeName",
                        "src": "787:7:12"
                      }
                    ],
                    "id": 5909,
                    "name": "VariableDeclaration",
                    "src": "787:7:12"
                  }
                ],
                "id": 5910,
                "name": "ParameterList",
                "src": "786:9:12"
              },
              {
                "children": [
                  {
                    "attributes": {
                      "assignments": [
                        5912
                      ]
                    },
                    "children": [
                      {
                        "attributes": {
                          "constant": false,
                          "name": "paramsHash",
                          "scope": 5935,
                          "stateVariable": false,
                          "storageLocation": "default",
                          "type": "bytes32",
                          "value": null,
                          "visibility": "internal"
                        },
                        "children": [
                          {
                            "attributes": {
                              "name": "bytes32",
                              "type": "bytes32"
                            },
                            "id": 5911,
                            "name": "ElementaryTypeName",
                            "src": "806:7:12"
                          }
                        ],
                        "id": 5912,
                        "name": "VariableDeclaration",
                        "src": "806:18:12"
                      },
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "isStructConstructorCall": false,
                          "lValueRequested": false,
                          "names": [
                            null
                          ],
                          "type": "bytes32",
                          "type_conversion": false
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": [
                                {
                                  "typeIdentifier": "t_contract$_StandardToken_$10855",
                                  "typeString": "contract StandardToken"
                                },
                                {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              ],
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 5951,
                              "type": "function (contract StandardToken,uint256) pure returns (bytes32)",
                              "value": "getParametersHash"
                            },
                            "id": 5913,
                            "name": "Identifier",
                            "src": "827:17:12"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 5904,
                              "type": "contract StandardToken",
                              "value": "_token"
                            },
                            "id": 5914,
                            "name": "Identifier",
                            "src": "845:6:12"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 5906,
                              "type": "uint256",
                              "value": "_cap"
                            },
                            "id": 5915,
                            "name": "Identifier",
                            "src": "853:4:12"
                          }
                        ],
                        "id": 5916,
                        "name": "FunctionCall",
                        "src": "827:31:12"
                      }
                    ],
                    "id": 5917,
                    "name": "VariableDeclarationStatement",
                    "src": "806:52:12"
                  },
                  {
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "operator": "=",
                          "type": "contract StandardToken"
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": true,
                              "member_name": "token",
                              "referencedDeclaration": 5895,
                              "type": "contract StandardToken"
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "type": "struct TokenCapGC.Parameters storage ref"
                                },
                                "children": [
                                  {
                                    "attributes": {
                                      "argumentTypes": null,
                                      "overloadedDeclarations": [
                                        null
                                      ],
                                      "referencedDeclaration": 5902,
                                      "type": "mapping(bytes32 => struct TokenCapGC.Parameters storage ref)",
                                      "value": "params"
                                    },
                                    "id": 5918,
                                    "name": "Identifier",
                                    "src": "868:6:12"
                                  },
                                  {
                                    "attributes": {
                                      "argumentTypes": null,
                                      "overloadedDeclarations": [
                                        null
                                      ],
                                      "referencedDeclaration": 5912,
                                      "type": "bytes32",
                                      "value": "paramsHash"
                                    },
                                    "id": 5919,
                                    "name": "Identifier",
                                    "src": "875:10:12"
                                  }
                                ],
                                "id": 5920,
                                "name": "IndexAccess",
                                "src": "868:18:12"
                              }
                            ],
                            "id": 5921,
                            "name": "MemberAccess",
                            "src": "868:24:12"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 5904,
                              "type": "contract StandardToken",
                              "value": "_token"
                            },
                            "id": 5922,
                            "name": "Identifier",
                            "src": "895:6:12"
                          }
                        ],
                        "id": 5923,
                        "name": "Assignment",
                        "src": "868:33:12"
                      }
                    ],
                    "id": 5924,
                    "name": "ExpressionStatement",
                    "src": "868:33:12"
                  },
                  {
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "operator": "=",
                          "type": "uint256"
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "isConstant": false,
                              "isLValue": true,
                              "isPure": false,
                              "lValueRequested": true,
                              "member_name": "cap",
                              "referencedDeclaration": 5897,
                              "type": "uint256"
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "isConstant": false,
                                  "isLValue": true,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "type": "struct TokenCapGC.Parameters storage ref"
                                },
                                "children": [
                                  {
                                    "attributes": {
                                      "argumentTypes": null,
                                      "overloadedDeclarations": [
                                        null
                                      ],
                                      "referencedDeclaration": 5902,
                                      "type": "mapping(bytes32 => struct TokenCapGC.Parameters storage ref)",
                                      "value": "params"
                                    },
                                    "id": 5925,
                                    "name": "Identifier",
                                    "src": "911:6:12"
                                  },
                                  {
                                    "attributes": {
                                      "argumentTypes": null,
                                      "overloadedDeclarations": [
                                        null
                                      ],
                                      "referencedDeclaration": 5912,
                                      "type": "bytes32",
                                      "value": "paramsHash"
                                    },
                                    "id": 5926,
                                    "name": "Identifier",
                                    "src": "918:10:12"
                                  }
                                ],
                                "id": 5927,
                                "name": "IndexAccess",
                                "src": "911:18:12"
                              }
                            ],
                            "id": 5928,
                            "name": "MemberAccess",
                            "src": "911:22:12"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 5906,
                              "type": "uint256",
                              "value": "_cap"
                            },
                            "id": 5929,
                            "name": "Identifier",
                            "src": "936:4:12"
                          }
                        ],
                        "id": 5930,
                        "name": "Assignment",
                        "src": "911:29:12"
                      }
                    ],
                    "id": 5931,
                    "name": "ExpressionStatement",
                    "src": "911:29:12"
                  },
                  {
                    "attributes": {
                      "functionReturnParameters": 5910
                    },
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "overloadedDeclarations": [
                            null
                          ],
                          "referencedDeclaration": 5912,
                          "type": "bytes32",
                          "value": "paramsHash"
                        },
                        "id": 5932,
                        "name": "Identifier",
                        "src": "957:10:12"
                      }
                    ],
                    "id": 5933,
                    "name": "Return",
                    "src": "950:17:12"
                  }
                ],
                "id": 5934,
                "name": "Block",
                "src": "796:178:12"
              }
            ],
            "id": 5935,
            "name": "FunctionDefinition",
            "src": "716:258:12"
          },
          {
            "attributes": {
              "constant": true,
              "implemented": true,
              "isConstructor": false,
              "modifiers": [
                null
              ],
              "name": "getParametersHash",
              "payable": false,
              "scope": 6006,
              "stateMutability": "pure",
              "superFunction": null,
              "visibility": "public"
            },
            "children": [
              {
                "children": [
                  {
                    "attributes": {
                      "constant": false,
                      "name": "_token",
                      "scope": 5951,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "contract StandardToken",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "contractScope": null,
                          "name": "StandardToken",
                          "referencedDeclaration": 10855,
                          "type": "contract StandardToken"
                        },
                        "id": 5936,
                        "name": "UserDefinedTypeName",
                        "src": "1252:13:12"
                      }
                    ],
                    "id": 5937,
                    "name": "VariableDeclaration",
                    "src": "1252:20:12"
                  },
                  {
                    "attributes": {
                      "constant": false,
                      "name": "_cap",
                      "scope": 5951,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "uint256",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "uint",
                          "type": "uint256"
                        },
                        "id": 5938,
                        "name": "ElementaryTypeName",
                        "src": "1274:4:12"
                      }
                    ],
                    "id": 5939,
                    "name": "VariableDeclaration",
                    "src": "1274:9:12"
                  }
                ],
                "id": 5940,
                "name": "ParameterList",
                "src": "1251:33:12"
              },
              {
                "children": [
                  {
                    "attributes": {
                      "constant": false,
                      "name": "",
                      "scope": 5951,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "bytes32",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "bytes32",
                          "type": "bytes32"
                        },
                        "id": 5941,
                        "name": "ElementaryTypeName",
                        "src": "1305:7:12"
                      }
                    ],
                    "id": 5942,
                    "name": "VariableDeclaration",
                    "src": "1305:7:12"
                  }
                ],
                "id": 5943,
                "name": "ParameterList",
                "src": "1304:9:12"
              },
              {
                "children": [
                  {
                    "attributes": {
                      "functionReturnParameters": 5943
                    },
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "isConstant": false,
                          "isInlineArray": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "type": "bytes32"
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "isStructConstructorCall": false,
                              "lValueRequested": false,
                              "names": [
                                null
                              ],
                              "type": "bytes32",
                              "type_conversion": false
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": [
                                    {
                                      "typeIdentifier": "t_contract$_StandardToken_$10855",
                                      "typeString": "contract StandardToken"
                                    },
                                    {
                                      "typeIdentifier": "t_uint256",
                                      "typeString": "uint256"
                                    }
                                  ],
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 10861,
                                  "type": "function () pure returns (bytes32)",
                                  "value": "keccak256"
                                },
                                "id": 5944,
                                "name": "Identifier",
                                "src": "1332:9:12"
                              },
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 5937,
                                  "type": "contract StandardToken",
                                  "value": "_token"
                                },
                                "id": 5945,
                                "name": "Identifier",
                                "src": "1342:6:12"
                              },
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 5939,
                                  "type": "uint256",
                                  "value": "_cap"
                                },
                                "id": 5946,
                                "name": "Identifier",
                                "src": "1350:4:12"
                              }
                            ],
                            "id": 5947,
                            "name": "FunctionCall",
                            "src": "1332:23:12"
                          }
                        ],
                        "id": 5948,
                        "name": "TupleExpression",
                        "src": "1331:25:12"
                      }
                    ],
                    "id": 5949,
                    "name": "Return",
                    "src": "1324:32:12"
                  }
                ],
                "id": 5950,
                "name": "Block",
                "src": "1314:49:12"
              }
            ],
            "id": 5951,
            "name": "FunctionDefinition",
            "src": "1225:138:12"
          },
          {
            "attributes": {
              "constant": true,
              "implemented": true,
              "isConstructor": false,
              "modifiers": [
                null
              ],
              "name": "pre",
              "payable": false,
              "scope": 6006,
              "stateMutability": "pure",
              "superFunction": null,
              "visibility": "public"
            },
            "children": [
              {
                "children": [
                  {
                    "attributes": {
                      "constant": false,
                      "name": "",
                      "scope": 5965,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "address",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "address",
                          "type": "address"
                        },
                        "id": 5952,
                        "name": "ElementaryTypeName",
                        "src": "1568:7:12"
                      }
                    ],
                    "id": 5953,
                    "name": "VariableDeclaration",
                    "src": "1568:7:12"
                  },
                  {
                    "attributes": {
                      "constant": false,
                      "name": "",
                      "scope": 5965,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "bytes32",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "bytes32",
                          "type": "bytes32"
                        },
                        "id": 5954,
                        "name": "ElementaryTypeName",
                        "src": "1577:7:12"
                      }
                    ],
                    "id": 5955,
                    "name": "VariableDeclaration",
                    "src": "1577:7:12"
                  },
                  {
                    "attributes": {
                      "constant": false,
                      "name": "",
                      "scope": 5965,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "bytes memory",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "bytes",
                          "type": "bytes storage pointer"
                        },
                        "id": 5956,
                        "name": "ElementaryTypeName",
                        "src": "1586:5:12"
                      }
                    ],
                    "id": 5957,
                    "name": "VariableDeclaration",
                    "src": "1586:5:12"
                  }
                ],
                "id": 5958,
                "name": "ParameterList",
                "src": "1567:25:12"
              },
              {
                "children": [
                  {
                    "attributes": {
                      "constant": false,
                      "name": "",
                      "scope": 5965,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "bool",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "bool",
                          "type": "bool"
                        },
                        "id": 5959,
                        "name": "ElementaryTypeName",
                        "src": "1613:4:12"
                      }
                    ],
                    "id": 5960,
                    "name": "VariableDeclaration",
                    "src": "1613:4:12"
                  }
                ],
                "id": 5961,
                "name": "ParameterList",
                "src": "1612:6:12"
              },
              {
                "children": [
                  {
                    "attributes": {
                      "functionReturnParameters": 5961
                    },
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "hexvalue": "74727565",
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "subdenomination": null,
                          "token": "bool",
                          "type": "bool",
                          "value": "true"
                        },
                        "id": 5962,
                        "name": "Literal",
                        "src": "1636:4:12"
                      }
                    ],
                    "id": 5963,
                    "name": "Return",
                    "src": "1629:11:12"
                  }
                ],
                "id": 5964,
                "name": "Block",
                "src": "1619:28:12"
              }
            ],
            "id": 5965,
            "name": "FunctionDefinition",
            "src": "1555:92:12"
          },
          {
            "attributes": {
              "constant": true,
              "implemented": true,
              "isConstructor": false,
              "modifiers": [
                null
              ],
              "name": "post",
              "payable": false,
              "scope": 6006,
              "stateMutability": "view",
              "superFunction": null,
              "visibility": "public"
            },
            "children": [
              {
                "children": [
                  {
                    "attributes": {
                      "constant": false,
                      "name": "",
                      "scope": 6005,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "address",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "address",
                          "type": "address"
                        },
                        "id": 5966,
                        "name": "ElementaryTypeName",
                        "src": "1856:7:12"
                      }
                    ],
                    "id": 5967,
                    "name": "VariableDeclaration",
                    "src": "1856:7:12"
                  },
                  {
                    "attributes": {
                      "constant": false,
                      "name": "_paramsHash",
                      "scope": 6005,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "bytes32",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "bytes32",
                          "type": "bytes32"
                        },
                        "id": 5968,
                        "name": "ElementaryTypeName",
                        "src": "1865:7:12"
                      }
                    ],
                    "id": 5969,
                    "name": "VariableDeclaration",
                    "src": "1865:19:12"
                  },
                  {
                    "attributes": {
                      "constant": false,
                      "name": "",
                      "scope": 6005,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "bytes memory",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "bytes",
                          "type": "bytes storage pointer"
                        },
                        "id": 5970,
                        "name": "ElementaryTypeName",
                        "src": "1886:5:12"
                      }
                    ],
                    "id": 5971,
                    "name": "VariableDeclaration",
                    "src": "1886:5:12"
                  }
                ],
                "id": 5972,
                "name": "ParameterList",
                "src": "1855:37:12"
              },
              {
                "children": [
                  {
                    "attributes": {
                      "constant": false,
                      "name": "",
                      "scope": 6005,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "bool",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "bool",
                          "type": "bool"
                        },
                        "id": 5973,
                        "name": "ElementaryTypeName",
                        "src": "1913:4:12"
                      }
                    ],
                    "id": 5974,
                    "name": "VariableDeclaration",
                    "src": "1913:4:12"
                  }
                ],
                "id": 5975,
                "name": "ParameterList",
                "src": "1912:6:12"
              },
              {
                "children": [
                  {
                    "attributes": {
                      "falseBody": null
                    },
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "commonType": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          },
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "operator": "&&",
                          "type": "bool"
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "isConstant": false,
                              "isInlineArray": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "type": "bool"
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "commonType": {
                                    "typeIdentifier": "t_contract$_StandardToken_$10855",
                                    "typeString": "contract StandardToken"
                                  },
                                  "isConstant": false,
                                  "isLValue": false,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "operator": "!=",
                                  "type": "bool"
                                },
                                "children": [
                                  {
                                    "attributes": {
                                      "argumentTypes": null,
                                      "isConstant": false,
                                      "isLValue": true,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "member_name": "token",
                                      "referencedDeclaration": 5895,
                                      "type": "contract StandardToken"
                                    },
                                    "children": [
                                      {
                                        "attributes": {
                                          "argumentTypes": null,
                                          "isConstant": false,
                                          "isLValue": true,
                                          "isPure": false,
                                          "lValueRequested": false,
                                          "type": "struct TokenCapGC.Parameters storage ref"
                                        },
                                        "children": [
                                          {
                                            "attributes": {
                                              "argumentTypes": null,
                                              "overloadedDeclarations": [
                                                null
                                              ],
                                              "referencedDeclaration": 5902,
                                              "type": "mapping(bytes32 => struct TokenCapGC.Parameters storage ref)",
                                              "value": "params"
                                            },
                                            "id": 5976,
                                            "name": "Identifier",
                                            "src": "1934:6:12"
                                          },
                                          {
                                            "attributes": {
                                              "argumentTypes": null,
                                              "overloadedDeclarations": [
                                                null
                                              ],
                                              "referencedDeclaration": 5969,
                                              "type": "bytes32",
                                              "value": "_paramsHash"
                                            },
                                            "id": 5977,
                                            "name": "Identifier",
                                            "src": "1941:11:12"
                                          }
                                        ],
                                        "id": 5978,
                                        "name": "IndexAccess",
                                        "src": "1934:19:12"
                                      }
                                    ],
                                    "id": 5979,
                                    "name": "MemberAccess",
                                    "src": "1934:25:12"
                                  },
                                  {
                                    "attributes": {
                                      "argumentTypes": null,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "isStructConstructorCall": false,
                                      "lValueRequested": false,
                                      "names": [
                                        null
                                      ],
                                      "type": "contract StandardToken",
                                      "type_conversion": true
                                    },
                                    "children": [
                                      {
                                        "attributes": {
                                          "argumentTypes": [
                                            {
                                              "typeIdentifier": "t_rational_0_by_1",
                                              "typeString": "int_const 0"
                                            }
                                          ],
                                          "overloadedDeclarations": [
                                            null
                                          ],
                                          "referencedDeclaration": 10855,
                                          "type": "type(contract StandardToken)",
                                          "value": "StandardToken"
                                        },
                                        "id": 5980,
                                        "name": "Identifier",
                                        "src": "1963:13:12"
                                      },
                                      {
                                        "attributes": {
                                          "argumentTypes": null,
                                          "hexvalue": "30",
                                          "isConstant": false,
                                          "isLValue": false,
                                          "isPure": true,
                                          "lValueRequested": false,
                                          "subdenomination": null,
                                          "token": "number",
                                          "type": "int_const 0",
                                          "value": "0"
                                        },
                                        "id": 5981,
                                        "name": "Literal",
                                        "src": "1977:1:12"
                                      }
                                    ],
                                    "id": 5982,
                                    "name": "FunctionCall",
                                    "src": "1963:16:12"
                                  }
                                ],
                                "id": 5983,
                                "name": "BinaryOperation",
                                "src": "1934:45:12"
                              }
                            ],
                            "id": 5984,
                            "name": "TupleExpression",
                            "src": "1933:47:12"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "isConstant": false,
                              "isInlineArray": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "type": "bool"
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "commonType": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  },
                                  "isConstant": false,
                                  "isLValue": false,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "operator": ">",
                                  "type": "bool"
                                },
                                "children": [
                                  {
                                    "attributes": {
                                      "argumentTypes": null,
                                      "arguments": [
                                        null
                                      ],
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": false,
                                      "isStructConstructorCall": false,
                                      "lValueRequested": false,
                                      "names": [
                                        null
                                      ],
                                      "type": "uint256",
                                      "type_conversion": false
                                    },
                                    "children": [
                                      {
                                        "attributes": {
                                          "argumentTypes": [
                                            null
                                          ],
                                          "isConstant": false,
                                          "isLValue": false,
                                          "isPure": false,
                                          "lValueRequested": false,
                                          "member_name": "totalSupply",
                                          "referencedDeclaration": 10489,
                                          "type": "function () view external returns (uint256)"
                                        },
                                        "children": [
                                          {
                                            "attributes": {
                                              "argumentTypes": null,
                                              "isConstant": false,
                                              "isLValue": true,
                                              "isPure": false,
                                              "lValueRequested": false,
                                              "member_name": "token",
                                              "referencedDeclaration": 5895,
                                              "type": "contract StandardToken"
                                            },
                                            "children": [
                                              {
                                                "attributes": {
                                                  "argumentTypes": null,
                                                  "isConstant": false,
                                                  "isLValue": true,
                                                  "isPure": false,
                                                  "lValueRequested": false,
                                                  "type": "struct TokenCapGC.Parameters storage ref"
                                                },
                                                "children": [
                                                  {
                                                    "attributes": {
                                                      "argumentTypes": null,
                                                      "overloadedDeclarations": [
                                                        null
                                                      ],
                                                      "referencedDeclaration": 5902,
                                                      "type": "mapping(bytes32 => struct TokenCapGC.Parameters storage ref)",
                                                      "value": "params"
                                                    },
                                                    "id": 5985,
                                                    "name": "Identifier",
                                                    "src": "1998:6:12"
                                                  },
                                                  {
                                                    "attributes": {
                                                      "argumentTypes": null,
                                                      "overloadedDeclarations": [
                                                        null
                                                      ],
                                                      "referencedDeclaration": 5969,
                                                      "type": "bytes32",
                                                      "value": "_paramsHash"
                                                    },
                                                    "id": 5986,
                                                    "name": "Identifier",
                                                    "src": "2005:11:12"
                                                  }
                                                ],
                                                "id": 5987,
                                                "name": "IndexAccess",
                                                "src": "1998:19:12"
                                              }
                                            ],
                                            "id": 5988,
                                            "name": "MemberAccess",
                                            "src": "1998:25:12"
                                          }
                                        ],
                                        "id": 5989,
                                        "name": "MemberAccess",
                                        "src": "1998:37:12"
                                      }
                                    ],
                                    "id": 5990,
                                    "name": "FunctionCall",
                                    "src": "1998:39:12"
                                  },
                                  {
                                    "attributes": {
                                      "argumentTypes": null,
                                      "isConstant": false,
                                      "isLValue": true,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "member_name": "cap",
                                      "referencedDeclaration": 5897,
                                      "type": "uint256"
                                    },
                                    "children": [
                                      {
                                        "attributes": {
                                          "argumentTypes": null,
                                          "isConstant": false,
                                          "isLValue": true,
                                          "isPure": false,
                                          "lValueRequested": false,
                                          "type": "struct TokenCapGC.Parameters storage ref"
                                        },
                                        "children": [
                                          {
                                            "attributes": {
                                              "argumentTypes": null,
                                              "overloadedDeclarations": [
                                                null
                                              ],
                                              "referencedDeclaration": 5902,
                                              "type": "mapping(bytes32 => struct TokenCapGC.Parameters storage ref)",
                                              "value": "params"
                                            },
                                            "id": 5991,
                                            "name": "Identifier",
                                            "src": "2040:6:12"
                                          },
                                          {
                                            "attributes": {
                                              "argumentTypes": null,
                                              "overloadedDeclarations": [
                                                null
                                              ],
                                              "referencedDeclaration": 5969,
                                              "type": "bytes32",
                                              "value": "_paramsHash"
                                            },
                                            "id": 5992,
                                            "name": "Identifier",
                                            "src": "2047:11:12"
                                          }
                                        ],
                                        "id": 5993,
                                        "name": "IndexAccess",
                                        "src": "2040:19:12"
                                      }
                                    ],
                                    "id": 5994,
                                    "name": "MemberAccess",
                                    "src": "2040:23:12"
                                  }
                                ],
                                "id": 5995,
                                "name": "BinaryOperation",
                                "src": "1998:65:12"
                              }
                            ],
                            "id": 5996,
                            "name": "TupleExpression",
                            "src": "1996:68:12"
                          }
                        ],
                        "id": 5997,
                        "name": "BinaryOperation",
                        "src": "1933:131:12"
                      },
                      {
                        "children": [
                          {
                            "attributes": {
                              "functionReturnParameters": 5975
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "hexvalue": "66616c7365",
                                  "isConstant": false,
                                  "isLValue": false,
                                  "isPure": true,
                                  "lValueRequested": false,
                                  "subdenomination": null,
                                  "token": "bool",
                                  "type": "bool",
                                  "value": "false"
                                },
                                "id": 5998,
                                "name": "Literal",
                                "src": "2087:5:12"
                              }
                            ],
                            "id": 5999,
                            "name": "Return",
                            "src": "2080:12:12"
                          }
                        ],
                        "id": 6000,
                        "name": "Block",
                        "src": "2066:39:12"
                      }
                    ],
                    "id": 6001,
                    "name": "IfStatement",
                    "src": "1929:176:12"
                  },
                  {
                    "attributes": {
                      "functionReturnParameters": 5975
                    },
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "hexvalue": "74727565",
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "subdenomination": null,
                          "token": "bool",
                          "type": "bool",
                          "value": "true"
                        },
                        "id": 6002,
                        "name": "Literal",
                        "src": "2121:4:12"
                      }
                    ],
                    "id": 6003,
                    "name": "Return",
                    "src": "2114:11:12"
                  }
                ],
                "id": 6004,
                "name": "Block",
                "src": "1919:213:12"
              }
            ],
            "id": 6005,
            "name": "FunctionDefinition",
            "src": "1842:290:12"
          }
        ],
        "id": 6006,
        "name": "ContractDefinition",
        "src": "201:1933:12"
      }
    ],
    "id": 6007,
    "name": "SourceUnit",
    "src": "0:2135:12"
  },
  "compiler": {
    "name": "solc",
    "version": "0.4.18+commit.9cf6e910.Emscripten.clang"
  },
  "networks": {},
  "schemaVersion": "1.0.1",
  "updatedAt": "2018-01-25T13:15:04.381Z"
}