diff --git a/.gitignore b/.gitignore index 2518ae7..9feaec5 100644 --- a/.gitignore +++ b/.gitignore @@ -16,4 +16,5 @@ mocha_test/scripts/poa-genesis.json mocha_test/scripts/pw mocha_test/scripts/st-poa/ -package-lock.json \ No newline at end of file +package-lock.json +build/ diff --git a/.travis.yml b/.travis.yml index df3066b..b127360 100644 --- a/.travis.yml +++ b/.travis.yml @@ -23,12 +23,14 @@ before_install: - sudo apt-get install software-properties-common - sudo add-apt-repository -y ppa:ethereum/ethereum - sudo apt-get update - - sudo bash mocha_test/scripts/install_geth_1_7_3.sh + - sudo bash mocha_test/scripts/install_geth_1_8_3.sh - sudo apt-get install solc - geth version install: - npm install -before_script: +before_script: + - mkdir -p ~/.ethash + - geth makedag 0 ~/.ethash - nohup sh tools/runTestRpc.sh /dev/null 2>&1 & - bash contracts/compile.sh script: diff --git a/CHANGELOG.md b/CHANGELOG.md index 5d7d2d9..837cd91 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,55 @@ +## OpenST-Payments v1.0.5 (17 May 2018) + +Changelog: + +- Fix for double credit issue is done. On few cases of payment transactions beneficiary was credited two times. +- Solidity/solc is upgraded to 0.4.23. All contracts compile warnings are handled and contracts are upgraded with latest syntax. +- Truffle package is upgraded to 4.1.8. +- Fixes for travis broken tests is added. +- New response helper integration. Standardized error codes are now being used in OST Price Oracle. +- OpenST base web3 integration. Web socket connection to geth is now being used and preferred over RPC connection. +- OpenST base integration with logger is done. +- New services for payment success and failure were added. This was part of payment transactions optimization fixes. +- Loggers updated from into to debug wherever necessary. Log level support was introduced and non-important logs were moved to debug log level. +- Gas limit optimization on transactions is done. Predefined calculated gas limit with buffer is defined for each type of transactions. +- Support for web socket is added. +- Geth version updated to 1.0.0-beta.33. + +## OpenST-Payments v1.0.5.beta.1 + +Changelog: +- Added new services and services refactoring +- Readme update as per updated services +- Comments updated for services + +## OpenST-Payments v1.0.4.beta.2 + +Changelog: +- Upgrade Geth and Web3 version +- while transferring from reserve to airdrop budget holder validate if reserve has sufficient balance. + +## OpenST-Payments v1.0.4 + +Changelog: +- Changed error message when insufficient balance +- Changed error message when insufficient gas + +## OpenST-Payments v1.0.3 + +Changelog: +- Added error code for insufficient gas fund +- Added error code for transaction receipt with status 0 + +## OpenST-Payments v1.0.2 + +Changelog: +- Airdrop table caching and integration + +## OpenST-Payments v1.0.1 + +Changelog: +- Fixed - Exception coming when converting Number to BigNumber with high precision + ## OpenST-Payments v1.0.0 (14 March 2018) OpenST-Payments 1.0.0 is the first release of OpenST-Payments. It provides `Airdrop` and `Pricer` contracts for token transfers, defines a `PriceOracle` interface, and introduces the concept of `Workers`. diff --git a/README.md b/README.md index 5f203bb..c833639 100644 --- a/README.md +++ b/README.md @@ -26,6 +26,7 @@ sh start_test_chain.sh ```bash export OST_UTILITY_GETH_RPC_PROVIDER='' +export OST_UTILITY_GETH_WS_PROVIDER='' export OST_UTILITY_DEPLOYER_ADDR='' export OST_UTILITY_DEPLOYER_PASSPHRASE='' export OST_UTILITY_OPS_ADDR='' @@ -73,47 +74,179 @@ export OP_MYSQL_CONNECTION_POOL_SIZE='5' node migrations/create_tables.js ``` -# Example: +# Deploy Service Examples: ```js const OpenSTPayment = require('@openstfoundation/openst-payments') - , deployer = new OpenSTPayment.deployer() - , opsManaged = new OpenSTPayment.opsManaged(contractAddress, gasPrice, chainId) - , workers = new OpenSTPayment.worker(workerContractAddress, chainId) - , airdrop = new OpenSTPayment.airdrop(airdropContractAddress, chainId) - , airdropManager = OpenSTPayment.airdropManager + , Deploy = OpenSTPayment.services.deploy +; + // Deploy Workers + const deployWorkerObject = new Deploy.workers({ + gas_price: gasPrice, + options: {returnType: 'txHash'} + }); + deployWorkerObject.perform(); + + // Deploy Airdrop + const deployAirdropObject = new Deploy.airdrop({ + branded_token_contract_address: brandedTokenAddress, + base_currency: baseCurrency, + worker_contract_address: workerContractAddress, + airdrop_budget_holder: airdropBudgetHolder, + gas_price: gasPrice, + options: {returnType: 'txHash'} + }); + deployAirdropObject.perform(); + +``` + +# OpsManaged Service Examples +```js +const OpenSTPayment = require('@openstfoundation/openst-payments') + , OpsManaged = OpenSTPayment.services.opsManaged ; - // Deploy Contract - deployer.deploy( contractName, constructorArgs, gasPrice, options); - // Register Airdrop - airdropManager.registerAirdrop(airdropContractAddress, chainId); // Set Ops Address - opsManaged.setOpsAddress(deployerAddress, deployerPassphrase, opsAddress, options); + const setOpsObject = new OpsManaged.setOps({ + contract_address: contractAddress, + gas_price: gasPrice, + chain_id: chainId, + deployer_address: deployerAddress, + deployer_passphrase: deployerPassphrase, + ops_address: opsAddress, + options: {returnType: 'txHash'} + }); + setOpsObject.perform(); + + // Get Ops Address + const getOpsObject = new OpsManaged.getOps({ + contract_address: contractAddress, + gas_price: gasPrice, + chain_id: chainId + }); + getOpsObject.perform(); +``` + +# Workers Service Examples +```js +const OpenSTPayment = require('@openstfoundation/openst-payments') + , Workers = OpenSTPayment.services.workers +; // Set Worker - workers.setWorker(senderAddress, senderPassphrase, workerAddress, deactivationHeight, gasPrice, options); + const setWorkerObject = new Workers.setWorker({ + workers_contract_address: constants.workersContractAddress, + sender_address: constants.ops, + sender_passphrase: constants.opsPassphrase, + worker_address: workerAddress, + deactivation_height: deactivationHeight.toString(10), + gas_price: gasPrice, + chain_id: chainId, + options: {returnType: 'txHash'} + }); + setWorkerObject.perform(); + + // Is Worker + const isWorkerObject = new Workers.isWorker({ + workers_contract_address: workersContractAddress, + worker_address: workerAddress, + chain_id: chainId + }); + isWorkerObject.perform(); +``` + +# Airdrop Management Service Examples: +```js +const OpenSTPayment = require('@openstfoundation/openst-payments') + , AirdropManager = OpenSTPayment.services.airdropManager +; + // Register Airdrop + const registerObject = new AirdropManager.register({ + airdrop_contract_address: airdropContractAddress, + chain_id: chainId + }); + registerObject.perform(); + // Set Price Oracle - airdrop.setPriceOracle(senderAddress, senderPassphrase, currency, address, gasPrice, options); + const setPriceOracleObject = new AirdropManager.setPriceOracle({ + airdrop_contract_address: airdropContractAddress, + chain_id: chainId, + sender_address: senderAddress, + sender_passphrase: senderPassphrase, + currency: currency, + price_oracle_contract_address: priceOracleContractAddress, + gas_price: gasPrice, + options: {tag: 'airdrop.setPriceOracle', returnType: 'txHash'} + }); + setPriceOracleObject.perform(); + // Set Accepted Margin - airdrop.setAcceptedMargin(senderAddress, senderPassphrase, currency, acceptedMargin, gasPrice, options); + const setAcceptedMarginObject = new AirdropManager.setAcceptedMargin({ + airdrop_contract_address: airdropContractAddress, + chain_id: chainId, + sender_address: senderAddress, + sender_passphrase: senderPassphrase, + currency: currency, + accepted_margin: acceptedMargin, + gas_price: gasPrice, + options: {tag: 'airdrop.setAcceptedMargin', returnType: 'txHash'} + }); + setAcceptedMarginObject.perform(); + // Transfer Amount to airdrop budget holder - airdropManager.transfer(senderAddress, senderPassphrase, airdropContractAddress, amount, gasPrice, chainId, options); + const transferObject = new AirdropManager.transfer({ + sender_address: senderAddress, + sender_passphrase: senderPassphrase, + airdrop_contract_address: airdropContractAddress, + amount: airdropBudgetAmountInWei, + gas_price: gasPrice, + chain_id: chainId, + options: {tag: 'airdrop.transfer', returnType: 'txHash'} + }); + transferObject.perform(); + // Approve airdrop budget holder - airdropManager.approve(airdropContractAddress, airdropBudgetHolderPassphrase, gasPrice, chainId, options); + const approveObject = new AirdropManager.approve({ + airdrop_contract_address: airdropContractAddress, + airdrop_budget_holder_passphrase: airdropBudgetHolderPassphrase, + gas_price: gasPrice, + chain_id: chainId, + options: {tag: 'airdrop.approve', returnType: 'txHash'} + }); + approveObject.perform(); + // Allocate airdrop amount to users in batch - airdropManager.batchAllocate(airdropContractAddress, transactionHash, airdropUsers, chainId); + const batchAllocatorObject = new AirdropManager.batchAllocator({ + airdrop_contract_address: airdropContractAddress, + transaction_hash: transactionHash, + airdrop_users: {userAddress1: {airdropAmount: amountInWei, expiryTimestamp: 0}, userAddress2: {airdropAmount: amountInWei, expiryTimestamp: 0}}, + chain_id: chainId + }); + batchAllocatorObject.perform(); + // Get Users Airdrop Balance - airdropManager.getAirdropBalance(chainId, airdropContractAddress, userAddresses); + const userBalanceObject = new AirdropManager.userBalance({ + airdrop_contract_address: airdropContractAddress, + chain_id: chainId, + user_addresses: [user1, user2] + }); + userBalanceObject.perform(); + // Call Pay method - airdrop.pay(workerAddress, - WorkerPassphrase, - beneficiaryAddress, - transferAmount, - commissionBeneficiaryAddress, - commissionAmount, - currency, - intendedPricePoint, - spender, - gasPrice, - {tag:'airdrop.pay', returnType: 'txHash'}); + const payObject = new AirdropManager.pay({ + airdrop_contract_address: airdropContractAddress, + chain_id: chainId, + sender_worker_address: workerAddress, + sender_worker_passphrase: workerPassphrase, + beneficiary_address: beneficiary, + transfer_amount: transferAmount.toString(10), + commission_beneficiary_address: commissionBeneficiary, + commission_amount: commissionAmount.toString(10), + currency: currency, + intended_price_point: intendedPricePoint, + spender: spenderAddress, + gas_price: gasPrice, + options: {tag:'airdrop.pay', returnType: 'txHash'} + }); + payObject.perform() + ``` For further implementation details, please refer to the [API documentation](https://openstfoundation.github.io/openst-payments/). \ No newline at end of file diff --git a/VERSION b/VERSION index afaf360..1464c52 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.0.0 \ No newline at end of file +1.0.5 \ No newline at end of file diff --git a/app/models/airdrop.js b/app/models/airdrop.js index 528ff33..e645186 100644 --- a/app/models/airdrop.js +++ b/app/models/airdrop.js @@ -47,6 +47,19 @@ const AirdropKlassPrototype = { */ tableName: 'airdrops', + /** + * Select all airdrop contracts + * + * @return {Promise} + * + */ + getAll: function() { + const oThis = this + ; + + return oThis.select().fire(); + }, + /** * get airdrop AR by contract Address * @@ -62,6 +75,7 @@ const AirdropKlassPrototype = { return oThis.select().where(["contract_address=?", airdropContractAddress]). limit(1).fire(); } + }; Object.assign(AirdropKlass.prototype, AirdropKlassPrototype); diff --git a/app/models/airdrop_allocation_proof_detail.js b/app/models/airdrop_allocation_proof_detail.js index 6112481..5bd4f2a 100644 --- a/app/models/airdrop_allocation_proof_detail.js +++ b/app/models/airdrop_allocation_proof_detail.js @@ -11,8 +11,16 @@ const rootPrefix = '../..' , QueryDBKlass = require(rootPrefix + '/app/models/queryDb') , ModelBaseKlass = require(rootPrefix + '/app/models/base') , responseHelper = require(rootPrefix + '/lib/formatter/response') + , logger = require(rootPrefix + '/helpers/custom_console_logger') + , paramErrorConfig = require(rootPrefix + '/config/param_error_config') + , apiErrorConfig = require(rootPrefix + '/config/api_error_config') ; +const errorConfig = { + param_error_config: paramErrorConfig, + api_error_config: apiErrorConfig +}; + const dbName = coreConstants.MYSQL_DATABASE , QueryDBObj = new QueryDBKlass(dbName) ; @@ -62,7 +70,13 @@ const AirdropAllocationProofDetailKlassPrototype = { }); return responseHelper.successWithData({response: insertedRecord}); } catch(err){ - return responseHelper.error('l_aapd_cr_1', 'Error creating airdrop_allocation_proof_details record:'+err); + let errorParams = { + internal_error_identifier: 'l_aapd_cr_1', + api_error_identifier: 'entry_creation_failed', + error_config: errorConfig, + debug_options: { err: err } + }; + return responseHelper.error(errorParams); } }, @@ -84,7 +98,13 @@ const AirdropAllocationProofDetailKlassPrototype = { await oThis.update({airdrop_allocated_amount: allocatedAmount}).where(["id=?", id]).fire(); return responseHelper.successWithData({}); } catch(err){ - return responseHelper.error('l_a_m_aapd_1', 'Something went wrong while updating record id:'+id+" err: "+err); + let errorParams = { + internal_error_identifier: 'l_a_m_aapd_1', + api_error_identifier: 'entry_updation_failed', + error_config: errorConfig, + debug_options: { err: err } + }; + return responseHelper.error(errorParams); } }, diff --git a/app/models/base.js b/app/models/base.js index ae95857..da54f06 100644 --- a/app/models/base.js +++ b/app/models/base.js @@ -4,7 +4,6 @@ const rootPrefix = '../..' , utils = require(rootPrefix + '/lib/utils') , MysqlQueryKlass = require(rootPrefix + '/lib/query_builders/mysql') , mysqlWrapper = require(rootPrefix + "/lib/mysql_wrapper") - , responseHelper = require(rootPrefix + '/lib/formatter/response') , logger = require(rootPrefix + '/helpers/custom_console_logger') ; @@ -57,12 +56,12 @@ const ModelBaseKlassPrototype = { const queryGenerator = oThis.generate(); if(queryGenerator.isSuccess()){ - //console.log(queryGenerator.data.query, queryGenerator.data.queryData); + //logger.debug(queryGenerator.data.query, queryGenerator.data.queryData); } var pre_query = Date.now(); var qry = oThis.onWriteConnection().query(queryGenerator.data.query, queryGenerator.data.queryData, function (err, result, fields) { - logger.info("(", (Date.now() - pre_query), "ms)", qry.sql); + logger.debug("(", (Date.now() - pre_query), "ms)", qry.sql); if (err) { onReject(err); } else { diff --git a/app/models/queryDb.js b/app/models/queryDb.js index 3fb72b6..151a5c0 100644 --- a/app/models/queryDb.js +++ b/app/models/queryDb.js @@ -52,7 +52,7 @@ QueryDB.prototype = { // get a timestamp before running the query var pre_query = Date.now(); var qry = oThis.onReadConnection().query(q, whereClauseValues, function (err, result, fields) { - logger.info("(%s ms) %s", (Date.now() - pre_query), qry.sql); + logger.debug("(%s ms) %s", (Date.now() - pre_query), qry.sql); if (err) { onReject(err); } else { @@ -74,7 +74,7 @@ QueryDB.prototype = { // get a timestamp before running the query var pre_query = Date.now(); var qry = oThis.onReadConnection().query(q, function (err, result, fields) { - logger.info("(%s ms) %s", (Date.now() - pre_query), qry.sql); + logger.debug("(%s ms) %s", (Date.now() - pre_query), qry.sql); if (err) { onReject(err); } else { @@ -100,7 +100,7 @@ QueryDB.prototype = { // get a timestamp before running the query var pre_query = Date.now(); var qry = oThis.onWriteConnection().query(q, [queryArgs], function (err, result, fields) { - logger.info("(%s ms) %s", (Date.now() - pre_query), qry.sql); + logger.debug("(%s ms) %s", (Date.now() - pre_query), qry.sql); if (err) { onReject(err); } else { @@ -127,8 +127,8 @@ QueryDB.prototype = { // get a timestamp before running the query var pre_query = Date.now(); var qry = oThis.onWriteConnection().query(q, [queryArgs], function (err, result, fields) { - logger.info("=======Insert Query======="); - logger.info("(%s ms) %s", (Date.now() - pre_query), qry.sql); + logger.debug("=======Insert Query======="); + logger.debug("(%s ms) %s", (Date.now() - pre_query), qry.sql); if (err) { onReject(err); } else { @@ -165,7 +165,7 @@ QueryDB.prototype = { , q = 'UPDATE '+tableName+' set '+fields+' where '+whereClause; var qry = oThis.onWriteConnection().query(q, queryArgs, function (err, result, fields) { - logger.info("(%s ms) %s", (Date.now() - pre_query), qry.sql); + logger.debug("(%s ms) %s", (Date.now() - pre_query), qry.sql); if (err) { onReject(err); } else { @@ -193,7 +193,7 @@ QueryDB.prototype = { var pre_query = Date.now(); var qry = oThis.onWriteConnection().query(query, [], function (err, result, fields) { - logger.info("(%s ms) %s", (Date.now() - pre_query), qry.sql); + logger.debug("(%s ms) %s", (Date.now() - pre_query), qry.sql); if (err) { onReject(err); } else { diff --git a/app/models/user_airdrop_detail.js b/app/models/user_airdrop_detail.js index b01f59f..912250e 100644 --- a/app/models/user_airdrop_detail.js +++ b/app/models/user_airdrop_detail.js @@ -7,8 +7,15 @@ const rootPrefix = '../..' , responseHelper = require(rootPrefix + '/lib/formatter/response') , logger = require(rootPrefix + '/helpers/custom_console_logger') , BigNumber = require('bignumber.js') + , paramErrorConfig = require(rootPrefix + '/config/param_error_config') + , apiErrorConfig = require(rootPrefix + '/config/api_error_config') ; +const errorConfig = { + param_error_config: paramErrorConfig, + api_error_config: apiErrorConfig +}; + const dbName = coreConstants.MYSQL_DATABASE , QueryDBObj = new QueryDBKlass(dbName) ; @@ -39,8 +46,8 @@ const UserAirdropDetailKlassPrototype = { */ getByUserAddresses: async function (airdropId, userAddresses) { var oThis = this; - logger.info("========user_airdrop_detail.getByUserAddresses().userAddresses========="); - logger.info(userAddresses); + logger.debug("========user_airdrop_detail.getByUserAddresses().userAddresses========="); + logger.debug(userAddresses); return new Promise(async function (onResolve, onReject) { var result = {} , userAirdropDetail = {} @@ -58,7 +65,7 @@ const UserAirdropDetailKlassPrototype = { for (var i in userAddresses) { userAddressesMap[userAddresses[i].toLowerCase()] = userAddresses[i]; } - logger.info("userAddressesMap ", userAddressesMap); + logger.debug("userAddressesMap ", userAddressesMap); for (var uadIndex in userAirdropDetailResultArray) { userAirdropDetail = userAirdropDetailResultArray[uadIndex]; @@ -73,11 +80,18 @@ const UserAirdropDetailKlassPrototype = { balanceAirdropAmount: balanceAirdropAmount.toString(10) }; } - logger.info("========user_airdrop_detail.getByUserAddresses().result========="); - logger.info(result); + logger.debug("========user_airdrop_detail.getByUserAddresses().result========="); + logger.debug(result); return onResolve(responseHelper.successWithData(result)); } catch (error) { - return onResolve(responseHelper.error('a_m_uad_1', 'error:' + error)); + let errorParams = { + internal_error_identifier: 'a_m_uad_1', + api_error_identifier: 'select_airdrop_users_failed', + error_config: errorConfig, + debug_options: {} + }; + logger.error(error); + return onResolve(responseHelper.error(errorParams)); } }); diff --git a/config/api_error_config.json b/config/api_error_config.json new file mode 100644 index 0000000..8e1b5fe --- /dev/null +++ b/config/api_error_config.json @@ -0,0 +1,127 @@ +{ + "invalid_api_params": { + "http_code": "400", + "code": "invalid_request", + "message": "At least one parameter is invalid or missing. See err.error_data for more details." + }, + "entry_creation_failed": { + "http_code": "200", + "code": "entry_creation_failed", + "message": "There seems to be an error with entry creation" + }, + "entry_updation_failed": { + "http_code": "200", + "code": "entry_updation_failed", + "message": "There seems to be an error with entry updation" + }, + "select_airdrop_users_failed": { + "http_code": "200", + "code": "select_airdrop_users_failed", + "message": "Technical error in getting airdrop users" + }, + "unhandled_api_error": { + "http_code": "500", + "code": "unhandled_api_error", + "message": "Can't proceed due to unhandled error" + }, + "no_events_in_receipt": { + "http_code": "200", + "code": "no_events_in_receipt", + "message": "No events found in the transaction receipt" + }, + "amount_invalid": { + "http_code": "422", + "code": "amount_invalid", + "message": "One or more of the amounts used are invalid" + }, + "user_address_invalid": { + "http_code": "422", + "code": "user_address_invalid", + "message": "One or more of the amounts used are invalid" + }, + "record_not_found": { + "http_code": "422", + "code": "record_not_found", + "message": "There is no record for processing" + }, + "amount_update_failed": { + "http_code": "500", + "code": "amount_update_failed", + "message": "Could not adjust the amount due to technical failure" + }, + "data_not_found": { + "http_code": "204", + "code": "data_not_found", + "message": "Could not find the data in DB" + }, + "db_get_failed": { + "http_code": "422", + "code": "db_get_failed", + "message": "Technical error in getting the data" + }, + "insufficient_funds": { + "http_code": "422", + "code": "insufficient_funds", + "message": "Can't proceed due to insufficient funds" + }, + "something_went_wrong": { + "http_code": "500", + "code": "something_went_wrong", + "message": "" + }, + "could_not_process": { + "http_code": "422", + "code": "unprocessable_entity", + "message": "Cannot process due to error" + }, + "get_receipt_failed": { + "http_code": "422", + "code": "get_receipt_failed", + "message": "Get receipt failed due to timeout or other error" + }, + "invalid_receipt": { + "http_code": "422", + "code": "invalid_receipt", + "message": "Obtained receipt is invalid" + }, + "contract_address_invalid": { + "http_code": "422", + "code": "invalid_contract_address", + "message": "Contract address is invalid" + }, + "get_balance_failed": { + "http_code": "422", + "code": "get_balance_failed", + "message": "Get balance failed due to timeout or error" + }, + "invalid_amount": { + "http_code": "422", + "code": "invalid_amount", + "message": "Amount is not appropriate for the action" + }, + "invalid_object": { + "http_code": "422", + "code": "invalid_object", + "message": "Object is invalid" + }, + "batch_size_exceeded": { + "http_code": "422", + "code": "airdrop_batch_size_exceeded", + "message": "Airdrop batch size exceeded" + }, + "timestamp_invalid": { + "http_code": "422", + "code": "timestamp_invalid", + "message": "Timestamp is not valid" + }, + "invalid_deployer_passphrase": { + "http_code": "422", + "code": "invalid_deployer_passphrase", + "message": "Deployer passphrase is invalid" + }, + "contract_deploy_failed": { + "http_code": "422", + "code": "contract_deploy_failed", + "message": "Contract deployment failed" + } +} diff --git a/config/core_constants.js b/config/core_constants.js index eb6ac87..a6274a6 100644 --- a/config/core_constants.js +++ b/config/core_constants.js @@ -16,13 +16,11 @@ function define(name, value) { }); } //Cache engine -define('CACHING_ENGINE', process.env.OST_CACHING_ENGINE), +define('CACHING_ENGINE', process.env.OST_CACHING_ENGINE); // Geth define('OST_UTILITY_GETH_RPC_PROVIDER', process.env.OST_UTILITY_GETH_RPC_PROVIDER); -// Gas limit -define('OST_GAS_LIMIT', 9000000); -define('OST_PAY_GAS_LIMIT', 150000); +define('OST_UTILITY_GETH_WS_PROVIDER', process.env.OST_UTILITY_GETH_WS_PROVIDER); // MySQL details define("MYSQL_HOST", process.env.OP_MYSQL_HOST); diff --git a/config/param_error_config.json b/config/param_error_config.json new file mode 100644 index 0000000..60527b5 --- /dev/null +++ b/config/param_error_config.json @@ -0,0 +1,130 @@ +{ + "gas_price_invalid": { + "name": "gasPrice", + "message": "Gas price is either undefined or invalid" + }, + "chain_id_invalid": { + "name": "chainId", + "message": "Chain id is either undefined or invalid" + }, + "negative_airdrop_amount": { + "name": "airdropAmountUsed", + "message": "Negative airdrop amount is invalid" + }, + "invalid_user_address": { + "name": "userAddress", + "message": "Invalid user address" + }, + "invalid_sender_address": { + "name": "senderAddress", + "message": "Invalid sender address" + }, + "invalid_spender_address": { + "name": "spenderAddress", + "message": "Invalid spender address" + }, + "negative_transfer_amount": { + "name": "transferAmount", + "message": "Negative transfer amount is invalid" + }, + "zero_transfer_amount": { + "name": "transferAmount", + "message": "Zero transfer amount is invalid" + }, + "invalid_commission_amount": { + "name": "commissionAmount", + "message": "Commission amount is negative or a float" + }, + "beneficiary_address_invalid": { + "name": "beneficiaryAddress", + "message": "Beneficiary address is not valid" + }, + "commission_beneficiary_address_invalid": { + "name": "commissionBeneficiaryAddress", + "message": "Commission beneficiary address is not valid" + }, + "invalid_currency": { + "name": "currency", + "message": "Currency is invalid" + }, + "price_point_invalid": { + "name": "intendedPricePoint", + "message": "Price point invalid for given currency" + }, + "branded_token_address_invalid": { + "name": "contractAddress", + "message": "Branded token address is invalid" + }, + "airdrop_budget_holder_invalid": { + "name": "airdropBudgetHolder", + "message": "Airdrop budget holder address invalid" + }, + "total_amount_invalid": { + "name": "totalAmount", + "message": "Total amount cannot be negative or floating" + }, + "airdrop_amount_invalid": { + "name": "airdropAmountToUse", + "message": "Airdrop amount cannot be negative or floating" + }, + "accepted_margin_invalid": { + "name": "acceptedMargin", + "message": "Accepted margin is negative or invalid" + }, + "invalid_transaction_hash": { + "name": "transactionHash", + "message": "Transaction hash is invalid" + }, + "invalid_worker_address": { + "name": "workerAddress", + "message": "Worker address is invalid" + }, + "airdrop_contract_address_invalid": { + "name": "airdrop_contract_address", + "message": "Airdrop contract address is invalid" + }, + "airdrop_contract_already_registered": { + "name": "airdrop_contract_address", + "message": "Airdrop contract is already registered" + }, + "invalid_amount": { + "name": "amount", + "message": "Amount is invalid" + }, + "invalid_decoded_events": { + "name": "decodedEvents", + "message": "decoded events are invalid" + }, + "price_oracle_address_invalid": { + "name": "priceOracleContractAddress", + "message": "Price oracle contract address is invalid" + }, + "invalid_options": { + "name": "options", + "message": "options for txHash/txReceipt are invalid" + }, + "base_currency_invalid": { + "name": "baseCurrency", + "message": "Base currency is invalid" + }, + "contract_name_invalid": { + "name": "contractName", + "message": "contract name is invalid" + }, + "gas_limit_invalid": { + "name": "gasLimit", + "message": "Gas limit is invalid" + }, + "deployer_invalid": { + "name": "deployerAddress", + "message": "Deployer address is invalid" + }, + "invalid_contract_address": { + "name": "contractAddress", + "message": "Invalid contract address" + }, + "deactivation_height_invalid": { + "name": "deactivationHeight", + "message": "Deactivation height is invalid" + } +} diff --git a/contracts/Airdrop.sol b/contracts/Airdrop.sol index 201d399..8a6bc03 100644 --- a/contracts/Airdrop.sol +++ b/contracts/Airdrop.sol @@ -1,5 +1,5 @@ /* solhint-disable-next-line compiler-fixed */ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; // Copyright 2018 OpenST Ltd. // @@ -59,14 +59,13 @@ contract Airdrop is Pricer { /// @param _baseCurrency Base Currency /// @param _workers Workers contract address /// @param _airdropBudgetHolder Airdrop Budget Holder Address - function Airdrop( + constructor( address _brandedToken, bytes3 _baseCurrency, Workers _workers, address _airdropBudgetHolder) public Pricer(_brandedToken, _baseCurrency) - OpsManaged() { require(_workers != address(0)); require(_airdropBudgetHolder != address(0)); @@ -124,7 +123,7 @@ contract Airdrop is Pricer { _commissionBeneficiary, commissionTokenAmount)); /// Emit AirdropPayment Event - AirdropPayment(_beneficiary, tokenAmount, _commissionBeneficiary, + emit AirdropPayment(_beneficiary, tokenAmount, _commissionBeneficiary, commissionTokenAmount, _currency, pricePoint, _spender, airdropUsed); return ((tokenAmount + commissionTokenAmount), airdropUsed); diff --git a/contracts/EIP20TokenMock.sol b/contracts/EIP20TokenMock.sol index eaac984..0213e4e 100644 --- a/contracts/EIP20TokenMock.sol +++ b/contracts/EIP20TokenMock.sol @@ -1,5 +1,5 @@ /* solhint-disable-next-line compiler-fixed */ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; // Copyright 2018 OpenST Ltd. // @@ -36,7 +36,7 @@ contract EIP20TokenMock is EIP20Token { /// @param _symbol symbol /// @param _name name /// @param _decimals decimals - function EIP20TokenMock( + constructor( uint256 _conversionRate, uint8 _conversionRateDecimals, string _symbol, diff --git a/contracts/OpsManaged.sol b/contracts/OpsManaged.sol index 3403787..46c9d5b 100644 --- a/contracts/OpsManaged.sol +++ b/contracts/OpsManaged.sol @@ -1,4 +1,4 @@ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; // Copyright 2017 OpenST Ltd. // @@ -36,7 +36,7 @@ contract OpsManaged is Owned { event OpsAddressChanged(address indexed _newAddress); - function OpsManaged() public + constructor() public Owned() { } @@ -89,7 +89,7 @@ contract OpsManaged is Owned { adminAddress = _adminAddress; - AdminAddressChanged(_adminAddress); + emit AdminAddressChanged(_adminAddress); return true; } @@ -103,7 +103,7 @@ contract OpsManaged is Owned { opsAddress = _opsAddress; - OpsAddressChanged(_opsAddress); + emit OpsAddressChanged(_opsAddress); return true; } diff --git a/contracts/Owned.sol b/contracts/Owned.sol index d748cf7..9d2899d 100644 --- a/contracts/Owned.sol +++ b/contracts/Owned.sol @@ -1,4 +1,4 @@ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; // Copyright 2017 OpenST Ltd. // @@ -34,7 +34,7 @@ contract Owned { event OwnershipTransferCompleted(address indexed _newOwner); - function Owned() public { + constructor() public { owner = msg.sender; } @@ -53,7 +53,7 @@ contract Owned { function initiateOwnershipTransfer(address _proposedOwner) public onlyOwner returns (bool) { proposedOwner = _proposedOwner; - OwnershipTransferInitiated(_proposedOwner); + emit OwnershipTransferInitiated(_proposedOwner); return true; } @@ -65,7 +65,7 @@ contract Owned { owner = proposedOwner; proposedOwner = address(0); - OwnershipTransferCompleted(owner); + emit OwnershipTransferCompleted(owner); return true; } diff --git a/contracts/PriceOracleInterface.sol b/contracts/PriceOracleInterface.sol index 8354153..c6f640a 100644 --- a/contracts/PriceOracleInterface.sol +++ b/contracts/PriceOracleInterface.sol @@ -1,5 +1,5 @@ /* solhint-disable-next-line compiler-fixed */ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; // Copyright 2018 OpenST Ltd. // diff --git a/contracts/PriceOracleMock.sol b/contracts/PriceOracleMock.sol index c120a9c..cf91077 100644 --- a/contracts/PriceOracleMock.sol +++ b/contracts/PriceOracleMock.sol @@ -1,5 +1,5 @@ /* solhint-disable-next-line compiler-fixed */ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; // Copyright 2018 OpenST Ltd. // @@ -48,7 +48,7 @@ contract PriceOracleMock is PriceOracleInterface { /// @dev constructor function /// @param _baseCurrency baseCurrency /// @param _quoteCurrency quoteCurrency - function PriceOracleMock( + constructor( bytes3 _baseCurrency, bytes3 _quoteCurrency, uint256 _price diff --git a/contracts/Pricer.sol b/contracts/Pricer.sol index ce74df9..4253a54 100644 --- a/contracts/Pricer.sol +++ b/contracts/Pricer.sol @@ -1,5 +1,5 @@ /* solhint-disable-next-line compiler-fixed */ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; // Copyright 2018 OpenST Ltd. // @@ -66,7 +66,7 @@ contract Pricer is OpsManaged, PricerInterface { /// public method; /// @param _brandedToken Branded Token /// @param _baseCurrency Base Currency - function Pricer( + constructor( address _brandedToken, bytes3 _baseCurrency) public @@ -89,7 +89,7 @@ contract Pricer is OpsManaged, PricerInterface { external onlyAdminOrOps { - Removed(msg.sender); + emit Removed(msg.sender); selfdestruct(msg.sender); } @@ -192,7 +192,7 @@ contract Pricer is OpsManaged, PricerInterface { pricerPriceOracles[_currency] = PriceOracleInterface(_oracleAddress); //Trigger PriceOracleSet event - PriceOracleSet(_currency, _oracleAddress); + emit PriceOracleSet(_currency, _oracleAddress); return true; } @@ -213,7 +213,7 @@ contract Pricer is OpsManaged, PricerInterface { delete pricerPriceOracles[_currency]; //Trigger PriceOracleUnset event - PriceOracleUnset(_currency); + emit PriceOracleUnset(_currency); return true; } @@ -234,7 +234,7 @@ contract Pricer is OpsManaged, PricerInterface { { pricerAcceptedMargins[_currency] = _acceptedMargin; // Trigger AcceptedMarginSet event - AcceptedMarginSet(_currency, _acceptedMargin); + emit AcceptedMarginSet(_currency, _acceptedMargin); return true; } @@ -307,7 +307,7 @@ contract Pricer is OpsManaged, PricerInterface { _commissionBeneficiary, commissionTokenAmount)); //Trigger Event for PaymentComplete - Payment(_beneficiary, tokenAmount, _commissionBeneficiary, + emit Payment(_beneficiary, tokenAmount, _commissionBeneficiary, commissionTokenAmount, _currency, _intendedPricePoint, pricePoint); return (tokenAmount + commissionTokenAmount); } diff --git a/contracts/PricerInterface.sol b/contracts/PricerInterface.sol index 2859f1e..608bd82 100644 --- a/contracts/PricerInterface.sol +++ b/contracts/PricerInterface.sol @@ -1,5 +1,5 @@ /* solhint-disable-next-line compiler-fixed */ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; // Copyright 2018 OpenST Ltd. // diff --git a/contracts/SafeMath.sol b/contracts/SafeMath.sol index 379f7be..47dd86b 100644 --- a/contracts/SafeMath.sol +++ b/contracts/SafeMath.sol @@ -1,4 +1,4 @@ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; // Copyright 2017 OpenST Ltd. // diff --git a/contracts/Workers.sol b/contracts/Workers.sol index 278582c..27fd7c6 100644 --- a/contracts/Workers.sol +++ b/contracts/Workers.sol @@ -1,4 +1,4 @@ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; // Copyright 2018 OpenST Ltd. // @@ -51,7 +51,7 @@ contract Workers is OpsManaged { /// @dev Constructor; /// public method; - function Workers() + constructor() public OpsManaged() { @@ -76,7 +76,7 @@ contract Workers is OpsManaged { workers[_worker] = _deactivationHeight; uint256 remainingHeight = _deactivationHeight - block.number; //Event for worker set - WorkerSet(_worker, _deactivationHeight, remainingHeight); + emit WorkerSet(_worker, _deactivationHeight, remainingHeight); return (remainingHeight); } @@ -96,7 +96,7 @@ contract Workers is OpsManaged { delete workers[_worker]; //Event for worker removed - WorkerRemoved(_worker, existed); + emit WorkerRemoved(_worker, existed); return existed; } diff --git a/contracts/bin/Airdrop.bin b/contracts/bin/Airdrop.bin index 926b127..70465ec 100644 --- a/contracts/bin/Airdrop.bin +++ b/contracts/bin/Airdrop.bin @@ -1 +1 @@ -6060604052341561000f57600080fd5b604051608080620016c78339810160405280805191906020018051919060200180519190602001805160008054600160a060020a03191633600160a060020a039081169190911790915590925085915084908216151561006e57600080fd5b7fffffff00000000000000000000000000000000000000000000000000000000008116151561009c57600080fd5b60048054600160a060020a031916600160a060020a0384811691909117918290556007805462ffffff19167d01000000000000000000000000000000000000000000000000000000000085041790551663313ce5676000604051602001526040518163ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401602060405180830381600087803b151561014157600080fd5b6102c65a03f1151561015257600080fd5b50505060405180516007805460ff90921663010000000263ff0000001990921691909117905550600160a060020a038216637ffdf53e6000604051602001526040518163ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401602060405180830381600087803b15156101d857600080fd5b6102c65a03f115156101e957600080fd5b505050604051805160085550600160a060020a03821663e30ac6c36000604051602001526040518163ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401602060405180830381600087803b151561025457600080fd5b6102c65a03f1151561026557600080fd5b50505060405180516009805460ff191660ff92909216919091179055505050600160a060020a038216151561029957600080fd5b600160a060020a03811615156102ae57600080fd5b6009805461010060a860020a031916610100600160a060020a0394851602179055600a8054600160a060020a03191691909216179055506113d0905080620002f76000396000f30060606040526004361061012f5763ffffffff60e060020a60003504166310f6fa4781146101345780632c1e816d14610163578063313ce567146101965780634a9569c5146101bf578063707789c5146101f15780637307453a146102105780637ffdf53e1461023057806383121455146102435780638da5cb5b146102635780638ea643761461027657806392a85fde14610289578063a1543600146102b9578063a7f4377914610303578063ae20a9ae14610318578063b2b802c814610378578063bbd30f10146103b4578063bd90bc30146103d4578063c0b6f561146103f7578063cabb62f014610416578063d153b60c14610429578063d348050c1461043c578063e30ac6c31461044f578063e71a781114610462578063f3443dd214610475578063fc6f9468146104a1575b600080fd5b341561013f57600080fd5b6101476104b4565b604051600160a060020a03909116815260200160405180910390f35b341561016e57600080fd5b610182600160a060020a03600435166104c3565b604051901515815260200160405180910390f35b34156101a157600080fd5b6101a9610589565b60405160ff909116815260200160405180910390f35b34156101ca57600080fd5b6101df600160e860020a031960043516610599565b60405190815260200160405180910390f35b34156101fc57600080fd5b610182600160a060020a03600435166105b5565b341561021b57600080fd5b610182600160e860020a03196004351661067b565b341561023b57600080fd5b6101df61071b565b341561024e57600080fd5b610147600160e860020a031960043516610721565b341561026e57600080fd5b610147610746565b341561028157600080fd5b610147610755565b341561029457600080fd5b61029c610764565b604051600160e860020a0319909116815260200160405180910390f35b34156102c457600080fd5b6102df600435602435600160e860020a03196044351661078a565b60405180848152602001838152602001828152602001935050505060405180910390f35b341561030e57600080fd5b6103166107d5565b005b341561032357600080fd5b610360600160a060020a036004358116906024359060443581169060643590600160e860020a0319608435169060a4359060c4351660e43561083a565b60405191825260208201526040908101905180910390f35b341561038357600080fd5b6101df600160a060020a036004358116906024359060443516606435600160e860020a03196084351660a4356109f2565b34156103bf57600080fd5b6101df600160e860020a031960043516610adb565b34156103df57600080fd5b610182600160e860020a031960043516602435610b71565b341561040257600080fd5b610182600160a060020a0360043516610be1565b341561042157600080fd5b610147610c49565b341561043457600080fd5b610147610c5d565b341561044757600080fd5b610147610c6c565b341561045a57600080fd5b6101a9610c7b565b341561046d57600080fd5b610182610c84565b341561048057600080fd5b610182600160e860020a031960043516600160a060020a0360243516610cfe565b34156104ac57600080fd5b610147610f4f565b600a54600160a060020a031681565b60006104ce33610f5e565b806104dd57506104dd33610f72565b15156104e857600080fd5b600054600160a060020a038381169116141561050357600080fd5b30600160a060020a031682600160a060020a03161415151561052457600080fd5b61052d82610fa2565b1561053757600080fd5b60038054600160a060020a031916600160a060020a0384169081179091557f17bb0532ac84902a52bb6799529153f5ea501fc54fbcf3ea00dbd42bceb6b0f460405160405180910390a2506001919050565b6007546301000000900460ff1690565b600160e860020a03191660009081526005602052604090205490565b60006105c033610f5e565b806105cf57506105cf33610f72565b15156105da57600080fd5b600054600160a060020a03838116911614156105f557600080fd5b30600160a060020a031682600160a060020a03161415151561061657600080fd5b61061f82610f72565b1561062957600080fd5b60028054600160a060020a031916600160a060020a0384169081179091557fac46a4511b8366ae3b7cf3cf342e31556274975598dcae03c866f8f0f55d51c460405160405180910390a2506001919050565b600061068633610fa2565b151561069157600080fd5b600160e860020a03198216600090815260066020526040902054600160a060020a031615156106bf57600080fd5b600160e860020a03198216600081815260066020526040908190208054600160a060020a03191690557f8bee55d48a68222fe9f1ee5b03929f037c08911acfe96caa89dcfe3fc1e95358905160405180910390a2506001919050565b60085490565b600160e860020a031916600090815260066020526040902054600160a060020a031690565b600054600160a060020a031681565b600254600160a060020a031681565b6007547d0100000000000000000000000000000000000000000000000000000000000290565b60008080600160e860020a0319841615156107a457600080fd5b6107ad84610adb565b9250600083116107bc57600080fd5b6107c7838787610fcf565b909250905093509350939050565b6107de33610f72565b806107ed57506107ed33610fa2565b15156107f857600080fd5b33600160a060020a03167f066a905b79c0121afe61e3a44e0b14b6bc1ec16d854cdba09efdfc9b6aa9af8160405160405180910390a233600160a060020a0316ff5b600080600080600080600960019054906101000a9004600160a060020a0316600160a060020a031663aa1566453360006040516020015260405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b15156108af57600080fd5b6102c65a03f115156108c057600080fd5b5050506040518051905015156108d557600080fd5b600160a060020a03881615156108ea57600080fd5b6108f68e8e8e8e611052565b151561090157600080fd5b8c93508a9250889150600160e860020a03198a161561092e576109268a8a8f8e61109e565b909550935091505b61093a888886866110fb565b9050610949888f868f876111bb565b151561095457600080fd5b87600160a060020a03168c600160a060020a03168f600160a060020a03167f12889b9f6a87492224e4fd8e6dbdb4618b3f564708185c493b152215ee961f5d87878f88886040518086815260200185815260200184600160e860020a031916600160e860020a03191681526020018381526020018281526020019550505050505060405180910390a4919092019c909b509950505050505050505050565b600080600080610a048a8a8a8a611052565b1515610a0f57600080fd5b5087915085905083600160e860020a0319861615610a3b57610a3386868b8a61109e565b909450925090505b610a48338b858b866111bb565b1515610a5357600080fd5b7f51e16b543c5bb3c6005bcb22b4b577f1567710d0f828897168bf3f1e9ad36a3f8a848a858a8a87604051600160a060020a0397881681526020810196909652939095166040808601919091526060850192909252600160e860020a031916608084015260a083019390935260c082015260e001905180910390a15001979650505050505050565b600160e860020a03198116600090815260066020526040812054600160a060020a0316801515610b0a57600080fd5b80600160a060020a03166398d5fdca6000604051602001526040518163ffffffff1660e060020a028152600401602060405180830381600087803b1515610b5057600080fd5b6102c65a03f11515610b6157600080fd5b5050506040518051949350505050565b6000610b7c33610fa2565b1515610b8757600080fd5b600160e860020a03198316600081815260056020526040908190208490557f058ed7b764a1a386e76b3cbca5e1d213a98664cb17e47628ed1bb3047f5039929084905190815260200160405180910390a250600192915050565b6000610bec33610f5e565b1515610bf757600080fd5b60018054600160a060020a031916600160a060020a0384169081179091557f20f5afdf40bf7b43c89031a5d4369a30b159e512d164aa46124bcb706b4a1caf60405160405180910390a2506001919050565b6009546101009004600160a060020a031681565b600154600160a060020a031681565b600454600160a060020a031690565b60095460ff1690565b60015460009033600160a060020a03908116911614610ca257600080fd5b6001805460008054600160a060020a03808416600160a060020a031992831617928390559216909255167f624adc4c72536289dd9d5439ccdeccd8923cb9af95fb626b21935447c77b840760405160405180910390a250600190565b6000610d0933610fa2565b1515610d1457600080fd5b600160a060020a0382161515610d2957600080fd5b600160e860020a031983161515610d3f57600080fd5b6007547d01000000000000000000000000000000000000000000000000000000000002600160e860020a031916600160a060020a0383166392a85fde6000604051602001526040518163ffffffff1660e060020a028152600401602060405180830381600087803b1515610db257600080fd5b6102c65a03f11515610dc357600080fd5b50505060405180519050600160e860020a031916141515610de357600080fd5b600160e860020a03198316600160a060020a0383166382564bca6000604051602001526040518163ffffffff1660e060020a028152600401602060405180830381600087803b1515610e3457600080fd5b6102c65a03f11515610e4557600080fd5b50505060405180519050600160e860020a031916141515610e6557600080fd5b6007546301000000900460ff16600160a060020a03831663313ce5676000604051602001526040518163ffffffff1660e060020a028152600401602060405180830381600087803b1515610eb857600080fd5b6102c65a03f11515610ec957600080fd5b5050506040518051905060ff16141515610ee257600080fd5b600160e860020a03198316600081815260066020526040908190208054600160a060020a031916600160a060020a03861690811790915591907f7d3ca855476824d6b0058a0c46e19e7275ce11bbe83bb82418ecf3a94e09c0d1905160405180910390a350600192915050565b600354600160a060020a031681565b600054600160a060020a0390811691161490565b600354600090600160a060020a031615801590610f9c5750600354600160a060020a038381169116145b92915050565b600254600090600160a060020a031615801590610f9c575050600254600160a060020a0390811691161490565b60095460075460085460009283928392839283926110179260ff928316600a90810a9361100b936301000000900416900a63ffffffff6112fc16565b9063ffffffff61132716565b925061102d8861100b898663ffffffff6112fc16565b91506110438861100b888663ffffffff6112fc16565b91989197509095505050505050565b6000600160a060020a038516151561106957600080fd5b83151561107557600080fd5b600082111561109357600160a060020a038316151561109357600080fd5b506001949350505050565b6000806000806000806110b08a610adb565b9250600083116110bf57600080fd5b6110d289846110cd8d610599565b61133e565b15156110dd57600080fd5b6110e8838989610fcf565b939b909a50929850919650505050505050565b828282018181101561110b578091505b60008211156111b25761111c610c6c565b600a54600160a060020a03918216916323b872dd9116888560006040516020015260405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b151561118c57600080fd5b6102c65a03f1151561119d57600080fd5b5050506040518051905015156111b257600080fd5b50949350505050565b600454600090600160a060020a03166323b872dd878787856040516020015260405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b151561122957600080fd5b6102c65a03f1151561123a57600080fd5b50505060405180519050151561124f57600080fd5b600160a060020a038316156112f057600454600160a060020a03166323b872dd87858560006040516020015260405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b15156112ca57600080fd5b6102c65a03f115156112db57600080fd5b5050506040518051905015156112f057600080fd5b50600195945050505050565b6000828202831580611318575082848281151561131557fe5b04145b151561132057fe5b9392505050565b600080828481151561133557fe5b04949350505050565b6000600182851061135f578361135a868563ffffffff61138316565b111590505b801561137b57611375858463ffffffff61139516565b84111590505b949350505050565b60008282111561138f57fe5b50900390565b60008282018381101561132057fe00a165627a7a72305820d91d0d7bcc12cd5ae3a2f46639d16bba08ac43cb21bfbd184b777f11753929310029 \ No newline at end of file +60806040523480156200001157600080fd5b50604051608080620017ed833981016040908152815160208301519183015160609093015160008054600160a060020a03191633600160a060020a039081169190911790915591939184908490821615156200006c57600080fd5b7fffffff0000000000000000000000000000000000000000000000000000000000811615156200009b57600080fd5b60048054600160a060020a031916600160a060020a03848116919091178083556007805462ffffff19167d0100000000000000000000000000000000000000000000000000000000008604179055604080517f313ce5670000000000000000000000000000000000000000000000000000000081529051919092169263313ce567928082019260209290918290030181600087803b1580156200013d57600080fd5b505af115801562000152573d6000803e3d6000fd5b505050506040513d60208110156200016957600080fd5b50516007805460ff90921663010000000263ff00000019909216919091179055604080517f7ffdf53e0000000000000000000000000000000000000000000000000000000081529051600160a060020a03841691637ffdf53e9160048083019260209291908290030181600087803b158015620001e557600080fd5b505af1158015620001fa573d6000803e3d6000fd5b505050506040513d60208110156200021157600080fd5b5051600855604080517fe30ac6c30000000000000000000000000000000000000000000000000000000081529051600160a060020a0384169163e30ac6c39160048083019260209291908290030181600087803b1580156200027257600080fd5b505af115801562000287573d6000803e3d6000fd5b505050506040513d60208110156200029e57600080fd5b50516009805460ff191660ff9092169190911790555050600160a060020a0382161515620002cb57600080fd5b600160a060020a0381161515620002e157600080fd5b6009805461010060a860020a031916610100600160a060020a0394851602179055600a8054600160a060020a03191691909216179055506114c39050806200032a6000396000f30060806040526004361061012f5763ffffffff60e060020a60003504166310f6fa4781146101345780632c1e816d14610165578063313ce5671461019a5780634a9569c5146101c5578063707789c5146101f95780637307453a1461021a5780637ffdf53e1461023c57806383121455146102515780638da5cb5b146102735780638ea643761461028857806392a85fde1461029d578063a1543600146102cf578063a7f4377914610315578063ae20a9ae1461032c578063b2b802c81461038f578063bbd30f10146103cd578063bd90bc30146103ef578063c0b6f56114610414578063cabb62f014610435578063d153b60c1461044a578063d348050c1461045f578063e30ac6c314610474578063e71a781114610489578063f3443dd21461049e578063fc6f9468146104cc575b600080fd5b34801561014057600080fd5b506101496104e1565b60408051600160a060020a039092168252519081900360200190f35b34801561017157600080fd5b50610186600160a060020a03600435166104f0565b604080519115158252519081900360200190f35b3480156101a657600080fd5b506101af6105c0565b6040805160ff9092168252519081900360200190f35b3480156101d157600080fd5b506101e7600160e860020a0319600435166105d0565b60408051918252519081900360200190f35b34801561020557600080fd5b50610186600160a060020a03600435166105ec565b34801561022657600080fd5b50610186600160e860020a0319600435166106bc565b34801561024857600080fd5b506101e7610762565b34801561025d57600080fd5b50610149600160e860020a031960043516610768565b34801561027f57600080fd5b5061014961078d565b34801561029457600080fd5b5061014961079c565b3480156102a957600080fd5b506102b26107ab565b60408051600160e860020a03199092168252519081900360200190f35b3480156102db57600080fd5b506102f7600435602435600160e860020a0319604435166107d1565b60408051938452602084019290925282820152519081900360600190f35b34801561032157600080fd5b5061032a61081c565b005b34801561033857600080fd5b50610376600160a060020a036004358116906024359060443581169060643590600160e860020a0319608435169060a4359060c4351660e43561087f565b6040805192835260208301919091528051918290030190f35b34801561039b57600080fd5b506101e7600160a060020a036004358116906024359060443516606435600160e860020a03196084351660a435610a4c565b3480156103d957600080fd5b506101e7600160e860020a031960043516610b29565b3480156103fb57600080fd5b50610186600160e860020a031960043516602435610bc9565b34801561042057600080fd5b50610186600160a060020a0360043516610c39565b34801561044157600080fd5b50610149610cab565b34801561045657600080fd5b50610149610cbf565b34801561046b57600080fd5b50610149610cce565b34801561048057600080fd5b506101af610cdd565b34801561049557600080fd5b50610186610ce6565b3480156104aa57600080fd5b50610186600160e860020a031960043516600160a060020a0360243516610d6d565b3480156104d857600080fd5b50610149610fea565b600a54600160a060020a031681565b60006104fb33610ff9565b8061050a575061050a3361100d565b151561051557600080fd5b600054600160a060020a038381169116141561053057600080fd5b30600160a060020a031682600160a060020a03161415151561055157600080fd5b61055a8261103d565b1561056457600080fd5b6003805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091556040517f17bb0532ac84902a52bb6799529153f5ea501fc54fbcf3ea00dbd42bceb6b0f490600090a2506001919050565b6007546301000000900460ff1690565b600160e860020a03191660009081526005602052604090205490565b60006105f733610ff9565b8061060657506106063361100d565b151561061157600080fd5b600054600160a060020a038381169116141561062c57600080fd5b30600160a060020a031682600160a060020a03161415151561064d57600080fd5b6106568261100d565b1561066057600080fd5b6002805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091556040517fac46a4511b8366ae3b7cf3cf342e31556274975598dcae03c866f8f0f55d51c490600090a2506001919050565b60006106c73361103d565b15156106d257600080fd5b600160e860020a03198216600090815260066020526040902054600160a060020a0316151561070057600080fd5b600160e860020a03198216600081815260066020526040808220805473ffffffffffffffffffffffffffffffffffffffff19169055517f8bee55d48a68222fe9f1ee5b03929f037c08911acfe96caa89dcfe3fc1e953589190a2506001919050565b60085490565b600160e860020a031916600090815260066020526040902054600160a060020a031690565b600054600160a060020a031681565b600254600160a060020a031681565b6007547d0100000000000000000000000000000000000000000000000000000000000290565b60008080600160e860020a0319841615156107eb57600080fd5b6107f484610b29565b92506000831161080357600080fd5b61080e83878761106a565b909250905093509350939050565b6108253361100d565b8061083457506108343361103d565b151561083f57600080fd5b604051600160a060020a033316907f066a905b79c0121afe61e3a44e0b14b6bc1ec16d854cdba09efdfc9b6aa9af8190600090a233600160a060020a0316ff5b600080600080600080600960019054906101000a9004600160a060020a0316600160a060020a031663aa156645336040518263ffffffff1660e060020a0281526004018082600160a060020a0316600160a060020a03168152602001915050602060405180830381600087803b1580156108f857600080fd5b505af115801561090c573d6000803e3d6000fd5b505050506040513d602081101561092257600080fd5b5051151561092f57600080fd5b600160a060020a038816151561094457600080fd5b6109508e8e8e8e6110ed565b151561095b57600080fd5b8c93508a9250889150600160e860020a03198a1615610988576109808a8a8f8e611139565b909550935091505b61099488888686611196565b90506109a3888f868f8761126f565b15156109ae57600080fd5b87600160a060020a03168c600160a060020a03168f600160a060020a03167f12889b9f6a87492224e4fd8e6dbdb4618b3f564708185c493b152215ee961f5d87878f88886040518086815260200185815260200184600160e860020a031916600160e860020a03191681526020018381526020018281526020019550505050505060405180910390a4919092019c909b509950505050505050505050565b600080600080610a5e8a8a8a8a6110ed565b1515610a6957600080fd5b5087915085905083600160e860020a0319861615610a9557610a8d86868b8a611139565b909450925090505b610aa2338b858b8661126f565b1515610aad57600080fd5b60408051600160a060020a03808d168252602082018690528a168183015260608101849052600160e860020a03198816608082015260a0810187905260c0810183905290517f51e16b543c5bb3c6005bcb22b4b577f1567710d0f828897168bf3f1e9ad36a3f9181900360e00190a15001979650505050505050565b600160e860020a03198116600090815260066020526040812054600160a060020a0316801515610b5857600080fd5b80600160a060020a03166398d5fdca6040518163ffffffff1660e060020a028152600401602060405180830381600087803b158015610b9657600080fd5b505af1158015610baa573d6000803e3d6000fd5b505050506040513d6020811015610bc057600080fd5b50519392505050565b6000610bd43361103d565b1515610bdf57600080fd5b600160e860020a03198316600081815260056020908152604091829020859055815185815291517f058ed7b764a1a386e76b3cbca5e1d213a98664cb17e47628ed1bb3047f5039929281900390910190a250600192915050565b6000610c4433610ff9565b1515610c4f57600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091556040517f20f5afdf40bf7b43c89031a5d4369a30b159e512d164aa46124bcb706b4a1caf90600090a2506001919050565b6009546101009004600160a060020a031681565b600154600160a060020a031681565b600454600160a060020a031690565b60095460ff1690565b60015460009033600160a060020a03908116911614610d0457600080fd5b6001805460008054600160a060020a0380841673ffffffffffffffffffffffffffffffffffffffff19928316178084559190931690935560405192909116917f624adc4c72536289dd9d5439ccdeccd8923cb9af95fb626b21935447c77b84079190a250600190565b6000610d783361103d565b1515610d8357600080fd5b600160a060020a0382161515610d9857600080fd5b600160e860020a031983161515610dae57600080fd5b600760009054906101000a90047d01000000000000000000000000000000000000000000000000000000000002600160e860020a03191682600160a060020a03166392a85fde6040518163ffffffff1660e060020a028152600401602060405180830381600087803b158015610e2357600080fd5b505af1158015610e37573d6000803e3d6000fd5b505050506040513d6020811015610e4d57600080fd5b5051600160e860020a03191614610e6357600080fd5b82600160e860020a03191682600160a060020a03166382564bca6040518163ffffffff1660e060020a028152600401602060405180830381600087803b158015610eac57600080fd5b505af1158015610ec0573d6000803e3d6000fd5b505050506040513d6020811015610ed657600080fd5b5051600160e860020a03191614610eec57600080fd5b600760039054906101000a900460ff1660ff1682600160a060020a031663313ce5676040518163ffffffff1660e060020a028152600401602060405180830381600087803b158015610f3d57600080fd5b505af1158015610f51573d6000803e3d6000fd5b505050506040513d6020811015610f6757600080fd5b505160ff1614610f7657600080fd5b600160e860020a03198316600081815260066020526040808220805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a03871690811790915590519092917f7d3ca855476824d6b0058a0c46e19e7275ce11bbe83bb82418ecf3a94e09c0d191a350600192915050565b600354600160a060020a031681565b600054600160a060020a0390811691161490565b600354600090600160a060020a0316158015906110375750600354600160a060020a038381169116145b92915050565b600254600090600160a060020a031615801590611037575050600254600160a060020a0390811691161490565b60095460075460085460009283928392839283926110b29260ff928316600a90810a936110a6936301000000900416900a63ffffffff6113ef16565b9063ffffffff61141a16565b92506110c8886110a6898663ffffffff6113ef16565b91506110de886110a6888663ffffffff6113ef16565b91989197509095505050505050565b6000600160a060020a038516151561110457600080fd5b83151561111057600080fd5b600082111561112e57600160a060020a038316151561112e57600080fd5b506001949350505050565b60008060008060008061114b8a610b29565b92506000831161115a57600080fd5b61116d89846111688d6105d0565b611431565b151561117857600080fd5b61118383898961106a565b939b909a50929850919650505050505050565b82828201818110156111a6578091505b6000821115611266576111b7610cce565b600a54604080517f23b872dd000000000000000000000000000000000000000000000000000000008152600160a060020a039283166004820152898316602482015260448101869052905192909116916323b872dd916064808201926020929091908290030181600087803b15801561122f57600080fd5b505af1158015611243573d6000803e3d6000fd5b505050506040513d602081101561125957600080fd5b5051151561126657600080fd5b50949350505050565b60048054604080517f23b872dd000000000000000000000000000000000000000000000000000000008152600160a060020a03898116948201949094528784166024820152604481018790529051600093909216916323b872dd9160648082019260209290919082900301818787803b1580156112eb57600080fd5b505af11580156112ff573d6000803e3d6000fd5b505050506040513d602081101561131557600080fd5b5051151561132257600080fd5b600160a060020a038316156113e35760048054604080517f23b872dd000000000000000000000000000000000000000000000000000000008152600160a060020a038a811694820194909452868416602482015260448101869052905192909116916323b872dd916064808201926020929091908290030181600087803b1580156113ac57600080fd5b505af11580156113c0573d6000803e3d6000fd5b505050506040513d60208110156113d657600080fd5b505115156113e357600080fd5b50600195945050505050565b600082820283158061140b575082848281151561140857fe5b04145b151561141357fe5b9392505050565b600080828481151561142857fe5b04949350505050565b60006001828510611452578361144d868563ffffffff61147616565b111590505b801561146e57611468858463ffffffff61148816565b84111590505b949350505050565b60008282111561148257fe5b50900390565b60008282018381101561141357fe00a165627a7a72305820422b0e880a6661db9497e450a919860034ca79006efb5256c9c0e4cd548f66f50029 \ No newline at end of file diff --git a/contracts/bin/EIP20TokenMock.bin b/contracts/bin/EIP20TokenMock.bin index 5f295ae..7707622 100644 --- a/contracts/bin/EIP20TokenMock.bin +++ b/contracts/bin/EIP20TokenMock.bin @@ -1 +1 @@ -6060604052341561000f57600080fd5b60405161087238038061087283398101604052808051919060200180519190602001805182019190602001805182019190602001805191508390508282600183805161005f9291602001906100a8565b5060008280516100739291602001906100a8565b506002805460ff1990811660ff9384161790915560059890985560068054909816961695909517909555506101439350505050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106100e957805160ff1916838001178555610116565b82800160010185558215610116579182015b828111156101165782518255916020019190600101906100fb565b50610122929150610126565b5090565b61014091905b80821115610122576000815560010161012c565b90565b610720806101526000396000f3006060604052600436106100c45763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166306fdde0381146100c9578063095ea7b31461015357806318160ddd1461018957806323b872dd146101ae578063313ce567146101d657806357f3c897146101ff57806370a08231146102155780637ffdf53e1461023457806395d89b4114610247578063a9059cbb1461025a578063dd62ed3e1461027c578063e30443bc146102a1578063e30ac6c3146102c3575b600080fd5b34156100d457600080fd5b6100dc6102d6565b60405160208082528190810183818151815260200191508051906020019080838360005b83811015610118578082015183820152602001610100565b50505050905090810190601f1680156101455780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b341561015e57600080fd5b610175600160a060020a036004351660243561037e565b604051901515815260200160405180910390f35b341561019457600080fd5b61019c6103ea565b60405190815260200160405180910390f35b34156101b957600080fd5b610175600160a060020a03600435811690602435166044356103ef565b34156101e157600080fd5b6101e9610502565b60405160ff909116815260200160405180910390f35b341561020a57600080fd5b61017560043561050b565b341561022057600080fd5b61019c600160a060020a0360043516610513565b341561023f57600080fd5b61019c61052e565b341561025257600080fd5b6100dc610534565b341561026557600080fd5b610175600160a060020a03600435166024356105a7565b341561028757600080fd5b61019c600160a060020a0360043581169060243516610666565b34156102ac57600080fd5b610175600160a060020a0360043516602435610691565b34156102ce57600080fd5b6101e96106b1565b6102de6106e2565b60008054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156103745780601f1061034957610100808354040283529160200191610374565b820191906000526020600020905b81548152906001019060200180831161035757829003601f168201915b5050505050905090565b600160a060020a03338116600081815260046020908152604080832094871680845294909152808220859055909291907f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259085905190815260200160405180910390a350600192915050565b600090565b600160a060020a038316600090815260036020526040812054610418908363ffffffff6106ba16565b600160a060020a038086166000908152600360209081526040808320949094556004815283822033909316825291909152205461045b908363ffffffff6106ba16565b600160a060020a03808616600090815260046020908152604080832033851684528252808320949094559186168152600390915220546104a1908363ffffffff6106cc16565b600160a060020a03808516600081815260036020526040908190209390935591908616907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9085905190815260200160405180910390a35060019392505050565b60025460ff1690565b600555600190565b600160a060020a031660009081526003602052604090205490565b60055481565b61053c6106e2565b60018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156103745780601f1061034957610100808354040283529160200191610374565b600160a060020a0333166000908152600360205260408120546105d0908363ffffffff6106ba16565b600160a060020a033381166000908152600360205260408082209390935590851681522054610605908363ffffffff6106cc16565b600160a060020a0380851660008181526003602052604090819020939093559133909116907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9085905190815260200160405180910390a350600192915050565b600160a060020a03918216600090815260046020908152604080832093909416825291909152205490565b600160a060020a0391909116600090815260036020526040902055600190565b60065460ff1681565b6000828211156106c657fe5b50900390565b6000828201838110156106db57fe5b9392505050565b602060405190810160405260008152905600a165627a7a7230582088922e978e2d48cc83406fb5b017b2abe997b67c5e3228bbd9199d2da21ae55a0029 \ No newline at end of file +608060405234801561001057600080fd5b506040516108503803806108508339810160409081528151602080840151928401516060850151608086015191860180519496909491019284918491849161005e91600191908601906100a7565b5081516100729060009060208501906100a7565b506002805460ff1990811660ff9384161790915560059890985560068054909816961695909517909555506101429350505050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106100e857805160ff1916838001178555610115565b82800160010185558215610115579182015b828111156101155782518255916020019190600101906100fa565b50610121929150610125565b5090565b61013f91905b80821115610121576000815560010161012b565b90565b6106ff806101516000396000f3006080604052600436106100c45763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166306fdde0381146100c9578063095ea7b31461015357806318160ddd1461018b57806323b872dd146101b2578063313ce567146101dc57806357f3c8971461020757806370a082311461021f5780637ffdf53e1461024057806395d89b4114610255578063a9059cbb1461026a578063dd62ed3e1461028e578063e30443bc146102b5578063e30ac6c3146102d9575b600080fd5b3480156100d557600080fd5b506100de6102ee565b6040805160208082528351818301528351919283929083019185019080838360005b83811015610118578181015183820152602001610100565b50505050905090810190601f1680156101455780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561015f57600080fd5b50610177600160a060020a0360043516602435610384565b604080519115158252519081900360200190f35b34801561019757600080fd5b506101a06103ee565b60408051918252519081900360200190f35b3480156101be57600080fd5b50610177600160a060020a03600435811690602435166044356103f3565b3480156101e857600080fd5b506101f1610506565b6040805160ff9092168252519081900360200190f35b34801561021357600080fd5b5061017760043561050f565b34801561022b57600080fd5b506101a0600160a060020a0360043516610517565b34801561024c57600080fd5b506101a0610532565b34801561026157600080fd5b506100de610538565b34801561027657600080fd5b50610177600160a060020a0360043516602435610598565b34801561029a57600080fd5b506101a0600160a060020a0360043581169060243516610657565b3480156102c157600080fd5b50610177600160a060020a0360043516602435610682565b3480156102e557600080fd5b506101f16106a2565b60008054604080516020601f600260001961010060018816150201909516949094049384018190048102820181019092528281526060939092909183018282801561037a5780601f1061034f5761010080835404028352916020019161037a565b820191906000526020600020905b81548152906001019060200180831161035d57829003601f168201915b5050505050905090565b600160a060020a03338116600081815260046020908152604080832094871680845294825280832086905580518681529051929493927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925929181900390910190a350600192915050565b600090565b600160a060020a03831660009081526003602052604081205461041c908363ffffffff6106ab16565b600160a060020a038086166000908152600360209081526040808320949094556004815283822033909316825291909152205461045f908363ffffffff6106ab16565b600160a060020a03808616600090815260046020908152604080832033851684528252808320949094559186168152600390915220546104a5908363ffffffff6106bd16565b600160a060020a0380851660008181526003602090815260409182902094909455805186815290519193928816927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef92918290030190a35060019392505050565b60025460ff1690565b600555600190565b600160a060020a031660009081526003602052604090205490565b60055481565b60018054604080516020601f6002600019610100878916150201909516949094049384018190048102820181019092528281526060939092909183018282801561037a5780601f1061034f5761010080835404028352916020019161037a565b600160a060020a0333166000908152600360205260408120546105c1908363ffffffff6106ab16565b600160a060020a0333811660009081526003602052604080822093909355908516815220546105f6908363ffffffff6106bd16565b600160a060020a038085166000818152600360209081526040918290209490945580518681529051919333909316927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef92918290030190a350600192915050565b600160a060020a03918216600090815260046020908152604080832093909416825291909152205490565b600160a060020a0391909116600090815260036020526040902055600190565b60065460ff1681565b6000828211156106b757fe5b50900390565b6000828201838110156106cc57fe5b93925050505600a165627a7a72305820e7bd40ebd246a69787db0f60ea611d6732d82010b099f409b4ab62d90e32e4970029 \ No newline at end of file diff --git a/contracts/bin/OpsManaged.bin b/contracts/bin/OpsManaged.bin index a86c127..b6df26c 100644 --- a/contracts/bin/OpsManaged.bin +++ b/contracts/bin/OpsManaged.bin @@ -1 +1 @@ -6060604052341561000f57600080fd5b60008054600160a060020a033316600160a060020a03199091161790556104f98061003b6000396000f30060606040526004361061008d5763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416632c1e816d8114610092578063707789c5146100c55780638da5cb5b146100e45780638ea6437614610113578063c0b6f56114610126578063d153b60c14610145578063e71a781114610158578063fc6f94681461016b575b600080fd5b341561009d57600080fd5b6100b1600160a060020a036004351661017e565b604051901515815260200160405180910390f35b34156100d057600080fd5b6100b1600160a060020a0360043516610251565b34156100ef57600080fd5b6100f7610324565b604051600160a060020a03909116815260200160405180910390f35b341561011e57600080fd5b6100f7610333565b341561013157600080fd5b6100b1600160a060020a0360043516610342565b341561015057600080fd5b6100f76103b7565b341561016357600080fd5b6100b16103c6565b341561017657600080fd5b6100f761044d565b60006101893361045c565b80610198575061019833610470565b15156101a357600080fd5b600054600160a060020a03838116911614156101be57600080fd5b30600160a060020a031682600160a060020a0316141515156101df57600080fd5b6101e8826104a0565b156101f257600080fd5b6003805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091557f17bb0532ac84902a52bb6799529153f5ea501fc54fbcf3ea00dbd42bceb6b0f460405160405180910390a2506001919050565b600061025c3361045c565b8061026b575061026b33610470565b151561027657600080fd5b600054600160a060020a038381169116141561029157600080fd5b30600160a060020a031682600160a060020a0316141515156102b257600080fd5b6102bb82610470565b156102c557600080fd5b6002805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091557fac46a4511b8366ae3b7cf3cf342e31556274975598dcae03c866f8f0f55d51c460405160405180910390a2506001919050565b600054600160a060020a031681565b600254600160a060020a031681565b600061034d3361045c565b151561035857600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091557f20f5afdf40bf7b43c89031a5d4369a30b159e512d164aa46124bcb706b4a1caf60405160405180910390a2506001919050565b600154600160a060020a031681565b60015460009033600160a060020a039081169116146103e457600080fd5b6001805460008054600160a060020a0380841673ffffffffffffffffffffffffffffffffffffffff1992831617928390559216909255167f624adc4c72536289dd9d5439ccdeccd8923cb9af95fb626b21935447c77b840760405160405180910390a250600190565b600354600160a060020a031681565b600054600160a060020a0390811691161490565b600354600090600160a060020a03161580159061049a5750600354600160a060020a038381169116145b92915050565b600254600090600160a060020a03161580159061049a575050600254600160a060020a03908116911614905600a165627a7a72305820db78c58fbc24d7d5ce92d363dc0f27463368a0d637d625340e33f531fc7369f80029 \ No newline at end of file +608060405234801561001057600080fd5b5060008054600160a060020a033316600160a060020a03199091161790556105008061003d6000396000f30060806040526004361061008d5763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416632c1e816d8114610092578063707789c5146100c75780638da5cb5b146100e85780638ea6437614610119578063c0b6f5611461012e578063d153b60c1461014f578063e71a781114610164578063fc6f946814610179575b600080fd5b34801561009e57600080fd5b506100b3600160a060020a036004351661018e565b604080519115158252519081900360200190f35b3480156100d357600080fd5b506100b3600160a060020a036004351661025e565b3480156100f457600080fd5b506100fd61032e565b60408051600160a060020a039092168252519081900360200190f35b34801561012557600080fd5b506100fd61033d565b34801561013a57600080fd5b506100b3600160a060020a036004351661034c565b34801561015b57600080fd5b506100fd6103be565b34801561017057600080fd5b506100b36103cd565b34801561018557600080fd5b506100fd610454565b600061019933610463565b806101a857506101a833610477565b15156101b357600080fd5b600054600160a060020a03838116911614156101ce57600080fd5b30600160a060020a031682600160a060020a0316141515156101ef57600080fd5b6101f8826104a7565b1561020257600080fd5b6003805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091556040517f17bb0532ac84902a52bb6799529153f5ea501fc54fbcf3ea00dbd42bceb6b0f490600090a2506001919050565b600061026933610463565b80610278575061027833610477565b151561028357600080fd5b600054600160a060020a038381169116141561029e57600080fd5b30600160a060020a031682600160a060020a0316141515156102bf57600080fd5b6102c882610477565b156102d257600080fd5b6002805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091556040517fac46a4511b8366ae3b7cf3cf342e31556274975598dcae03c866f8f0f55d51c490600090a2506001919050565b600054600160a060020a031681565b600254600160a060020a031681565b600061035733610463565b151561036257600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091556040517f20f5afdf40bf7b43c89031a5d4369a30b159e512d164aa46124bcb706b4a1caf90600090a2506001919050565b600154600160a060020a031681565b60015460009033600160a060020a039081169116146103eb57600080fd5b6001805460008054600160a060020a0380841673ffffffffffffffffffffffffffffffffffffffff19928316178084559190931690935560405192909116917f624adc4c72536289dd9d5439ccdeccd8923cb9af95fb626b21935447c77b84079190a250600190565b600354600160a060020a031681565b600054600160a060020a0390811691161490565b600354600090600160a060020a0316158015906104a15750600354600160a060020a038381169116145b92915050565b600254600090600160a060020a0316158015906104a1575050600254600160a060020a03908116911614905600a165627a7a723058208eee66f60cfe198ac1e1b9817295d106448bb086506065bb67fbed1123b05d110029 \ No newline at end of file diff --git a/contracts/bin/Owned.bin b/contracts/bin/Owned.bin index ce90cdc..576b26e 100644 --- a/contracts/bin/Owned.bin +++ b/contracts/bin/Owned.bin @@ -1 +1 @@ -6060604052341561000f57600080fd5b60008054600160a060020a033316600160a060020a03199091161790556102488061003b6000396000f3006060604052600436106100615763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416638da5cb5b8114610066578063c0b6f56114610095578063d153b60c146100c8578063e71a7811146100db575b600080fd5b341561007157600080fd5b6100796100ee565b604051600160a060020a03909116815260200160405180910390f35b34156100a057600080fd5b6100b4600160a060020a03600435166100fd565b604051901515815260200160405180910390f35b34156100d357600080fd5b610079610172565b34156100e657600080fd5b6100b4610181565b600054600160a060020a031681565b600061010833610208565b151561011357600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091557f20f5afdf40bf7b43c89031a5d4369a30b159e512d164aa46124bcb706b4a1caf60405160405180910390a2506001919050565b600154600160a060020a031681565b60015460009033600160a060020a0390811691161461019f57600080fd5b6001805460008054600160a060020a0380841673ffffffffffffffffffffffffffffffffffffffff1992831617928390559216909255167f624adc4c72536289dd9d5439ccdeccd8923cb9af95fb626b21935447c77b840760405160405180910390a250600190565b600054600160a060020a03908116911614905600a165627a7a723058201a0a22a6378f09b622dbcefc82d8df515a129157b8b9aa89341043acfce5b47b0029 \ No newline at end of file +608060405234801561001057600080fd5b5060008054600160a060020a033316600160a060020a031990911617905561024d8061003d6000396000f3006080604052600436106100615763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416638da5cb5b8114610066578063c0b6f56114610097578063d153b60c146100cc578063e71a7811146100e1575b600080fd5b34801561007257600080fd5b5061007b6100f6565b60408051600160a060020a039092168252519081900360200190f35b3480156100a357600080fd5b506100b8600160a060020a0360043516610105565b604080519115158252519081900360200190f35b3480156100d857600080fd5b5061007b610177565b3480156100ed57600080fd5b506100b8610186565b600054600160a060020a031681565b60006101103361020d565b151561011b57600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091556040517f20f5afdf40bf7b43c89031a5d4369a30b159e512d164aa46124bcb706b4a1caf90600090a2506001919050565b600154600160a060020a031681565b60015460009033600160a060020a039081169116146101a457600080fd5b6001805460008054600160a060020a0380841673ffffffffffffffffffffffffffffffffffffffff19928316178084559190931690935560405192909116917f624adc4c72536289dd9d5439ccdeccd8923cb9af95fb626b21935447c77b84079190a250600190565b600054600160a060020a03908116911614905600a165627a7a72305820d77c51e6d8aac50bde1dc8c1f8eaed0cb054ab9cbb968c8344a571c9cfb506180029 \ No newline at end of file diff --git a/contracts/bin/PriceOracleMock.bin b/contracts/bin/PriceOracleMock.bin index d04730b..89a120d 100644 --- a/contracts/bin/PriceOracleMock.bin +++ b/contracts/bin/PriceOracleMock.bin @@ -1 +1 @@ -6060604052341561000f57600080fd5b6040516060806102568339810160405280805191906020018051919060200180516001805465ffffff000000191663010000007d01000000000000000000000000000000000000000000000000000000000096879004021762ffffff191694909504939093179093555060009081556101c79150819061008f90396000f3006060604052600436106100775763ffffffff7c0100000000000000000000000000000000000000000000000000000000600035041663313ce567811461007c578063562e5801146100a557806382564bca146100ca57806392a85fde1461011257806398d5fdca14610125578063a05e7d09146100a5575b600080fd5b341561008757600080fd5b61008f610138565b60405160ff909116815260200160405180910390f35b34156100b057600080fd5b6100b861013d565b60405190815260200160405180910390f35b34156100d557600080fd5b6100dd610142565b6040517fffffff0000000000000000000000000000000000000000000000000000000000909116815260200160405180910390f35b341561011d57600080fd5b6100dd61016f565b341561013057600080fd5b6100b8610195565b601290565b600090565b600154630100000090047d0100000000000000000000000000000000000000000000000000000000000290565b6001547d0100000000000000000000000000000000000000000000000000000000000290565b600054905600a165627a7a72305820f2eccfcf926fe58082f7a87ded8523fda9550ebb37f19e58e897639c488b73aa0029 \ No newline at end of file +608060405234801561001057600080fd5b5060405160608061025d8339810160409081528151602083015191909201516001805465ffffff000000191663010000007d01000000000000000000000000000000000000000000000000000000000094859004021762ffffff1916929093049190911790915560009081556101d190819061008c90396000f3006080604052600436106100775763ffffffff7c0100000000000000000000000000000000000000000000000000000000600035041663313ce567811461007c578063562e5801146100a757806382564bca146100ce57806392a85fde1461011857806398d5fdca1461012d578063a05e7d09146100a7575b600080fd5b34801561008857600080fd5b50610091610142565b6040805160ff9092168252519081900360200190f35b3480156100b357600080fd5b506100bc610147565b60408051918252519081900360200190f35b3480156100da57600080fd5b506100e361014c565b604080517fffffff00000000000000000000000000000000000000000000000000000000009092168252519081900360200190f35b34801561012457600080fd5b506100e3610179565b34801561013957600080fd5b506100bc61019f565b601290565b600090565b600154630100000090047d0100000000000000000000000000000000000000000000000000000000000290565b6001547d0100000000000000000000000000000000000000000000000000000000000290565b600054905600a165627a7a7230582078799a045b6b4b51424e6349f566d70d3c128ab5fab5ed92edf9ee6d41c17a980029 \ No newline at end of file diff --git a/contracts/bin/Pricer.bin b/contracts/bin/Pricer.bin index 72f8119..02816ae 100644 --- a/contracts/bin/Pricer.bin +++ b/contracts/bin/Pricer.bin @@ -1 +1 @@ -6060604052341561000f57600080fd5b60405160408061133c833981016040528080519190602001805160008054600160a060020a03191633600160a060020a039081169190911790915590925083161515905061005c57600080fd5b7fffffff00000000000000000000000000000000000000000000000000000000008116151561008a57600080fd5b60048054600160a060020a031916600160a060020a0384811691909117918290556007805462ffffff19167d01000000000000000000000000000000000000000000000000000000000085041790551663313ce5676000604051602001526040518163ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401602060405180830381600087803b151561012f57600080fd5b6102c65a03f1151561014057600080fd5b50505060405180516007805460ff90921663010000000263ff0000001990921691909117905550600160a060020a038216637ffdf53e6000604051602001526040518163ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401602060405180830381600087803b15156101c657600080fd5b6102c65a03f115156101d757600080fd5b505050604051805160085550600160a060020a03821663e30ac6c36000604051602001526040518163ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401602060405180830381600087803b151561024257600080fd5b6102c65a03f1151561025357600080fd5b50505060405180516009805460ff90921660ff199092169190911790555050506110ba806102826000396000f30060606040526004361061010e5763ffffffff60e060020a6000350416632c1e816d8114610113578063313ce567146101465780634a9569c51461016f578063707789c5146101a15780637307453a146101c05780637ffdf53e146101e057806383121455146101f35780638da5cb5b1461022f5780638ea643761461024257806392a85fde14610255578063a154360014610285578063a7f43779146102cf578063b2b802c8146102e4578063bbd30f1014610320578063bd90bc3014610340578063c0b6f56114610363578063d153b60c14610382578063d348050c14610395578063e30ac6c3146103a8578063e71a7811146103bb578063f3443dd2146103ce578063fc6f9468146103fa575b600080fd5b341561011e57600080fd5b610132600160a060020a036004351661040d565b604051901515815260200160405180910390f35b341561015157600080fd5b6101596104d3565b60405160ff909116815260200160405180910390f35b341561017a57600080fd5b61018f600160e860020a0319600435166104e3565b60405190815260200160405180910390f35b34156101ac57600080fd5b610132600160a060020a03600435166104ff565b34156101cb57600080fd5b610132600160e860020a0319600435166105c5565b34156101eb57600080fd5b61018f610665565b34156101fe57600080fd5b610213600160e860020a03196004351661066b565b604051600160a060020a03909116815260200160405180910390f35b341561023a57600080fd5b610213610690565b341561024d57600080fd5b61021361069f565b341561026057600080fd5b6102686106ae565b604051600160e860020a0319909116815260200160405180910390f35b341561029057600080fd5b6102ab600435602435600160e860020a0319604435166106d4565b60405180848152602001838152602001828152602001935050505060405180910390f35b34156102da57600080fd5b6102e261071f565b005b34156102ef57600080fd5b61018f600160a060020a036004358116906024359060443516606435600160e860020a03196084351660a435610784565b341561032b57600080fd5b61018f600160e860020a03196004351661086d565b341561034b57600080fd5b610132600160e860020a031960043516602435610903565b341561036e57600080fd5b610132600160a060020a0360043516610973565b341561038d57600080fd5b6102136109db565b34156103a057600080fd5b6102136109ea565b34156103b357600080fd5b6101596109f9565b34156103c657600080fd5b610132610a02565b34156103d957600080fd5b610132600160e860020a031960043516600160a060020a0360243516610a7c565b341561040557600080fd5b610213610cf9565b600061041833610d08565b80610427575061042733610d1c565b151561043257600080fd5b600054600160a060020a038381169116141561044d57600080fd5b30600160a060020a031682600160a060020a03161415151561046e57600080fd5b61047782610d4c565b1561048157600080fd5b60038054600160a060020a031916600160a060020a0384169081179091557f17bb0532ac84902a52bb6799529153f5ea501fc54fbcf3ea00dbd42bceb6b0f460405160405180910390a2506001919050565b6007546301000000900460ff1690565b600160e860020a03191660009081526005602052604090205490565b600061050a33610d08565b80610519575061051933610d1c565b151561052457600080fd5b600054600160a060020a038381169116141561053f57600080fd5b30600160a060020a031682600160a060020a03161415151561056057600080fd5b61056982610d1c565b1561057357600080fd5b60028054600160a060020a031916600160a060020a0384169081179091557fac46a4511b8366ae3b7cf3cf342e31556274975598dcae03c866f8f0f55d51c460405160405180910390a2506001919050565b60006105d033610d4c565b15156105db57600080fd5b600160e860020a03198216600090815260066020526040902054600160a060020a0316151561060957600080fd5b600160e860020a03198216600081815260066020526040908190208054600160a060020a03191690557f8bee55d48a68222fe9f1ee5b03929f037c08911acfe96caa89dcfe3fc1e95358905160405180910390a2506001919050565b60085490565b600160e860020a031916600090815260066020526040902054600160a060020a031690565b600054600160a060020a031681565b600254600160a060020a031681565b6007547d0100000000000000000000000000000000000000000000000000000000000290565b60008080600160e860020a0319841615156106ee57600080fd5b6106f78461086d565b92506000831161070657600080fd5b610711838787610d79565b909250905093509350939050565b61072833610d1c565b80610737575061073733610d4c565b151561074257600080fd5b33600160a060020a03167f066a905b79c0121afe61e3a44e0b14b6bc1ec16d854cdba09efdfc9b6aa9af8160405160405180910390a233600160a060020a0316ff5b6000806000806107968a8a8a8a610dfc565b15156107a157600080fd5b5087915085905083600160e860020a03198616156107cd576107c586868b8a610e48565b909450925090505b6107da338b858b86610ea5565b15156107e557600080fd5b7f51e16b543c5bb3c6005bcb22b4b577f1567710d0f828897168bf3f1e9ad36a3f8a848a858a8a87604051600160a060020a0397881681526020810196909652939095166040808601919091526060850192909252600160e860020a031916608084015260a083019390935260c082015260e001905180910390a15001979650505050505050565b600160e860020a03198116600090815260066020526040812054600160a060020a031680151561089c57600080fd5b80600160a060020a03166398d5fdca6000604051602001526040518163ffffffff1660e060020a028152600401602060405180830381600087803b15156108e257600080fd5b6102c65a03f115156108f357600080fd5b5050506040518051949350505050565b600061090e33610d4c565b151561091957600080fd5b600160e860020a03198316600081815260056020526040908190208490557f058ed7b764a1a386e76b3cbca5e1d213a98664cb17e47628ed1bb3047f5039929084905190815260200160405180910390a250600192915050565b600061097e33610d08565b151561098957600080fd5b60018054600160a060020a031916600160a060020a0384169081179091557f20f5afdf40bf7b43c89031a5d4369a30b159e512d164aa46124bcb706b4a1caf60405160405180910390a2506001919050565b600154600160a060020a031681565b600454600160a060020a031690565b60095460ff1690565b60015460009033600160a060020a03908116911614610a2057600080fd5b6001805460008054600160a060020a03808416600160a060020a031992831617928390559216909255167f624adc4c72536289dd9d5439ccdeccd8923cb9af95fb626b21935447c77b840760405160405180910390a250600190565b6000610a8733610d4c565b1515610a9257600080fd5b600160a060020a0382161515610aa757600080fd5b600160e860020a031983161515610abd57600080fd5b6007547d01000000000000000000000000000000000000000000000000000000000002600160e860020a031916600160a060020a0383166392a85fde6000604051602001526040518163ffffffff1660e060020a028152600401602060405180830381600087803b1515610b3057600080fd5b6102c65a03f11515610b4157600080fd5b505050604051805190507cffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916141515610b7757600080fd5b600160e860020a03198316600160a060020a0383166382564bca6000604051602001526040518163ffffffff1660e060020a028152600401602060405180830381600087803b1515610bc857600080fd5b6102c65a03f11515610bd957600080fd5b505050604051805190507cffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916141515610c0f57600080fd5b6007546301000000900460ff16600160a060020a03831663313ce5676000604051602001526040518163ffffffff1660e060020a028152600401602060405180830381600087803b1515610c6257600080fd5b6102c65a03f11515610c7357600080fd5b5050506040518051905060ff16141515610c8c57600080fd5b600160e860020a03198316600081815260066020526040908190208054600160a060020a031916600160a060020a03861690811790915591907f7d3ca855476824d6b0058a0c46e19e7275ce11bbe83bb82418ecf3a94e09c0d1905160405180910390a350600192915050565b600354600160a060020a031681565b600054600160a060020a0390811691161490565b600354600090600160a060020a031615801590610d465750600354600160a060020a038381169116145b92915050565b600254600090600160a060020a031615801590610d46575050600254600160a060020a0390811691161490565b6009546007546008546000928392839283928392610dc19260ff928316600a90810a93610db5936301000000900416900a63ffffffff610fe616565b9063ffffffff61101116565b9250610dd788610db5898663ffffffff610fe616565b9150610ded88610db5888663ffffffff610fe616565b91989197509095505050505050565b6000600160a060020a0385161515610e1357600080fd5b831515610e1f57600080fd5b6000821115610e3d57600160a060020a0383161515610e3d57600080fd5b506001949350505050565b600080600080600080610e5a8a61086d565b925060008311610e6957600080fd5b610e7c8984610e778d6104e3565b611028565b1515610e8757600080fd5b610e92838989610d79565b939b909a50929850919650505050505050565b600454600090600160a060020a03166323b872dd878787856040516020015260405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b1515610f1357600080fd5b6102c65a03f11515610f2457600080fd5b505050604051805190501515610f3957600080fd5b600160a060020a03831615610fda57600454600160a060020a03166323b872dd87858560006040516020015260405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b1515610fb457600080fd5b6102c65a03f11515610fc557600080fd5b505050604051805190501515610fda57600080fd5b50600195945050505050565b60008282028315806110025750828482811515610fff57fe5b04145b151561100a57fe5b9392505050565b600080828481151561101f57fe5b04949350505050565b600060018285106110495783611044868563ffffffff61106d16565b111590505b80156110655761105f858463ffffffff61107f16565b84111590505b949350505050565b60008282111561107957fe5b50900390565b60008282018381101561100a57fe00a165627a7a723058209c2924114f3e1fd3fbeb1d6b29870235c58e9cea75bbcdfc2bfcb4dc6203340a0029 \ No newline at end of file +608060405234801561001057600080fd5b5060405160408061141e83398101604052805160209091015160008054600160a060020a03191633600160a060020a03908116919091179091558216151561005757600080fd5b7fffffff00000000000000000000000000000000000000000000000000000000008116151561008557600080fd5b60048054600160a060020a031916600160a060020a03848116919091178083556007805462ffffff19167d0100000000000000000000000000000000000000000000000000000000008604179055604080517f313ce5670000000000000000000000000000000000000000000000000000000081529051919092169263313ce567928082019260209290918290030181600087803b15801561012657600080fd5b505af115801561013a573d6000803e3d6000fd5b505050506040513d602081101561015057600080fd5b50516007805460ff90921663010000000263ff00000019909216919091179055604080517f7ffdf53e0000000000000000000000000000000000000000000000000000000081529051600160a060020a03841691637ffdf53e9160048083019260209291908290030181600087803b1580156101cb57600080fd5b505af11580156101df573d6000803e3d6000fd5b505050506040513d60208110156101f557600080fd5b5051600855604080517fe30ac6c30000000000000000000000000000000000000000000000000000000081529051600160a060020a0384169163e30ac6c39160048083019260209291908290030181600087803b15801561025557600080fd5b505af1158015610269573d6000803e3d6000fd5b505050506040513d602081101561027f57600080fd5b50516009805460ff191660ff909216919091179055506111789050806102a66000396000f30060806040526004361061010e5763ffffffff60e060020a6000350416632c1e816d8114610113578063313ce567146101485780634a9569c514610173578063707789c5146101a75780637307453a146101c85780637ffdf53e146101ea57806383121455146101ff5780638da5cb5b1461023d5780638ea643761461025257806392a85fde14610267578063a154360014610299578063a7f43779146102df578063b2b802c8146102f6578063bbd30f1014610334578063bd90bc3014610356578063c0b6f5611461037b578063d153b60c1461039c578063d348050c146103b1578063e30ac6c3146103c6578063e71a7811146103db578063f3443dd2146103f0578063fc6f94681461041e575b600080fd5b34801561011f57600080fd5b50610134600160a060020a0360043516610433565b604080519115158252519081900360200190f35b34801561015457600080fd5b5061015d610503565b6040805160ff9092168252519081900360200190f35b34801561017f57600080fd5b50610195600160e860020a031960043516610513565b60408051918252519081900360200190f35b3480156101b357600080fd5b50610134600160a060020a036004351661052f565b3480156101d457600080fd5b50610134600160e860020a0319600435166105ff565b3480156101f657600080fd5b506101956106a5565b34801561020b57600080fd5b50610221600160e860020a0319600435166106ab565b60408051600160a060020a039092168252519081900360200190f35b34801561024957600080fd5b506102216106d0565b34801561025e57600080fd5b506102216106df565b34801561027357600080fd5b5061027c6106ee565b60408051600160e860020a03199092168252519081900360200190f35b3480156102a557600080fd5b506102c1600435602435600160e860020a031960443516610714565b60408051938452602084019290925282820152519081900360600190f35b3480156102eb57600080fd5b506102f461075f565b005b34801561030257600080fd5b50610195600160a060020a036004358116906024359060443516606435600160e860020a03196084351660a4356107c2565b34801561034057600080fd5b50610195600160e860020a03196004351661089f565b34801561036257600080fd5b50610134600160e860020a03196004351660243561093f565b34801561038757600080fd5b50610134600160a060020a03600435166109af565b3480156103a857600080fd5b50610221610a21565b3480156103bd57600080fd5b50610221610a30565b3480156103d257600080fd5b5061015d610a3f565b3480156103e757600080fd5b50610134610a48565b3480156103fc57600080fd5b50610134600160e860020a031960043516600160a060020a0360243516610acf565b34801561042a57600080fd5b50610221610d78565b600061043e33610d87565b8061044d575061044d33610d9b565b151561045857600080fd5b600054600160a060020a038381169116141561047357600080fd5b30600160a060020a031682600160a060020a03161415151561049457600080fd5b61049d82610dcb565b156104a757600080fd5b6003805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091556040517f17bb0532ac84902a52bb6799529153f5ea501fc54fbcf3ea00dbd42bceb6b0f490600090a2506001919050565b6007546301000000900460ff1690565b600160e860020a03191660009081526005602052604090205490565b600061053a33610d87565b80610549575061054933610d9b565b151561055457600080fd5b600054600160a060020a038381169116141561056f57600080fd5b30600160a060020a031682600160a060020a03161415151561059057600080fd5b61059982610d9b565b156105a357600080fd5b6002805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091556040517fac46a4511b8366ae3b7cf3cf342e31556274975598dcae03c866f8f0f55d51c490600090a2506001919050565b600061060a33610dcb565b151561061557600080fd5b600160e860020a03198216600090815260066020526040902054600160a060020a0316151561064357600080fd5b600160e860020a03198216600081815260066020526040808220805473ffffffffffffffffffffffffffffffffffffffff19169055517f8bee55d48a68222fe9f1ee5b03929f037c08911acfe96caa89dcfe3fc1e953589190a2506001919050565b60085490565b600160e860020a031916600090815260066020526040902054600160a060020a031690565b600054600160a060020a031681565b600254600160a060020a031681565b6007547d0100000000000000000000000000000000000000000000000000000000000290565b60008080600160e860020a03198416151561072e57600080fd5b6107378461089f565b92506000831161074657600080fd5b610751838787610df8565b909250905093509350939050565b61076833610d9b565b80610777575061077733610dcb565b151561078257600080fd5b604051600160a060020a033316907f066a905b79c0121afe61e3a44e0b14b6bc1ec16d854cdba09efdfc9b6aa9af8190600090a233600160a060020a0316ff5b6000806000806107d48a8a8a8a610e7b565b15156107df57600080fd5b5087915085905083600160e860020a031986161561080b5761080386868b8a610ec7565b909450925090505b610818338b858b86610f24565b151561082357600080fd5b60408051600160a060020a03808d168252602082018690528a168183015260608101849052600160e860020a03198816608082015260a0810187905260c0810183905290517f51e16b543c5bb3c6005bcb22b4b577f1567710d0f828897168bf3f1e9ad36a3f9181900360e00190a15001979650505050505050565b600160e860020a03198116600090815260066020526040812054600160a060020a03168015156108ce57600080fd5b80600160a060020a03166398d5fdca6040518163ffffffff1660e060020a028152600401602060405180830381600087803b15801561090c57600080fd5b505af1158015610920573d6000803e3d6000fd5b505050506040513d602081101561093657600080fd5b50519392505050565b600061094a33610dcb565b151561095557600080fd5b600160e860020a03198316600081815260056020908152604091829020859055815185815291517f058ed7b764a1a386e76b3cbca5e1d213a98664cb17e47628ed1bb3047f5039929281900390910190a250600192915050565b60006109ba33610d87565b15156109c557600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091556040517f20f5afdf40bf7b43c89031a5d4369a30b159e512d164aa46124bcb706b4a1caf90600090a2506001919050565b600154600160a060020a031681565b600454600160a060020a031690565b60095460ff1690565b60015460009033600160a060020a03908116911614610a6657600080fd5b6001805460008054600160a060020a0380841673ffffffffffffffffffffffffffffffffffffffff19928316178084559190931690935560405192909116917f624adc4c72536289dd9d5439ccdeccd8923cb9af95fb626b21935447c77b84079190a250600190565b6000610ada33610dcb565b1515610ae557600080fd5b600160a060020a0382161515610afa57600080fd5b600160e860020a031983161515610b1057600080fd5b600760009054906101000a90047d010000000000000000000000000000000000000000000000000000000000027cffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191682600160a060020a03166392a85fde6040518163ffffffff1660e060020a028152600401602060405180830381600087803b158015610b9b57600080fd5b505af1158015610baf573d6000803e3d6000fd5b505050506040513d6020811015610bc557600080fd5b5051600160e860020a03191614610bdb57600080fd5b827cffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191682600160a060020a03166382564bca6040518163ffffffff1660e060020a028152600401602060405180830381600087803b158015610c3a57600080fd5b505af1158015610c4e573d6000803e3d6000fd5b505050506040513d6020811015610c6457600080fd5b5051600160e860020a03191614610c7a57600080fd5b600760039054906101000a900460ff1660ff1682600160a060020a031663313ce5676040518163ffffffff1660e060020a028152600401602060405180830381600087803b158015610ccb57600080fd5b505af1158015610cdf573d6000803e3d6000fd5b505050506040513d6020811015610cf557600080fd5b505160ff1614610d0457600080fd5b600160e860020a03198316600081815260066020526040808220805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a03871690811790915590519092917f7d3ca855476824d6b0058a0c46e19e7275ce11bbe83bb82418ecf3a94e09c0d191a350600192915050565b600354600160a060020a031681565b600054600160a060020a0390811691161490565b600354600090600160a060020a031615801590610dc55750600354600160a060020a038381169116145b92915050565b600254600090600160a060020a031615801590610dc5575050600254600160a060020a0390811691161490565b6009546007546008546000928392839283928392610e409260ff928316600a90810a93610e34936301000000900416900a63ffffffff6110a416565b9063ffffffff6110cf16565b9250610e5688610e34898663ffffffff6110a416565b9150610e6c88610e34888663ffffffff6110a416565b91989197509095505050505050565b6000600160a060020a0385161515610e9257600080fd5b831515610e9e57600080fd5b6000821115610ebc57600160a060020a0383161515610ebc57600080fd5b506001949350505050565b600080600080600080610ed98a61089f565b925060008311610ee857600080fd5b610efb8984610ef68d610513565b6110e6565b1515610f0657600080fd5b610f11838989610df8565b939b909a50929850919650505050505050565b60048054604080517f23b872dd000000000000000000000000000000000000000000000000000000008152600160a060020a03898116948201949094528784166024820152604481018790529051600093909216916323b872dd9160648082019260209290919082900301818787803b158015610fa057600080fd5b505af1158015610fb4573d6000803e3d6000fd5b505050506040513d6020811015610fca57600080fd5b50511515610fd757600080fd5b600160a060020a038316156110985760048054604080517f23b872dd000000000000000000000000000000000000000000000000000000008152600160a060020a038a811694820194909452868416602482015260448101869052905192909116916323b872dd916064808201926020929091908290030181600087803b15801561106157600080fd5b505af1158015611075573d6000803e3d6000fd5b505050506040513d602081101561108b57600080fd5b5051151561109857600080fd5b50600195945050505050565b60008282028315806110c057508284828115156110bd57fe5b04145b15156110c857fe5b9392505050565b60008082848115156110dd57fe5b04949350505050565b600060018285106111075783611102868563ffffffff61112b16565b111590505b80156111235761111d858463ffffffff61113d16565b84111590505b949350505050565b60008282111561113757fe5b50900390565b6000828201838110156110c857fe00a165627a7a72305820aa0e79d9729860c3ea975c3ca5566b13c5b3aeabc5145d317f0d4a0b48cfd9d80029 \ No newline at end of file diff --git a/contracts/bin/SafeMath.bin b/contracts/bin/SafeMath.bin index 9912016..b35addd 100644 --- a/contracts/bin/SafeMath.bin +++ b/contracts/bin/SafeMath.bin @@ -1 +1 @@ -60606040523415600e57600080fd5b603580601b6000396000f3006060604052600080fd00a165627a7a72305820ea1dfda224c360b600e2ecc38282d885e0b0e62695ca7d8d68d5b6a724ed013e0029 \ No newline at end of file +604c602c600b82828239805160001a60731460008114601c57601e565bfe5b5030600052607381538281f30073000000000000000000000000000000000000000030146080604052600080fd00a165627a7a723058203d7cd16523f4631b70b5489d2d1c388d470d5ac1c771ea4b73a0fd8136d15f640029 \ No newline at end of file diff --git a/contracts/bin/Workers.bin b/contracts/bin/Workers.bin index 81323dc..0537141 100644 --- a/contracts/bin/Workers.bin +++ b/contracts/bin/Workers.bin @@ -1 +1 @@ -6060604052341561000f57600080fd5b60008054600160a060020a033316600160a060020a03199091161790556107438061003b6000396000f3006060604052600436106100c45763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416632c1e816d81146100c95780634048a257146100fc578063707789c51461012d5780638da5cb5b1461014c5780638ea643761461017b578063a7f437791461018e578063aa156645146101a3578063c0b6f561146101c2578063c4f987a5146101e1578063d153b60c14610200578063e71a781114610213578063ea6790cf14610226578063fc6f946814610248575b600080fd5b34156100d457600080fd5b6100e8600160a060020a036004351661025b565b604051901515815260200160405180910390f35b341561010757600080fd5b61011b600160a060020a036004351661032e565b60405190815260200160405180910390f35b341561013857600080fd5b6100e8600160a060020a0360043516610340565b341561015757600080fd5b61015f610413565b604051600160a060020a03909116815260200160405180910390f35b341561018657600080fd5b61015f610422565b341561019957600080fd5b6101a1610431565b005b34156101ae57600080fd5b6100e8600160a060020a0360043516610460565b34156101cd57600080fd5b6100e8600160a060020a036004351661047f565b34156101ec57600080fd5b6100e8600160a060020a03600435166104f4565b341561020b57600080fd5b61015f61056a565b341561021e57600080fd5b6100e8610579565b341561023157600080fd5b61011b600160a060020a0360043516602435610600565b341561025357600080fd5b61015f610697565b6000610266336106a6565b806102755750610275336106ba565b151561028057600080fd5b600054600160a060020a038381169116141561029b57600080fd5b30600160a060020a031682600160a060020a0316141515156102bc57600080fd5b6102c5826106ea565b156102cf57600080fd5b6003805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091557f17bb0532ac84902a52bb6799529153f5ea501fc54fbcf3ea00dbd42bceb6b0f460405160405180910390a2506001919050565b60046020526000908152604090205481565b600061034b336106a6565b8061035a575061035a336106ba565b151561036557600080fd5b600054600160a060020a038381169116141561038057600080fd5b30600160a060020a031682600160a060020a0316141515156103a157600080fd5b6103aa826106ba565b156103b457600080fd5b6002805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091557fac46a4511b8366ae3b7cf3cf342e31556274975598dcae03c866f8f0f55d51c460405160405180910390a2506001919050565b600054600160a060020a031681565b600254600160a060020a031681565b61043a336106ba565b806104495750610449336106ea565b151561045457600080fd5b33600160a060020a0316ff5b600160a060020a03166000908152600460205260409020544390101590565b600061048a336106a6565b151561049557600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091557f20f5afdf40bf7b43c89031a5d4369a30b159e512d164aa46124bcb706b4a1caf60405160405180910390a2506001919050565b60006104ff336106ea565b151561050a57600080fd5b50600160a060020a0381166000818152600460205260408082208054908390559190911191907fc5917d6d705542e8299632992e81d551fc6e12c5c0dd7ab918b9df7db5555b2b90839051901515815260200160405180910390a2919050565b600154600160a060020a031681565b60015460009033600160a060020a0390811691161461059757600080fd5b6001805460008054600160a060020a0380841673ffffffffffffffffffffffffffffffffffffffff1992831617928390559216909255167f624adc4c72536289dd9d5439ccdeccd8923cb9af95fb626b21935447c77b840760405160405180910390a250600190565b60008061060c336106ea565b151561061757600080fd5b600160a060020a038416151561062c57600080fd5b4383101561063957600080fd5b50600160a060020a038316600081815260046020526040908190208490554384039184917fc905a4aa20c3ea64a398e2cd342f153389c4c72818b5dbc6fb5e83a628de09a99084905190815260200160405180910390a39392505050565b600354600160a060020a031681565b600054600160a060020a0390811691161490565b600354600090600160a060020a0316158015906106e45750600354600160a060020a038381169116145b92915050565b600254600090600160a060020a0316158015906106e4575050600254600160a060020a03908116911614905600a165627a7a72305820fa1ef7d8b2c6a1668d4fe5e9fc77f108ffdcfdc2b61f1f1a28434a5c194a55d70029 \ No newline at end of file +608060405234801561001057600080fd5b5060008054600160a060020a033316600160a060020a03199091161790556107508061003d6000396000f3006080604052600436106100c45763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416632c1e816d81146100c95780634048a257146100fe578063707789c5146101315780638da5cb5b146101525780638ea6437614610183578063a7f4377914610198578063aa156645146101af578063c0b6f561146101d0578063c4f987a5146101f1578063d153b60c14610212578063e71a781114610227578063ea6790cf1461023c578063fc6f946814610260575b600080fd5b3480156100d557600080fd5b506100ea600160a060020a0360043516610275565b604080519115158252519081900360200190f35b34801561010a57600080fd5b5061011f600160a060020a0360043516610345565b60408051918252519081900360200190f35b34801561013d57600080fd5b506100ea600160a060020a0360043516610357565b34801561015e57600080fd5b50610167610427565b60408051600160a060020a039092168252519081900360200190f35b34801561018f57600080fd5b50610167610436565b3480156101a457600080fd5b506101ad610445565b005b3480156101bb57600080fd5b506100ea600160a060020a0360043516610474565b3480156101dc57600080fd5b506100ea600160a060020a0360043516610492565b3480156101fd57600080fd5b506100ea600160a060020a0360043516610504565b34801561021e57600080fd5b50610167610576565b34801561023357600080fd5b506100ea610585565b34801561024857600080fd5b5061011f600160a060020a036004351660243561060c565b34801561026c57600080fd5b506101676106a4565b6000610280336106b3565b8061028f575061028f336106c7565b151561029a57600080fd5b600054600160a060020a03838116911614156102b557600080fd5b30600160a060020a031682600160a060020a0316141515156102d657600080fd5b6102df826106f7565b156102e957600080fd5b6003805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091556040517f17bb0532ac84902a52bb6799529153f5ea501fc54fbcf3ea00dbd42bceb6b0f490600090a2506001919050565b60046020526000908152604090205481565b6000610362336106b3565b806103715750610371336106c7565b151561037c57600080fd5b600054600160a060020a038381169116141561039757600080fd5b30600160a060020a031682600160a060020a0316141515156103b857600080fd5b6103c1826106c7565b156103cb57600080fd5b6002805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091556040517fac46a4511b8366ae3b7cf3cf342e31556274975598dcae03c866f8f0f55d51c490600090a2506001919050565b600054600160a060020a031681565b600254600160a060020a031681565b61044e336106c7565b8061045d575061045d336106f7565b151561046857600080fd5b33600160a060020a0316ff5b600160a060020a031660009081526004602052604090205443111590565b600061049d336106b3565b15156104a857600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0384169081179091556040517f20f5afdf40bf7b43c89031a5d4369a30b159e512d164aa46124bcb706b4a1caf90600090a2506001919050565b600061050f336106f7565b151561051a57600080fd5b50600160a060020a03811660008181526004602090815260408083208054908490558151931080845290519093927fc5917d6d705542e8299632992e81d551fc6e12c5c0dd7ab918b9df7db5555b2b92908290030190a2919050565b600154600160a060020a031681565b60015460009033600160a060020a039081169116146105a357600080fd5b6001805460008054600160a060020a0380841673ffffffffffffffffffffffffffffffffffffffff19928316178084559190931690935560405192909116917f624adc4c72536289dd9d5439ccdeccd8923cb9af95fb626b21935447c77b84079190a250600190565b600080610618336106f7565b151561062357600080fd5b600160a060020a038416151561063857600080fd5b4383101561064557600080fd5b50600160a060020a038316600081815260046020908152604091829020859055815143860380825292519293869390927fc905a4aa20c3ea64a398e2cd342f153389c4c72818b5dbc6fb5e83a628de09a9928290030190a39392505050565b600354600160a060020a031681565b600054600160a060020a0390811691161490565b600354600090600160a060020a0316158015906106f15750600354600160a060020a038381169116145b92915050565b600254600090600160a060020a0316158015906106f1575050600254600160a060020a03908116911614905600a165627a7a7230582000ed02b6cc372037162983a7773d8a8621a8eb6427b805155d2518f972afc9e20029 \ No newline at end of file diff --git a/contracts/openst-protocol/EIP20Interface.sol b/contracts/openst-protocol/EIP20Interface.sol index 350793d..d66ba74 100644 --- a/contracts/openst-protocol/EIP20Interface.sol +++ b/contracts/openst-protocol/EIP20Interface.sol @@ -1,4 +1,4 @@ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; // Copyright 2017 OpenST Ltd. // diff --git a/contracts/openst-protocol/EIP20Token.sol b/contracts/openst-protocol/EIP20Token.sol index bf64bdd..3766478 100644 --- a/contracts/openst-protocol/EIP20Token.sol +++ b/contracts/openst-protocol/EIP20Token.sol @@ -1,4 +1,4 @@ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; // Copyright 2017 OpenST Ltd. // @@ -39,7 +39,7 @@ contract EIP20Token is EIP20Interface { mapping(address => mapping (address => uint256)) allowed; - function EIP20Token(string _symbol, string _name, uint8 _decimals) public + constructor(string _symbol, string _name, uint8 _decimals) public { tokenSymbol = _symbol; tokenName = _name; @@ -79,7 +79,7 @@ contract EIP20Token is EIP20Interface { balances[msg.sender] = balances[msg.sender].sub(_value); balances[_to] = balances[_to].add(_value); - Transfer(msg.sender, _to, _value); + emit Transfer(msg.sender, _to, _value); return true; } @@ -90,7 +90,7 @@ contract EIP20Token is EIP20Interface { allowed[_from][msg.sender] = allowed[_from][msg.sender].sub(_value); balances[_to] = balances[_to].add(_value); - Transfer(_from, _to, _value); + emit Transfer(_from, _to, _value); return true; } @@ -100,7 +100,7 @@ contract EIP20Token is EIP20Interface { allowed[msg.sender][_spender] = _value; - Approval(msg.sender, _spender, _value); + emit Approval(msg.sender, _spender, _value); return true; } @@ -111,7 +111,7 @@ contract EIP20Token is EIP20Interface { balances[address(this)] = balances[address(this)].sub(_amount); balances[_beneficiary] = balances[_beneficiary].add(_amount); - Transfer(address(this), _beneficiary, _amount); + emit Transfer(address(this), _beneficiary, _amount); return true; } diff --git a/contracts/openst-protocol/UtilityTokenInterface.sol b/contracts/openst-protocol/UtilityTokenInterface.sol index 54f59d8..5860a07 100644 --- a/contracts/openst-protocol/UtilityTokenInterface.sol +++ b/contracts/openst-protocol/UtilityTokenInterface.sol @@ -1,5 +1,5 @@ /* solhint-disable-next-line compiler-fixed */ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; // Copyright 2017 OpenST Ltd. // diff --git a/contracts/truffle/Migrations.sol b/contracts/truffle/Migrations.sol index f170cb4..5e03293 100644 --- a/contracts/truffle/Migrations.sol +++ b/contracts/truffle/Migrations.sol @@ -1,4 +1,4 @@ -pragma solidity ^0.4.17; +pragma solidity ^0.4.23; contract Migrations { address public owner; @@ -8,7 +8,7 @@ contract Migrations { if (msg.sender == owner) _; } - function Migrations() public { + constructor() public { owner = msg.sender; } diff --git a/docs/baseCacheMultiManagementKlass.html b/docs/baseCacheMultiManagementKlass.html deleted file mode 100644 index 284a793..0000000 --- a/docs/baseCacheMultiManagementKlass.html +++ /dev/null @@ -1,1137 +0,0 @@ - - - - - - - OpenST Payments Class: baseCacheMultiManagementKlass - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: baseCacheMultiManagementKlass

-
- -
- -

- baseCacheMultiManagementKlass -

- - -
- - -
-
- - -
-
-

new baseCacheMultiManagementKlass(params)

- - -
-
- - -
- constructor -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
params - - -Object - - - - - cache key generation & expiry related params
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

_fetchFromCache()

- - -
-
- - -
- fetch from cache -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Object - - - -
-
- - - - - -
- - - -
-
-

_setCache(dataToSet)

- - -
-
- - -
- set data in cache. -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
dataToSet - - -Object - - - - - data to set in cache
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Result - - - -
-
- - - - - -
- - - -
-
-

clear()

- - -
-
- - -
- clear cache -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise.<Result> - - - -
-
- - - - - -
- - - -
-
-

fetch()

- - -
-
- - -
- Fetch data from cache, in case of cache miss calls sub class method to fetch data from source -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- - On success, data.value has value. On failure, error details returned. -
- - - -
-
- Type -
-
- -Promise.<Result> - - - -
-
- - - - - -
- - - -
-
-

fetchDataFromSource()

- - -
-
- - -
- fetch data from source -return should be of klass Result -data attr of return is returned and set in cache -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Result - - - -
-
- - - - - -
- - - -
-
-

setCacheExpiry()

- - -
-
- - -
- set cache expiry in oThis.cacheExpiry and return it -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Number - - - -
-
- - - - - -
- - - -
-
-

setCacheKeys()

- - -
-
- - -
- set cache keys in oThis.cacheKeys and return it -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -String - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/classes.list.html b/docs/classes.list.html deleted file mode 100644 index d73d5c4..0000000 --- a/docs/classes.list.html +++ /dev/null @@ -1,396 +0,0 @@ - - - - - - - OpenST Payments Classes - - - - - - - - - - - - - -
-
- - -
- -
- - -

Classes

-
- -
- -

- -

- - -
- - -
-
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
baseCacheMultiManagementKlass
-
- -
BasicHelperKlass
-
- -
approve
-
- -
base
-
- -
batchAllocator
-
- -
register
-
- -
transfer
-
- -
AdjustAirdropAmountKlass
-
- -
AirdropUserBalanceKlass
-
- -
AirdropBalanceCache
-
- -
BalanceCache
-
- -
PricerCache
-
- -
Airdrop
-
- -
BrandedToken
-
- -
ContractInteractHelper
-
- -
OpsManagedContract
-
- -
OwnedContract
-
- -
MockToken
-
- -
Pricer
-
- -
Workers
-
- -
Deploy
-
- -
MySQLQueryBuilderKlass
-
- -
SetWorkerOps
-
- -
TransactionHelper
-
- -
userAirdropDetailCache
-
-
- - - - - -

Namespaces

- -
-
web3EventsDecoder
-
- -
web3EventsFormatter
-
-
- - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/fonts/glyphicons-halflings-regular.eot b/docs/fonts/glyphicons-halflings-regular.eot deleted file mode 100644 index b93a495..0000000 Binary files a/docs/fonts/glyphicons-halflings-regular.eot and /dev/null differ diff --git a/docs/fonts/glyphicons-halflings-regular.svg b/docs/fonts/glyphicons-halflings-regular.svg deleted file mode 100644 index 94fb549..0000000 --- a/docs/fonts/glyphicons-halflings-regular.svg +++ /dev/null @@ -1,288 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/fonts/glyphicons-halflings-regular.ttf b/docs/fonts/glyphicons-halflings-regular.ttf deleted file mode 100644 index 1413fc6..0000000 Binary files a/docs/fonts/glyphicons-halflings-regular.ttf and /dev/null differ diff --git a/docs/fonts/glyphicons-halflings-regular.woff b/docs/fonts/glyphicons-halflings-regular.woff deleted file mode 100644 index 9e61285..0000000 Binary files a/docs/fonts/glyphicons-halflings-regular.woff and /dev/null differ diff --git a/docs/fonts/glyphicons-halflings-regular.woff2 b/docs/fonts/glyphicons-halflings-regular.woff2 deleted file mode 100644 index 64539b5..0000000 Binary files a/docs/fonts/glyphicons-halflings-regular.woff2 and /dev/null differ diff --git a/docs/global.html b/docs/global.html deleted file mode 100644 index 7a82c15..0000000 --- a/docs/global.html +++ /dev/null @@ -1,375 +0,0 @@ - - - - - - - OpenST Payments Global - - - - - - - - - - - - - -
-
- - -
- -
- - -

Global

-
- -
- -

- -

- - -
- - -
-
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - - - - - - - -

Members

- -
- -
-
-

<constant> rootPrefix

- - -
-
- -
- List of all addresses and there respective abi, bin, passphrase -required for platform. - -And helper methods to access this information using human readable -names. -
- - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - -
- -
- - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/img/glyphicons-halflings-white.png b/docs/img/glyphicons-halflings-white.png deleted file mode 100644 index 3bf6484..0000000 Binary files a/docs/img/glyphicons-halflings-white.png and /dev/null differ diff --git a/docs/img/glyphicons-halflings.png b/docs/img/glyphicons-halflings.png deleted file mode 100644 index a996999..0000000 Binary files a/docs/img/glyphicons-halflings.png and /dev/null differ diff --git a/docs/index.html b/docs/index.html deleted file mode 100644 index 7df5100..0000000 --- a/docs/index.html +++ /dev/null @@ -1,304 +0,0 @@ - - - - - - - OpenST Payments Index - - - - - - - - - - - - - -
-
- - -
- -
- - - - - - - - - - - - - - - - - - - - - - -
-

OpenST Payments - Advance Payment infrastructure on top of the OpenST network

Latest version -Travis -Downloads per month -Gitter: JOIN CHAT

-

While OpenST 0.9 is available as-is for anyone to use, we caution that this is early stage software and under heavy ongoing development and improvement. Please report bugs and suggested improvements.

-

Install OpenST Payments

npm install @openstfoundation/openst-payments --save

Run Test Chain

cd mocha_test/scripts/
-sh start_test_chain.sh

Set EVN Variables

Setup Initial Setup Variables:

export OST_UTILITY_GETH_RPC_PROVIDER=''
-export OST_UTILITY_DEPLOYER_ADDR=''
-export OST_UTILITY_DEPLOYER_PASSPHRASE=''
-export OST_UTILITY_OPS_ADDR=''
-export OST_UTILITY_OPS_PASSPHRASE=''

Deploy Branded Token Contract:

node tools/deploy/EIP20TokenMock.js conversionRate symbol name decimals gasPrice

Deploy Workers Contract:

node tools/deploy/workers.js gasPrice chainId

Deploy Airdrop Contract:

node tools/deploy/airdrop.js brandedTokenContractAddress baseCurrency workerContractAddress airdropBudgetHolder gasPrice chainId

Set Caching Engine:

export OST_CACHING_ENGINE='none'
-For using redis/memcache as cache engine refer - [OpenSTFoundation/ost-price-oracle](https://github.com/OpenSTFoundation/ost-price-oracle)

Set DB Details For Payments/Airdrop:

export OP_MYSQL_HOST=''
-export OP_MYSQL_USER=''
-export OP_MYSQL_PASSWORD=''
-export OP_MYSQL_DATABASE=''
-export OP_MYSQL_CONNECTION_POOL_SIZE='5'

Create Airdrop Tables:

node migrations/create_tables.js 

Example:

const OpenSTPayment = require('@openstfoundation/openst-payments')
-  , deployer = new OpenSTPayment.deployer()
-  , opsManaged = new OpenSTPayment.opsManaged(contractAddress, gasPrice, chainId)
-  , workers = new OpenSTPayment.worker(workerContractAddress, chainId)
-  , airdrop = new OpenSTPayment.airdrop(airdropContractAddress, chainId)
-  , airdropManager = OpenSTPayment.airdropManager
-;  
-  // Deploy Contract
-  deployer.deploy( contractName, constructorArgs, gasPrice, options);
-  // Register Airdrop
-  airdropManager.registerAirdrop(airdropContractAddress, chainId);
-  // Set Ops Address
-  opsManaged.setOpsAddress(deployerAddress, deployerPassphrase, opsAddress, options);
-  // Set Worker
-  workers.setWorker(senderAddress, senderPassphrase, workerAddress, deactivationHeight, gasPrice, options);
-  // Set Price Oracle
-  airdrop.setPriceOracle(senderAddress, senderPassphrase, currency, address, gasPrice, options);
-  // Set Accepted Margin
-  airdrop.setAcceptedMargin(senderAddress, senderPassphrase, currency, acceptedMargin, gasPrice, options);
-  // Transfer Amount to airdrop budget holder
-  airdropManager.transfer(senderAddress, senderPassphrase, airdropContractAddress, amount, gasPrice, chainId, options);
-  // Approve airdrop budget holder
-  airdropManager.approve(airdropContractAddress, airdropBudgetHolderPassphrase, gasPrice, chainId, options);
-  // Allocate airdrop amount to users in batch
-  airdropManager.batchAllocate(airdropContractAddress, transactionHash, airdropUsers, chainId);
-  // Get Users Airdrop Balance
-  airdropManager.getAirdropBalance(chainId, airdropContractAddress, userAddresses);
-  // Call Pay method
-  airdrop.pay(workerAddress,
-              WorkerPassphrase,
-              beneficiaryAddress,
-              transferAmount,
-              commissionBeneficiaryAddress,
-              commissionAmount,
-              currency,
-              intendedPricePoint,
-              spender,
-              gasPrice,
-              {tag:'airdrop.pay', returnType: 'txHash'});

For further implementation details, please refer to the API documentation.

-
- - - - - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-helpers_basic_helper-BasicHelperKlass.html b/docs/module-helpers_basic_helper-BasicHelperKlass.html deleted file mode 100644 index bdc1135..0000000 --- a/docs/module-helpers_basic_helper-BasicHelperKlass.html +++ /dev/null @@ -1,2419 +0,0 @@ - - - - - - - OpenST Payments Class: BasicHelperKlass - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: BasicHelperKlass

-
- -
- -

- helpers/basic_helper~ - - BasicHelperKlass -

- - -
- - -
-
- - -
-
-

new BasicHelperKlass()

- - -
-
- - -
- Basic helper methods constructor -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

convertToBigNumber(amountInWei)

- - -
-
- - -
- Convert number to big number. Make sure it's a valid number -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
amountInWei - - -number - - - - - amount in wei to be formatted
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -BigNumber - - - -
-
- - - - - -
- - - -
-
-

formatWeiToString(amountInWei)

- - -
-
- - -
- Convert wei to proper string. Make sure it's a valid number -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
amountInWei - - -number - - - - - amount in wei to be formatted
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -string - - - -
-
- - - - - -
- - - -
-
-

getReturnType(returnType)

- - -
-
- - -
- get return type for transaction -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
returnType - - -string - - - - - return from geth transactions when following event is received
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -string - - - -
-
- - - - - -
- - - -
-
-

isAddressValid(address)

- - -
-
- - -
- Check if address is valid or not -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
address - - -string - - - - - Address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -boolean - - - -
-
- - - - - -
- - - -
-
-

isBTConversionRateValid(conversionRate)

- - -
-
- - -
- Check if branded token conversion rate is valid or not -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
conversionRate - - -number - - - - - Branded token conversion rate
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -boolean - - - -
-
- - - - - -
- - - -
-
-

isBTNameValid(name)

- - -
-
- - -
- Check if branded token name is valid or not -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
name - - -string - - - - - Branded token name
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -boolean - - - -
-
- - - - - -
- - - -
-
-

isBTSymbolValid(symbol)

- - -
-
- - -
- Check if branded token symbol is valid or not -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
symbol - - -string - - - - - Branded token symbol
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -boolean - - - -
-
- - - - - -
- - - -
-
-

isNonZeroWeiValid(amountInWei)

- - -
-
- - -
- Check if amount is valid wei number and not zero -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
amountInWei - - -number - - - - - amount in wei
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -boolean - - - -
-
- - - - - -
- - - -
-
-

isReturnTypeTxHash(returnType)

- - -
-
- - -
- check if return type is txHash or not -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
returnType - - -string - - - - - return type
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -boolean - - - -
-
- - - - - -
- - - -
-
-

isReturnTypeTxReceipt(returnType)

- - -
-
- - -
- check if return type is txReceipt or not -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
returnType - - -string - - - - - return type
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -boolean - - - -
-
- - - - - -
- - - -
-
-

isReturnTypeUUID(returnType)

- - -
-
- - -
- check if return type is uuid or not -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
returnType - - -string - - - - - return type
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -boolean - - - -
-
- - - - - -
- - - -
-
-

isTxHashValid(transactionHash)

- - -
-
- - -
- Check if transaction hash is valid or not -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
transactionHash - - -string - - - - - Transaction hash
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -boolean - - - -
-
- - - - - -
- - - -
-
-

isUuidValid(uuid)

- - -
-
- - -
- Check if uuid is valid or not -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
uuid - - -string - - - - - Branded Token UUID
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -boolean - - - -
-
- - - - - -
- - - -
-
-

isValidChainId(chainId)

- - -
-
- - -
- Check if chainId is valid -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
chainId - - -Number - - - - - chainId
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Bool - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-helpers_basic_helper.html b/docs/module-helpers_basic_helper.html deleted file mode 100644 index f06aca7..0000000 --- a/docs/module-helpers_basic_helper.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: helpers/basic_helper - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: helpers/basic_helper

-
- -
- -
- - -
-
- - -
Perform basic validations
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
BasicHelperKlass
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_airdrop_management_approve-approve.html b/docs/module-lib_airdrop_management_approve-approve.html deleted file mode 100644 index bc91d23..0000000 --- a/docs/module-lib_airdrop_management_approve-approve.html +++ /dev/null @@ -1,807 +0,0 @@ - - - - - - - OpenST Payments Class: approve - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: approve

-
- -
- -

- lib/airdrop_management/approve~ - - approve -

- - -
- - -
-
- - -
-
-

new approve(airdropContractAddress, airdropBudgetHolderPassphrase, gasPrice, chainId, options)

- - -
-
- - -
- Constructor to create object of approve -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
airdropContractAddress - - -Hex - - - - - airdrop contract address
airdropBudgetHolderPassphrase - - -String - - - - - airdropBudgetHolder Passphrase
gasPrice - - -String - - - - - gas price
chainId - - -Number - - - - - chain Id
options - - -Object - - - - - chain Id
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Object - - - -
-
- - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

doApprove()

- - -
-
- - -
- Perform Approve to airdrop budget holder -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

perform()

- - -
-
- - -
- Perform approve by airdrop budget holder to contract -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

validateParams()

- - -
-
- - -
- Validate params -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_airdrop_management_approve.html b/docs/module-lib_airdrop_management_approve.html deleted file mode 100644 index a8a2ad2..0000000 --- a/docs/module-lib_airdrop_management_approve.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/airdrop_management/approve - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/airdrop_management/approve

-
- -
- -
- - -
-
- - -
This is a utility file which would be used for executing approve by airdrop budget holder.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
approve
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_airdrop_management_base-base.html b/docs/module-lib_airdrop_management_base-base.html deleted file mode 100644 index 3539446..0000000 --- a/docs/module-lib_airdrop_management_base-base.html +++ /dev/null @@ -1,1478 +0,0 @@ - - - - - - - OpenST Payments Class: base - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: base

-
- -
- -

- lib/airdrop_management/base~ - - base -

- - -
- - -
-
- - -
-
-

new base()

- - -
-
- - -
- Constructor to create object of base -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

approve(airdropContractAddress, airdropBudgetHolderPassphrase, gasPrice, chainId, options)

- - -
-
- - -
- approve airdrop amount to airdrop contract address -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
airdropContractAddress - - -Hex - - - - - airdrop contract address
airdropBudgetHolderPassphrase - - -string - - - - - passphrase
gasPrice - - -Hex - - - - - gasPrice
chainId - - -Number - - - - - chainId
options - - -Object - - - - - options e.g. {returnType: '', tag: ''}
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

batchAllocate(airdropContractAddress, transactionHash, airdropUsers, chainId)

- - -
-
- - -
- batch allocate to users -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
airdropContractAddress - - -Hex - - - - - airdrop contract address
transactionHash - - -Hex - - - - - transfer transaction hash
airdropUsers - - -Object - - - - - airdropUsers => {address: {airdropAmount:2, expiryTimestamp: timestamp}}
chainId - - -Number - - - - - chainId
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -response - - - -
-
- - - - - -
- - - -
-
-

getAirdropBalance(chainId, airdropContractAddress, userAddresses)

- - -
-
- - -
- Get user airdrop balance -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
chainId - - -Integer - - - - - chain Id
airdropContractAddress - - -Hex - - - - - airdrop contract address
userAddresses - - -Array - - - - - array of user addresses
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- - { - '0x934ebd34b2a4f16d4de16256df36a6013785557d': {totalAirdropAmount: '10000000000000000', totalAirdropUsedAmount: '10000000000000000', balanceAirdropAmount: '10000000000000000'}, - '0x934ebd34b2a4f16d4de16256df36a6013785557e': {totalAirdropAmount: '20000000000000000', totalAirdropUsedAmount: '20000000000000000', balanceAirdropAmount: '10000000000000000'} -} -
- - - -
-
- Type -
-
- -response - - - -
-
- - - - - -
- - - -
-
-

registerAirdrop(airdropContractAddress, chainId)

- - -
-
- - -
- Register Airdrop -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
airdropContractAddress - - -Hex - - - - - airdrop contract address
chainId - - -Number - - - - - chain Id
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

transfer(senderAddress, senderPassphrase, airdropContractAddress, amount, gasPrice, chainId, options)

- - -
-
- - -
- Transfer airdrop amount to airdrop budget holder -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -Hex - - - - - Sender Address
senderPassphrase - - -string - - - - - passphrase
airdropContractAddress - - -Hex - - - - - airdrop contract address
amount - - -BigNumber - - - - - amount to transfer
gasPrice - - -Hex - - - - - gasPrice
chainId - - -Number - - - - - chainId
options - - -Object - - - - - options e.g. {returnType: '', tag: ''}
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_airdrop_management_base.html b/docs/module-lib_airdrop_management_base.html deleted file mode 100644 index c16fc3a..0000000 --- a/docs/module-lib_airdrop_management_base.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/airdrop_management/base - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/airdrop_management/base

-
- -
- -
- - -
-
- - -
This is a utility file which would be used for executing all methods related to airdrop.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
base
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_airdrop_management_batch_allocator-batchAllocator.html b/docs/module-lib_airdrop_management_batch_allocator-batchAllocator.html deleted file mode 100644 index 8c5e4eb..0000000 --- a/docs/module-lib_airdrop_management_batch_allocator-batchAllocator.html +++ /dev/null @@ -1,881 +0,0 @@ - - - - - - - OpenST Payments Class: batchAllocator - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: batchAllocator

-
- -
- -

- lib/airdrop_management/batch_allocator~ - - batchAllocator -

- - -
- - -
-
- - -
-
-

new batchAllocator(airdropContractAddress, transactionHash, airdropUsers, chainId)

- - -
-
- - -
- Constructor to create object of batch allocator -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
airdropContractAddress - - -Hex - - - - - airdrop contract address
transactionHash - - -Hex - - - - - airdrop transfer transactio hash
airdropUsers - - -Object - - - - - {userAddress: {airdropAmount: inwei, expiryTimestamp: 0}}
chainId - - -Number - - - - - chain ID
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Object - - - -
-
- - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

allocateAirdropAmountToUsers()

- - -
-
- - -
- Allocate airdrop amount to users -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

clearCache()

- - -
-
- - -
- Clear all users cache -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -nil - - - -
-
- - - - - -
- - - -
-
-

perform()

- - -
-
- - -
- Perform batch allocation to airdrop users -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

validateParams()

- - -
-
- - -
- Validate params -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_airdrop_management_batch_allocator.html b/docs/module-lib_airdrop_management_batch_allocator.html deleted file mode 100644 index 306ca28..0000000 --- a/docs/module-lib_airdrop_management_batch_allocator.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/airdrop_management/batch_allocator - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/airdrop_management/batch_allocator

-
- -
- -
- - -
-
- - -
This is a utility file which would be used for allocating amount to airdrop users.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
batchAllocator
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_airdrop_management_register-register.html b/docs/module-lib_airdrop_management_register-register.html deleted file mode 100644 index 8b27abf..0000000 --- a/docs/module-lib_airdrop_management_register-register.html +++ /dev/null @@ -1,735 +0,0 @@ - - - - - - - OpenST Payments Class: register - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: register

-
- -
- -

- lib/airdrop_management/register~ - - register -

- - -
- - -
-
- - -
-
-

new register(airdropContractAddress, chainId)

- - -
-
- - -
- Constructor to create object of register -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
airdropContractAddress - - -Hex - - - - - airdrop contract address
chainId - - -Number - - - - - chain Id
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Object - - - -
-
- - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

perform()

- - -
-
- - -
- Perform method -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -responseHelper - - - -
-
- - - - - -
- - - -
-
-

runRegister()

- - -
-
- - -
- Run the register -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

validateParams()

- - -
-
- - -
- Validation of params -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_airdrop_management_register.html b/docs/module-lib_airdrop_management_register.html deleted file mode 100644 index 3cf66b5..0000000 --- a/docs/module-lib_airdrop_management_register.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/airdrop_management/register - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/airdrop_management/register

-
- -
- -
- - -
-
- - -
This class would be used for executing airdrop register.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
register
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_airdrop_management_transfer-transfer.html b/docs/module-lib_airdrop_management_transfer-transfer.html deleted file mode 100644 index 5b04245..0000000 --- a/docs/module-lib_airdrop_management_transfer-transfer.html +++ /dev/null @@ -1,855 +0,0 @@ - - - - - - - OpenST Payments Class: transfer - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: transfer

-
- -
- -

- lib/airdrop_management/transfer~ - - transfer -

- - -
- - -
-
- - -
-
-

new transfer(senderAddress, senderPassphrase, airdropContractAddress, amount, gasPrice, chainId, options)

- - -
-
- - -
- Constructor to create object of transfer -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -Hex - - - - - sender address
senderPassphrase - - -String - - - - - sender Passphrase
airdropContractAddress - - -Hex - - - - - airdrop contract address
amount - - -String - - - - - amount in wei
gasPrice - - -String - - - - - gas price
chainId - - -Number - - - - - chain Id
options - - -Object - - - - - chain Id
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Object - - - -
-
- - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

doTransfer()

- - -
-
- - -
- Transfer amount to airdrop budget holder -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

perform()

- - -
-
- - -
- Perform method -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

validateParams()

- - -
-
- - -
- validation of params -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_airdrop_management_transfer.html b/docs/module-lib_airdrop_management_transfer.html deleted file mode 100644 index dd6ef9a..0000000 --- a/docs/module-lib_airdrop_management_transfer.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/airdrop_management/transfer - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/airdrop_management/transfer

-
- -
- -
- - -
-
- - -
This is a utility file which would be used for executing transfer amount to airdrop budget holder.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
transfer
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_airdrop_management_user_balance-AdjustAirdropAmountKlass.html b/docs/module-lib_airdrop_management_user_balance-AdjustAirdropAmountKlass.html deleted file mode 100644 index 9435744..0000000 --- a/docs/module-lib_airdrop_management_user_balance-AdjustAirdropAmountKlass.html +++ /dev/null @@ -1,831 +0,0 @@ - - - - - - - OpenST Payments Class: AdjustAirdropAmountKlass - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: AdjustAirdropAmountKlass

-
- -
- -

- lib/airdrop_management/user_balance~ - - AdjustAirdropAmountKlass -

- - -
- - -
-
- - -
-
-

new AdjustAirdropAmountKlass(airdropContractAddress, userAddress, airdropAmountUsed)

- - -
-
- - -
- Constructor to create object of userBalance -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
airdropContractAddress - - -Hex - - - - - airdrop contract address
userAddress - - -Array - - - - - Array of user addressed
airdropAmountUsed - - -BigNumber - - - - - used airdrop amount
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Object - - - -
-
- - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

creditAirdropUsedAmount()

- - -
-
- - -
- Credit airdrop used amount. decreases airdrop_used_amount of user_airdrop_details table -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

debitAirdropUsedAmount()

- - -
-
- - -
- Debit airdrop used amount -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

rollbackCreditAirdropAdjustedAmount()

- - -
-
- - -
- Rollback credit airdrop used amount -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- - - -
-
-

rollbackDebitAirdropAdjustedAmount()

- - -
-
- - -
- Rollback debit airdrop used amount -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_airdrop_management_user_balance-AirdropUserBalanceKlass.html b/docs/module-lib_airdrop_management_user_balance-AirdropUserBalanceKlass.html deleted file mode 100644 index d15a2a1..0000000 --- a/docs/module-lib_airdrop_management_user_balance-AirdropUserBalanceKlass.html +++ /dev/null @@ -1,759 +0,0 @@ - - - - - - - OpenST Payments Class: AirdropUserBalanceKlass - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: AirdropUserBalanceKlass

-
- -
- -

- lib/airdrop_management/user_balance~ - - AirdropUserBalanceKlass -

- - -
- - -
-
- - -
-
-

new AirdropUserBalanceKlass(chainId, airdropContractAddress, userAddresses)

- - -
-
- - -
- Constructor to create object of userBalance -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
chainId - - -Number - - - - - chain Id
airdropContractAddress - - -Hex - - - - - airdrop contract address
userAddresses - - -Array - - - - - Array of user addressed
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Object - - - -
-
- - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

getUserAirdropBalance()

- - -
-
- - -
- Run the register -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

perform()

- - -
-
- - -
- Perform method -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -responseHelper - - - -
-
- - - - - -
- - - -
-
-

validateParams()

- - -
-
- - -
- Validation of params -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_airdrop_management_user_balance.html b/docs/module-lib_airdrop_management_user_balance.html deleted file mode 100644 index 22b8b0f..0000000 --- a/docs/module-lib_airdrop_management_user_balance.html +++ /dev/null @@ -1,407 +0,0 @@ - - - - - - - OpenST Payments Module: lib/airdrop_management/user_balance - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/airdrop_management/user_balance

-
- -
- -
- - -
-
- - -
This class would be used for calculating user airdrop balance.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
AdjustAirdropAmountKlass
-
- -
AirdropUserBalanceKlass
-
-
- - - - - - - - - - - - - -
- -
- - - - -

Module: lib/airdrop_management/user_balance

-
- -
- -
- - -
-
- - -
This class would be used for calculating user airdrop balance.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
AdjustAirdropAmountKlass
-
- -
AirdropUserBalanceKlass
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_cache_management_airdrop_cache-AirdropBalanceCache.html b/docs/module-lib_cache_management_airdrop_cache-AirdropBalanceCache.html deleted file mode 100644 index 9d21a17..0000000 --- a/docs/module-lib_cache_management_airdrop_cache-AirdropBalanceCache.html +++ /dev/null @@ -1,428 +0,0 @@ - - - - - - - OpenST Payments Class: AirdropBalanceCache - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: AirdropBalanceCache

-
- -
- -

- lib/cache_management/airdrop_cache~ - - AirdropBalanceCache -

- - -
- - -
-
- - -
-
-

new AirdropBalanceCache(chainId, airdropAddress)

- - -
-
- - -
- constructor -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
chainId - - -string - - - - - Chain id
airdropAddress - - -string - - - - - address of airdrop contract
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - -

Extends

- - - - -
    -
  • PricerCacheKlass
  • -
- - - - - - - - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_cache_management_airdrop_cache.html b/docs/module-lib_cache_management_airdrop_cache.html deleted file mode 100644 index 27af12a..0000000 --- a/docs/module-lib_cache_management_airdrop_cache.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/cache_management/airdrop_cache - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/cache_management/airdrop_cache

-
- -
- -
- - -
-
- - -
This is cache layer for airdrop balance related caching

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
AirdropBalanceCache
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_cache_management_balance_cache-BalanceCache.html b/docs/module-lib_cache_management_balance_cache-BalanceCache.html deleted file mode 100644 index 91fc800..0000000 --- a/docs/module-lib_cache_management_balance_cache-BalanceCache.html +++ /dev/null @@ -1,889 +0,0 @@ - - - - - - - OpenST Payments Class: BalanceCache - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: BalanceCache

-
- -
- -

- lib/cache_management/balance_cache~ - - BalanceCache -

- - -
- - -
-
- - -
-
-

new BalanceCache(chainId, brandedTokenAddress)

- - -
-
- - -
- constructor -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
chainId - - -string - - - - - Chain id
brandedTokenAddress - - -string - - - - - address of branded token contract
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

clearBalance(owner)

- - -
-
- - -
- Clear balance from cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
owner - - -string - - - - - address of user whose balance is to be set
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getBalance(owner)

- - -
-
- - -
- Get balance from cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
owner - - -string - - - - - address of user whose balance is to be found
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setBalance(owner, balance)

- - -
-
- - -
- Set balance to cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
owner - - -string - - - - - address of user whose balance is to be set
balance - - -BigNumber - - - - - balance of the user
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_cache_management_balance_cache.html b/docs/module-lib_cache_management_balance_cache.html deleted file mode 100644 index 0ea4d9c..0000000 --- a/docs/module-lib_cache_management_balance_cache.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/cache_management/balance_cache - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/cache_management/balance_cache

-
- -
- -
- - -
-
- - -
This is cache layer for balance related caching

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
BalanceCache
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_cache_management_pricer_cache-PricerCache.html b/docs/module-lib_cache_management_pricer_cache-PricerCache.html deleted file mode 100644 index 14a3808..0000000 --- a/docs/module-lib_cache_management_pricer_cache-PricerCache.html +++ /dev/null @@ -1,3891 +0,0 @@ - - - - - - - OpenST Payments Class: PricerCache - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: PricerCache

-
- -
- -

- lib/cache_management/pricer_cache~ - - PricerCache -

- - -
- - -
-
- - -
-
-

new PricerCache(chainId, contractAddress)

- - -
-
- - -
- constructor -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
chainId - - -string - - - - - Chain id
contractAddress - - -string - - - - - address of pricer/airdrop contract
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

clearAcceptedMargins(currency)

- - -
-
- - -
- reset accepted margin cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
currency - - -string - - - - - currency
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

clearBrandedTokenAddress(brandedTokenAddress)

- - -
-
- - -
- clear branded token address cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - branded token address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

clearCache(key)

- - -
-
- - -
- Clear cache for given key -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
key - - -string - - - - - cache key
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

clearConversionRate()

- - -
-
- - -
- Clear conversion rate from cache -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

clearConversionRateDecimals()

- - -
-
- - -
- Clear conversion rate decimals from cache -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

clearDecimals()

- - -
-
- - -
- clear decimals from cache -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

clearPriceOracles(currency, address)

- - -
-
- - -
- Clear price oracle address for given currency in cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
currency - - -string - - - - - currency
address - - -string - - - - - price oracle address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

clearPricePoint(address)

- - -
-
- - -
- Clear price point of price oracle from cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
address - - -string - - - - - price oracle address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getAcceptedMargins(currency)

- - -
-
- - -
- Get accepted margin -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
currency - - -string - - - - - currency
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getBrandedTokenAddress()

- - -
-
- - -
- Get branded token address for pricer -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getCacheKey(owner)

- - -
-
- - -
- Get conversion rate for pricer -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
owner - - -string - - - - - address of user whose balance is to be found
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getCacheValue(key)

- - -
-
- - -
- Get cached value -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
key - - -string - - - - - key
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getConversionRate()

- - -
-
- - -
- Get conversion rate for pricer -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getConversionRateDecimals()

- - -
-
- - -
- Get conversion rate decimals for pricer -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getDecimals()

- - -
-
- - -
- Get decimals for pricer -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getPriceOracles(currency)

- - -
-
- - -
- Get price oracle address for given currency from cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
currency - - -string - - - - - currency
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getPricePoint(address)

- - -
-
- - -
- Get price point of price oracle from cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
address - - -string - - - - - price oracle address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setAcceptedMargins(currency, margin)

- - -
-
- - -
- Set accepted margin -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
currency - - -string - - - - - currency
margin - - -BigNumber - - - - - accepted margin value
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setBrandedTokenAddress(brandedTokenAddress)

- - -
-
- - -
- Set branded token address for pricer -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - branded token address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setCacheValue(key, value)

- - -
-
- - -
- Set value in cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
key - - -string - - - - - key
value - - -string - - - - - value
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setConversionRate(conversionRate)

- - -
-
- - -
- Set conversion rate to cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
conversionRate - - -BigNumber - - - - - conversion rate of pricer/airdrop
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setConversionRateDecimals(conversionRateDecimals)

- - -
-
- - -
- Set conversion rate decimals to cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
conversionRateDecimals - - -BigNumber - - - - - conversion rate of pricer/airdrop
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setDecimals(conversionRateDecimals)

- - -
-
- - -
- Set decimals to cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
conversionRateDecimals - - -BigNumber - - - - - conversion rate of pricer/airdrop
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setPriceOracles(currency, address)

- - -
-
- - -
- Set price oracle address for given currency in cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
currency - - -string - - - - - currency
address - - -string - - - - - price oracle address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setPricePoint(pricePoint, address)

- - -
-
- - -
- Set price point of price oracle from cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
pricePoint - - -string - - - - - price oracle price point
address - - -string - - - - - price oracle address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_cache_management_pricer_cache.html b/docs/module-lib_cache_management_pricer_cache.html deleted file mode 100644 index d7ca325..0000000 --- a/docs/module-lib_cache_management_pricer_cache.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/cache_management/pricer_cache - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/cache_management/pricer_cache

-
- -
- -
- - -
-
- - -
This is cache layer for pricer balance related caching

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
PricerCache
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_airdrop-Airdrop.html b/docs/module-lib_contract_interact_airdrop-Airdrop.html deleted file mode 100644 index fa5ff26..0000000 --- a/docs/module-lib_contract_interact_airdrop-Airdrop.html +++ /dev/null @@ -1,1075 +0,0 @@ - - - - - - - OpenST Payments Class: Airdrop - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: Airdrop

-
- -
- -

- lib/contract_interact/airdrop~ - - Airdrop -

- - -
- - -
-
- - -
-
-

new Airdrop(airdropContractAddress, chainId)

- - -
-
- - - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
airdropContractAddress - - -string - - - - - airdrop contract address
chainId - - -string - - - - - chain ID
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

airdropBudgetHolder()

- - -
-
- - -
- Get airdrop budget holder address of airdrop -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getAirdropBudgetHolderFromContract()

- - -
-
- - -
- Get airdrop budget holder address of airdrop from contract -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getWorkers()

- - -
-
- - -
- Get worker contract address -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

pay(senderWorkerAddress, senderWorkerPassphrase, beneficiaryAddress, transferAmount, commissionBeneficiaryAddress, commissionAmount, currency, intendedPricePoint, spender, options)

- - -
-
- - -
- Pay -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderWorkerAddress - - -string - - - - - address of worker
senderWorkerPassphrase - - -string - - - - - passphrase of worker
beneficiaryAddress - - -string - - - - - address of beneficiary account
transferAmount - - -BigNumber - - - - - transfer amount (in wei)
commissionBeneficiaryAddress - - -string - - - - - address of commision beneficiary account
commissionAmount - - -BigNumber - - - - - commission amount (in wei)
currency - - -string - - - - - quote currency
intendedPricePoint - - -BigNumber - - - - - price point at which the pay is intended (in wei)
spender - - -string - - - - - User address
options - - -object - - - - - for params like returnType, tag.
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_airdrop.html b/docs/module-lib_contract_interact_airdrop.html deleted file mode 100644 index caa9b54..0000000 --- a/docs/module-lib_contract_interact_airdrop.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/contract_interact/airdrop - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/contract_interact/airdrop

-
- -
- -
- - -
-
- - -
This is a utility file which would be used for executing all methods on Pricer.sol contract.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
Airdrop
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_branded_token-BrandedToken.html b/docs/module-lib_contract_interact_branded_token-BrandedToken.html deleted file mode 100644 index c54bcb8..0000000 --- a/docs/module-lib_contract_interact_branded_token-BrandedToken.html +++ /dev/null @@ -1,1953 +0,0 @@ - - - - - - - OpenST Payments Class: BrandedToken - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: BrandedToken

-
- -
- -

- lib/contract_interact/branded_token~ - - BrandedToken -

- - -
- - -
-
- - -
-
-

new BrandedToken(brandedTokenAddress, chainId)

- - -
-
- - -
- Constructor to create object of BrandedToken -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - Branded token address
chainId - - -number - - - - - chainId
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - -

Members

- -
- -
-
-

balanceCache

- - -
-
- -
- balance cache -
- - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - -
- - - -
-
-

brandedTokenAddress

- - -
-
- -
- branded token address -
- - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - -
- - - -
-
-

chainId

- - -
-
- -
- chain id -
- - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - -
- -
- - - -

Methods

- -
- -
-
-

approveByBudgetHolder(airdropBudgetHolderAddress, airdropBudgetHolderPassphrase, airdropContractAddress, amount, gasPrice, options)

- - -
-
- - -
- Approve amount to budget holder -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
airdropBudgetHolderAddress - - -string - - - - - address of airdropBudgetHolder
airdropBudgetHolderPassphrase - - -string - - - - - Passphrase of airdropBudgetHolder
airdropContractAddress - - -string - - - - - airdrop contract address
amount - - -BigNumber - - - - - amount in wei
gasPrice - - -BigNumber - - - - - gas price
options - - -object - - - - - for params like returnType, tag.
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

creditBalance(owner, bigAmount)

- - -
-
- - -
- Credit balance in cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
owner - - -string - - - - - Account address
bigAmount - - -BigNumber - - - - - amount to be credited
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

debitBalance(owner, bigAmount)

- - -
-
- - -
- Debit balance in cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
owner - - -string - - - - - Account address
bigAmount - - -BigNumber - - - - - amount to be debited
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getBalanceFromContract(owner)

- - -
-
- - -
- Fetch Balance For a given address from contract -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
owner - - -string - - - - - address for which balance is to be fetched
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getBalanceOf(owner)

- - -
-
- - -
- Fetch Balance For a given address -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
owner - - -string - - - - - address for which balance is to be fetched
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setBalanceInCache(owner, bigAmount)

- - -
-
- - -
- Set balance in cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
owner - - -string - - - - - Account address
bigAmount - - -BigNumber - - - - - amount to be set
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

transferToAirdropBudgetHolder(senderAddress, senderPassphrase, airdropBudgetHolderAddress, amount, gasPrice, options)

- - -
-
- - -
- Transfer amount to budget holder -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
senderPassphrase - - -string - - - - - passphrase of sender
airdropBudgetHolderAddress - - -string - - - - - recipient address
amount - - -BigNumber - - - - - amount in wei
gasPrice - - -BigNumber - - - - - gas price
options - - -object - - - - - for params like returnType, tag.
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_branded_token.html b/docs/module-lib_contract_interact_branded_token.html deleted file mode 100644 index dfe6183..0000000 --- a/docs/module-lib_contract_interact_branded_token.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/contract_interact/branded_token - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/contract_interact/branded_token

-
- -
- -
- - -
-
- - -
This is a utility file which would be used for executing all methods on EIP20Token contract.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
BrandedToken
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_helper-ContractInteractHelper.html b/docs/module-lib_contract_interact_helper-ContractInteractHelper.html deleted file mode 100644 index fa1ed72..0000000 --- a/docs/module-lib_contract_interact_helper-ContractInteractHelper.html +++ /dev/null @@ -1,4009 +0,0 @@ - - - - - - - OpenST Payments Class: ContractInteractHelper - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: ContractInteractHelper

-
- -
- -

- lib/contract_interact/helper~ - - ContractInteractHelper -

- - -
- - -
-
- - -
-
-

new ContractInteractHelper()

- - -
-
- - -
- contract interact helper constructor -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

call(web3RpcProvider, currContractAddr, encodeABI [, options] [, transactionOutputs])

- - -
-
- - -
- Call methods (execute methods which DO NOT modify state of contracts) -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeArgumentDescription
web3RpcProvider - - -object - - - - - - - - - - - It could be value chain or utility chain provider
currContractAddr - - -String - - - - - - - - - - - current contract address
encodeABI - - -Object - - - - - - - - - - - encoded method ABI data
options - - -Object - - - - - - - <optional>
- - - - - -
optional params
transactionOutputs - - -Object - - - - - - - <optional>
- - - - - -
optional transactionOutputs
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise - - - -
-
- - - - - -
- - - -
-
-

generateManagedKeyPassphrase()

- - -
-
- - -
- Stub method to generate managed key passphrase -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -String - - - -
-
- - - - - -
- - - -
-
-

getNotificationData(topics, publisher, method, contractName, contractAddress, web3RpcProvider, options)

- - -
-
- - -
- get notification event formatted data -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
topics - - -array - - - - - topics where the event will be published
publisher - - -String - - - - - publisher name
method - - -String - - - - - method name
contractName - - -String - - - - - name of contract
contractAddress - - -String - - - - - address of contract
web3RpcProvider - - -Object - - - - - address of contract
options - - -Object - - - - - options
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

getTransactionOutputs(transactionObject)

- - -
-
- - -
- get outputs of a given transaction -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
transactionObject - - -object - - - - - transactionObject is returned from call method.
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -array - - - -
-
- - - - - -
- - - -
-
-

getTransactionReceiptFromTrasactionHash(web3RpcProvider, transactionHash)

- - -
-
- - -
- Get transaction receipt -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
web3RpcProvider - - -Web3 - - - - - It could be value chain or utility chain provider
transactionHash - - -String - - - - - transaction hash
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

isDecimal(num)

- - -
-
- - -
- check if return type is true/false -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
num - - -Number - - - - - Number
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- Note - Don't use for BigNumbers -
- - - -
-
- Type -
-
- -boolean - - - -
-
- - - - - -
- - - -
-
-

isValidCurrency(currency, allow_blank)

- - -
-
- - -
- valid currency -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
currency - - -string - - - - - currency
allow_blank - - -bool - - - - - true / false, '' if allow_blank is true
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- - true / false -
- - - -
-
- Type -
-
- -Bool - - - -
-
- - - - - -
- - - -
-
-

performSend(Object, string, senderAddr)

- - -
-
- - -
- Perform send -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
Object - - -params - - - - - parmaters
string - - -returnType - - - - - return type
senderAddr - - -String - - - - - address of transaction's sender senderAddr
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

safeSend(web3RpcProvider, currContractAddr, senderName, encodeABI [, txOptions] [, addressToNameMap])

- - -
-
- - -
- Safe Send a transaction (this internally waits for transaction to be mined) -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeArgumentDescription
web3RpcProvider - - -Web3 - - - - - - - - - - - It could be value chain or utility chain provider
currContractAddr - - -String - - - - - - - - - - - current contract address
senderName - - -String - - - - - - - - - - - name of transaction's sender
encodeABI - - -Object - - - - - - - - - - - encoded method ABI data
txOptions - - -Object - - - - - - - <optional>
- - - - - -
optional txOptions
addressToNameMap - - -Object - - - - - - - <optional>
- - - - - -
optional addressToNameMap
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

safeSendFromAddr(web3RpcProvider, currContractAddr, senderAddr, senderPassphrase, encodeABI [, txOptions] [, addressToNameMap])

- - -
-
- - -
- Safe Send a transaction (this internally waits for transaction to be mined) -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeArgumentDescription
web3RpcProvider - - -Web3 - - - - - - - - - - - It could be value chain or utility chain provider
currContractAddr - - -String - - - - - - - - - - - current contract address
senderAddr - - -String - - - - - - - - - - - address of transaction's sender senderAddr
senderPassphrase - - -String - - - - - - - - - - - passphrase of
encodeABI - - -Object - - - - - - - - - - - encoded method ABI data
txOptions - - -Object - - - - - - - <optional>
- - - - - -
optional txOptions
addressToNameMap - - -Object - - - - - - - <optional>
- - - - - -
optional addressToNameMap
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

send(web3RpcProvider, currContractAddr, encodeABI [, options] [, transactionOutputs])

- - -
-
- - -
- Send methods (execute methods which modify state of a contracts) -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeArgumentDescription
web3RpcProvider - - -Web3 - - - - - - - - - - - It could be value chain or utility chain provider
currContractAddr - - -String - - - - - - - - - - - current contract address
encodeABI - - -Object - - - - - - - - - - - encoded method ABI data
options - - -Object - - - - - - - <optional>
- - - - - -
optional params
transactionOutputs - - -Object - - - - - - - <optional>
- - - - - -
optional transactionOutputs
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise - - - -
-
- - - - - -
- - - -
-
-

toAddress(web3RpcProvider, result)

- - -
-
- - -
- Decode result and typecast it to an Address -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
web3RpcProvider - - -Web3 - - - - - It could be value chain or utility chain provider
result - - -String - - - - - current contract address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

toNumber(web3RpcProvider, result)

- - -
-
- - -
- Decode result and typecast it to a Number -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
web3RpcProvider - - -Web3 - - - - - It could be value chain or utility chain provider
result - - -String - - - - - current contract address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

toString(web3RpcProvider, result)

- - -
-
- - -
- Decode result and typecast it to a String -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
web3RpcProvider - - -Web3 - - - - - It could be value chain or utility chain provider
result - - -String - - - - - current contract address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

validateAirdropPayParams(senderAddress, beneficiaryAddress, transferAmount, commissionBeneficiaryAddress, commissionAmount, currency, intendedPricePoint, gasPrice, user)

- - -
-
- - -
- Validate Airdrop pay params -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
beneficiaryAddress - - -string - - - - - address of beneficiary account
transferAmount - - -BigNumber - - - - - transfer amount (in wei)
commissionBeneficiaryAddress - - -string - - - - - address of commision beneficiary account
commissionAmount - - -BigNumber - - - - - commission amount (in wei)
currency - - -string - - - - - quote currency
intendedPricePoint - - -BigNumber - - - - - price point at which the pay is intended (in wei)
gasPrice - - -BigNumber - - - - - gas price
user - - -Hex - - - - - User address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

validatePayParams(senderAddress, beneficiaryAddress, transferAmount, commissionBeneficiaryAddress, commissionAmount, currency, intendedPricePoint, gasPrice)

- - -
-
- - -
- Validate Airdrop params -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
beneficiaryAddress - - -string - - - - - address of beneficiary account
transferAmount - - -BigNumber - - - - - transfer amount (in wei)
commissionBeneficiaryAddress - - -string - - - - - address of commision beneficiary account
commissionAmount - - -BigNumber - - - - - commission amount (in wei)
currency - - -string - - - - - quote currency
intendedPricePoint - - -BigNumber - - - - - price point at which the pay is intended (in wei)
gasPrice - - -BigNumber - - - - - gas price
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_helper.html b/docs/module-lib_contract_interact_helper.html deleted file mode 100644 index 036f913..0000000 --- a/docs/module-lib_contract_interact_helper.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/contract_interact/helper - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/contract_interact/helper

-
- -
- -
- - -
-
- - -
This is utility class for contract interacts

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
ContractInteractHelper
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_ops_managed_contract-OpsManagedContract.html b/docs/module-lib_contract_interact_ops_managed_contract-OpsManagedContract.html deleted file mode 100644 index 8c2f0cb..0000000 --- a/docs/module-lib_contract_interact_ops_managed_contract-OpsManagedContract.html +++ /dev/null @@ -1,774 +0,0 @@ - - - - - - - OpenST Payments Class: OpsManagedContract - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: OpsManagedContract

-
- -
- -

- lib/contract_interact/ops_managed_contract~ - - OpsManagedContract -

- - -
- - -
-
- - -
-
-

new OpsManagedContract(contractAddress, defaultGasPrice, chainId)

- - -
-
- - -
- Ops managed contract interact constructor -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
contractAddress - - -string - - - - - address where Contract has been deployed
defaultGasPrice - - -string - - - - - default Gas Price
chainId - - -number - - - - - chain id
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - -

Extends

- - - - -
    -
  • OwnedContract
  • -
- - - - - - - - - - - - - - - -

Methods

- -
- -
-
-

getOpsAddress()

- - -
-
- - -
- Get currContract's Ops Address -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setOpsAddress(senderAddress, senderPassphrase, opsAddress, options)

- - -
-
- - -
- Set currContract's Ops Address -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - Sender Address
senderPassphrase - - -String - - - - - Sender Passphrase
opsAddress - - -String - - - - - address which is to be made Ops Address of currContract
options - - -Object - - - - - options for this transaction
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_ops_managed_contract.html b/docs/module-lib_contract_interact_ops_managed_contract.html deleted file mode 100644 index 9c789ed..0000000 --- a/docs/module-lib_contract_interact_ops_managed_contract.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/contract_interact/ops_managed_contract - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/contract_interact/ops_managed_contract

-
- -
- -
- - -
-
- - -
This is a utility file which would be used for executing all methods on OpsManaged Contract.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
OpsManagedContract
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_owned_contract-OwnedContract.html b/docs/module-lib_contract_interact_owned_contract-OwnedContract.html deleted file mode 100644 index 0d90df6..0000000 --- a/docs/module-lib_contract_interact_owned_contract-OwnedContract.html +++ /dev/null @@ -1,763 +0,0 @@ - - - - - - - OpenST Payments Class: OwnedContract - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: OwnedContract

-
- -
- -

- lib/contract_interact/owned_contract~ - - OwnedContract -

- - -
- - -
-
- - -
-
-

new OwnedContract(contractAddress, web3RpcProvider, currContract, defaultGasPrice)

- - -
-
- - -
- Owned contract interact constructor -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
contractAddress - - -String - - - - - address where Contract has been deployed
web3RpcProvider - - -String - - - - - webRpc provider of network where currContract has been deployed
currContract - - -String - - - - - Contract Instance
defaultGasPrice - - -String - - - - - default Gas Price
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

getOwner()

- - -
-
- - -
- Get address of Owner of currContract -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<string> - - - -
-
- - - - - -
- - - -
-
-

initiateOwnerShipTransfer(senderName, proposedOwner, customOptions)

- - -
-
- - -
- Initiate Ownership of currContract -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderName - - -string - - - - - Sender of this Transaction
proposedOwner - - -string - - - - - address to which ownership needs to be transferred
customOptions - - -object - - - - - custom params of this transaction
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_owned_contract.html b/docs/module-lib_contract_interact_owned_contract.html deleted file mode 100644 index 29efa5c..0000000 --- a/docs/module-lib_contract_interact_owned_contract.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/contract_interact/owned_contract - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/contract_interact/owned_contract

-
- -
- -
- - -
-
- - -
This is a utility file which would be used for executing all methods on Owned Contract.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
OwnedContract
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_pricer-MockToken.html b/docs/module-lib_contract_interact_pricer-MockToken.html deleted file mode 100644 index 9cc8086..0000000 --- a/docs/module-lib_contract_interact_pricer-MockToken.html +++ /dev/null @@ -1,1199 +0,0 @@ - - - - - - - OpenST Payments Class: MockToken - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: MockToken

-
- -
- -

- lib/contract_interact/pricer~ - - MockToken -

- - -
- - -
-
- - -
-
-

new MockToken()

- - -
-
- - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

approve(senderAddr, senderPassphrase, spenderAddress, value, gasPrice)

- - -
-
- - -
- Approve -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddr - - -string - - - - - address of sender
senderPassphrase - - -string - - - - - passphrase of sender
spenderAddress - - -string - - - - - address which will be approved for spending
value - - -BigNumber - - - - - amount which is being approved (in wei)
gasPrice - - -BigNumber - - - - - gas price
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

balanceOf(ownerAddress)

- - -
-
- - -
- Get balance of address -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
ownerAddress - - -String - - - - - address for which balance is to be fetched
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

setBalance(senderAddr, senderPassphrase, ownerAddress, value, gasPrice)

- - -
-
- - -
- Set balance -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddr - - -string - - - - - address of user who is sending amount
senderPassphrase - - -string - - - - - sender address passphrase
ownerAddress - - -string - - - - - address for which balance is to be set
value - - -BigNumber - - - - - amount which is being transferred (in wei)
gasPrice - - -BigNumber - - - - - gas price
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

setConversionRate(senderAddr, senderPassphrase, conversionRate, gasPrice)

- - -
-
- - -
- Set conversion rate -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddr - - -string - - - - - address of sender
senderPassphrase - - -string - - - - - passphrase of sender
conversionRate - - -number - - - - - conversion rate of branded token
gasPrice - - -BigNumber - - - - - gas price
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_pricer-Pricer.html b/docs/module-lib_contract_interact_pricer-Pricer.html deleted file mode 100644 index 77e33ed..0000000 --- a/docs/module-lib_contract_interact_pricer-Pricer.html +++ /dev/null @@ -1,5207 +0,0 @@ - - - - - - - OpenST Payments Class: Pricer - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: Pricer

-
- -
- -

- lib/contract_interact/pricer~ - - Pricer -

- - -
- - -
-
- - -
-
-

new Pricer(pricerAddress, chainId)

- - -
-
- - - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
pricerAddress - - -string - - - - - Pricer contract address
chainId - - -string - - - - - chain ID
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

acceptedMargins(currency)

- - -
-
- - -
- Get acceptable margin for the given currency -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
currency - - -string - - - - - quote currency
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

baseCurrency()

- - -
-
- - -
- Get base currency of pricer -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

brandedToken()

- - -
-
- - -
- Get branded token address of pricer from cache, if not found in cache get from contract -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

conversionRate()

- - -
-
- - -
- Get conversion rate of pricer -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

conversionRateDecimals()

- - -
-
- - -
- Get conversion rate decimals of pricer -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

decimals()

- - -
-
- - -
- Get decimal of pricer -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getAcceptedMarginsFromContract(currency)

- - -
-
- - -
- Get acceptable margin for the given currency from contract -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
currency - - -string - - - - - quote currency
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getBalanceOf(owner)

- - -
-
- - -
- Get balance of the account -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
owner - - -string - - - - - account address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- 10^18 -
- - - -
-
- Type -
-
- -BigNumer - - - -
-
- - - - - -
- - - -
-
-

getBrandedTokenAddressFromContract()

- - -
-
- - -
- Get branded token address of pricer from contract -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getConversionRateDecimalsFromContract()

- - -
-
- - -
- Get conversion rate decimals of pricer from contract -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getConversionRateFromContract()

- - -
-
- - -
- Get conversion rate of pricer from contract -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getDecimalsFromContract()

- - -
-
- - -
- Get decimal of pricer from contract -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getEstimatedTotalAmount(transferAmount, commissionAmount, intendedPricePoint)

- - -
-
- - -
- Get estimated total amount -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
transferAmount - - -BigNumber - - - - - Transfer amount
commissionAmount - - -BigNumber - - - - - Commission amount
intendedPricePoint - - -BigNumber - - - - - Intended price point
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -BigNumber - - - -
-
- - - - - -
- - - -
-
-

getPriceOraclesFromContract(currency)

- - -
-
- - -
- Get address of price oracle for the given currency from contract -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
currency - - -string - - - - - quote currency
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getPricePoint(currency)

- - -
-
- - -
- Get current price point from the price oracle for the give currency -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
currency - - -string - - - - - quote currency
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getPricePointAndCalculatedAmounts(transferAmount, commissionAmount, currency)

- - -
-
- - -
- Get current price point and calculated token amounts -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
transferAmount - - -BigNumber - - - - - transfer amount (in wei)
commissionAmount - - -BigNumber - - - - - commision amount (in wei)
currency - - -string - - - - - quote currency
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getPricePointFromContract(currency)

- - -
-
- - -
- Get current price point from the price oracle for the give currency from contract -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
currency - - -string - - - - - quote currency
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getTxReceipt(transactionHash)

- - -
-
- - -
- Get transaction receipt from transaction hash -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
transactionHash - - -string - - - - - transaction hash
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- 10^18 -
- - - -
-
- Type -
-
- -BigNumer - - - -
-
- - - - - -
- - - -
-
-

pay(senderAddress, senderPassphrase, beneficiaryAddress, transferAmount, commissionBeneficiaryAddress, commissionAmount, currency, intendedPricePoint, gasPrice, options)

- - -
-
- - -
- Pay -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
senderPassphrase - - -string - - - - - passphrase of sender
beneficiaryAddress - - -string - - - - - address of beneficiary account
transferAmount - - -BigNumber - - - - - transfer amount (in wei)
commissionBeneficiaryAddress - - -string - - - - - address of commision beneficiary account
commissionAmount - - -BigNumber - - - - - commission amount (in wei)
currency - - -string - - - - - quote currency
intendedPricePoint - - -BigNumber - - - - - price point at which the pay is intended (in wei)
gasPrice - - -BigNumber - - - - - gas price
options - - -object - - - - - for params like returnType, tag.
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

priceOracles(currency)

- - -
-
- - -
- Get address of price oracle for the given currency -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
currency - - -string - - - - - quote currency
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setAcceptedMargin(senderAddress, senderPassphrase, currency, acceptedMargin, gasPrice, options)

- - -
-
- - -
- Set or update the acceptable margin range for a given currency -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
senderPassphrase - - -string - - - - - passphrase of sender
currency - - -string - - - - - quote currency
acceptedMargin - - -BigNumber - - - - - accepted margin for the given currency (in wei)
gasPrice - - -BigNumber - - - - - gas price
options - - -object - - - - - for params like returnType, tag.
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setAddressToNameMap()

- - -
-
- - -
- set address to name map -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setPriceOracle(senderAddress, senderPassphrase, currency, address, gasPrice, options)

- - -
-
- - -
- Set or updates the price oracle address for a given currency -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
senderPassphrase - - -string - - - - - passphrase of sender
currency - - -string - - - - - quote currency
address - - -string - - - - - address of price pracle
gasPrice - - -BigNumber - - - - - gas price
options - - -object - - - - - for params like returnType, tag.
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setTokenObj()

- - -
-
- - -
- set token object -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

toWei(value)

- - -
-
- - -
- Convert value in wei -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
value - - -BigNumber - - - - - amount in decimal
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- 10^18 -
- - - -
-
- Type -
-
- -BigNumer - - - -
-
- - - - - -
- - - -
-
-

unsetPriceOracle(senderAddress, senderPassphrase, currency, gasPrice, options)

- - -
-
- - -
- Remove the price oracle address for a given currency -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
senderPassphrase - - -string - - - - - passphrase of sender
currency - - -string - - - - - quote currency
gasPrice - - -BigNumber - - - - - gas price
options - - -object - - - - - for params like returnType, tag.
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

validateSetAcceptedMarginParams(senderAddress, currency, acceptedMargin, gasPrice)

- - -
-
- - -
- Validate set accepted margin params parameters -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
currency - - -string - - - - - quote currency
acceptedMargin - - -BigNumber - - - - - accepted margin for the given currency (in wei)
gasPrice - - -BigNumber - - - - - gas price
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -result - - - -
-
- - - - - -
- - - -
-
-

validateSetPriceOracleParams(senderAddress, currency, address, gasPrice)

- - -
-
- - -
- Validate set price oracle parameters -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
currency - - -string - - - - - quote currency
address - - -string - - - - - address of price pracle
gasPrice - - -BigNumber - - - - - gas price
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -result - - - -
-
- - - - - -
- - - -
-
-

validateUnsetPriceOracleParams(senderAddress, currency, gasPrice)

- - -
-
- - -
- Validate unset price oracle parameters -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
currency - - -string - - - - - quote currency
gasPrice - - -BigNumber - - - - - gas price
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

verifyReceiptAndUpdateAcceptedMarginCache(acceptedMargin, currency, receipt)

- - -
-
- - -
- Verify receipt and update accepted margin in cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
acceptedMargin - - -BigNumber - - - - - accepted margin for the given currency (in wei)
currency - - -string - - - - - quote currency
receipt - - -Object - - - - - transaction receipt
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_pricer.html b/docs/module-lib_contract_interact_pricer.html deleted file mode 100644 index a4199a3..0000000 --- a/docs/module-lib_contract_interact_pricer.html +++ /dev/null @@ -1,407 +0,0 @@ - - - - - - - OpenST Payments Module: lib/contract_interact/pricer - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/contract_interact/pricer

-
- -
- -
- - -
-
- - -
This is a utility file which would be used for executing all methods on Pricer contract.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
MockToken
-
- -
Pricer
-
-
- - - - - - - - - - - - - -
- -
- - - - -

Module: lib/contract_interact/pricer

-
- -
- -
- - -
-
- - -
This is a utility file which would be used for executing all methods on Pricer contract.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
MockToken
-
- -
Pricer
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_workers-Workers.html b/docs/module-lib_contract_interact_workers-Workers.html deleted file mode 100644 index 7655d48..0000000 --- a/docs/module-lib_contract_interact_workers-Workers.html +++ /dev/null @@ -1,2038 +0,0 @@ - - - - - - - OpenST Payments Class: Workers - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: Workers

-
- -
- -

- lib/contract_interact/workers~ - - Workers -

- - -
- - -
-
- - -
-
-

new Workers(workerAddress, chainId)

- - -
-
- - -
- Workers contract interact class constructor -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
workerAddress - - -string - - - - - address of worker (external address)
chainId - - -number - - - - - chain id
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

_validateRemoveParams(senderAddress, gasPrice)

- - -
-
- - -
- Validate Remove (selfdestruct) params -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
gasPrice - - -BigNumber - - - - - gas price
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -result - - - -
-
- - - - - -
- - - -
-
-

_validateRemoveWorkerParams(senderAddress, workerAddress, gasPrice)

- - -
-
- - -
- Validate remove worker params -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
workerAddress - - -string - - - - - worker address
gasPrice - - -BigNumber - - - - - gas price
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -result - - - -
-
- - - - - -
- - - -
-
-

_validateSetWorkersParams(senderAddress, workerAddress, deactivationHeight, gasPrice)

- - -
-
- - -
- Validate set workers params -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
workerAddress - - -string - - - - - worker address
deactivationHeight - - -number - - - - - block number till which the worker is valid
gasPrice - - -BigNumber - - - - - gas price
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -result - - - -
-
- - - - - -
- - - -
-
-

getTxReceipt(transactionHash)

- - -
-
- - -
- Get transaction receipt from transaction hash -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
transactionHash - - -string - - - - - transaction hash -TODO - this can be moved to a util class
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

isWorker(workerAddress)

- - -
-
- - -
- Check if the given worker address is valid or not -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
workerAddress - - -string - - - - - worker address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

remove(senderAddr, senderPassphrase, gasPrice, object)

- - -
-
- - -
- Remove (selfdestruct) -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddr - - -string - - - - - address of sender
senderPassphrase - - -string - - - - - passphrase of sender
gasPrice - - -BigNumber - - - - - gas price
object - - -options - - - - - for params like returnType, tag.
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise - - - -
-
- - - - - -
- - - -
-
-

removeWorker(senderAddress, senderPassphrase, workerAddress, gasPrice, options)

- - -
-
- - -
- Remove worker -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
senderPassphrase - - -string - - - - - passphrase of sender
workerAddress - - -string - - - - - worker address
gasPrice - - -BigNumber - - - - - gas price
options - - -object - - - - - for params like returnType, tag.
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

setWorker(senderAddress, senderPassphrase, workerAddress, deactivationHeight, gasPrice, options)

- - -
-
- - -
- Set or update the worker -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
senderAddress - - -string - - - - - address of sender
senderPassphrase - - -string - - - - - passphrase of sender
workerAddress - - -string - - - - - worker address
deactivationHeight - - -number - - - - - block number till which the worker is valid
gasPrice - - -BigNumber - - - - - gas price
options - - -object - - - - - for params like returnType, tag.
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_contract_interact_workers.html b/docs/module-lib_contract_interact_workers.html deleted file mode 100644 index 3aec85a..0000000 --- a/docs/module-lib_contract_interact_workers.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/contract_interact/workers - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/contract_interact/workers

-
- -
- -
- - -
-
- - -
This is a utility file which would be used for executing all methods on Workers contract.

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
Workers
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_deployer-Deploy.html b/docs/module-lib_deployer-Deploy.html deleted file mode 100644 index 99eda48..0000000 --- a/docs/module-lib_deployer-Deploy.html +++ /dev/null @@ -1,894 +0,0 @@ - - - - - - - OpenST Payments Class: Deploy - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: Deploy

-
- -
- -

- lib/deployer~ - - Deploy -

- - -
- - -
-
- - -
-
-

new Deploy()

- - -
-
- - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

deploy(contractName, constructorArgs, gasPrice, options)

- - -
-
- - -
- Deploy contract -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
contractName - - -string - - - - - Contract name - pricer / airdrop / workers
constructorArgs - - -Array - - - - - Contract constructor params
gasPrice - - -BigNumber - - - - - Gas price
options - - -object - - - - - for params like returnType, tag.
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -response - - - -
-
- - - - - -
- - - -
-
-

validateDeployParams(contractName, gasPrice)

- - -
-
- - -
- Validate deploy parameters -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
contractName - - -string - - - - - Contract name
gasPrice - - -BigNumber - - - - - Gas price
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -response - - - -
-
- - - - - -
- - - -
-
-

writeContractAddressToFile(fileName, contractAddress)

- - -
-
- - -
- Write contract address to file based on parameter -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
fileName - - -String - - - - - file name
contractAddress - - -Hex - - - - - contract Address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_deployer.html b/docs/module-lib_deployer.html deleted file mode 100644 index 919e3b6..0000000 --- a/docs/module-lib_deployer.html +++ /dev/null @@ -1,316 +0,0 @@ - - - - - - - OpenST Payments Module: lib/deployer - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/deployer

-
- -
- -
- - -
-
- - -
This is script for deploying any contract.

- - Prerequisite: -
    -
  1. Deployer Address
  2. -
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
Deploy
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_query_builder_mysql-MySQLQueryBuilderKlass.html b/docs/module-lib_query_builder_mysql-MySQLQueryBuilderKlass.html deleted file mode 100644 index d06f573..0000000 --- a/docs/module-lib_query_builder_mysql-MySQLQueryBuilderKlass.html +++ /dev/null @@ -1,2662 +0,0 @@ - - - - - - - OpenST Payments Class: MySQLQueryBuilderKlass - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: MySQLQueryBuilderKlass

-
- -
- -

- lib/query_builder/mysql~ - - MySQLQueryBuilderKlass -

- - -
- - -
-
- - -
-
-

new MySQLQueryBuilderKlass(params)

- - -
-
- - -
- MySQL query builder constructor -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
params - - -Object - - - - - - -
Properties
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeArgumentDescription
table_name - - -String - - - - - - - <optional>
- - - - - -
MySQL table name for which query need to be build
- -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

<private> _generateDelete()

- - -
-
- - -
- Generate the final DELETE statement -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - - -
-
-

<private> _generateInsert()

- - -
-
- - -
- Generate the final INSERT statement -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - - -
-
-

<private> _generateSelect()

- - -
-
- - -
- Generate the final SELECT statement -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - - -
-
-

<private> _generateUpdate()

- - -
-
- - -
- Generate the final UPDATE statement -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - - -
-
-

delete()

- - -
-
- - -
- Delete row from table - -Example 1: -delete() -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- oThis -
- - - -
-
- Type -
-
- -object.<self> - - - -
-
- - - - - -
- - - -
-
-

generate()

- - -
-
- - -
- Generate final query supported by mysql node module -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -object.<response> - - - -
-
- - - - - -
- - - -
-
-

group_by()

- - -
-
- - -
- List of fields to be grouped by from table. If called multiple times, group by conditions will be joined by COMMA. - -Possible data types: -* Array - list of field names will be joined by comma -* String - list of field names will be used as it is - -Example 1: -group_by(['name', 'created_at']) - -Example 2: -group_by('name, created_at') -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- oThis -
- - - -
-
- Type -
-
- -object.<self> - - - -
-
- - - - - -
- - - -
-
-

having()

- - -
-
- - -
- List of fields for having clause. If called multiple times, having conditions will be joined by AND. - -Possible data types: -* Array - index 0 should have the having sub query and other indexes should have the valued to be replaced in sub query -* String - where sub query, used as it is. - -Example 1: Where in array format -having(['MIN(`salary`) < ?', 10]) - -Example 2: condition in string. Will be used as it is -having('MIN(`salary`) < 10') -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- oThis -
- - - -
-
- Type -
-
- -object.<self> - - - -
-
- - - - - -
- - - -
-
-

insert((object), (object), (object))

- - -
-
- - -
- Insert single record in table. Method can't be called twice on same object - -Example 1: Insert in object format. -insert({name: 'ACMA', id: 10}) -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
(object) - - insertFields - key and value pairs of columns and values to be inserted
(object) - - insertOptions -
(object) - - [insertOptions.touch] - if true, auto insert created_at and updated_at values. Default is true.
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- oThis -
- - - -
-
- Type -
-
- -object.<self> - - - -
-
- - - - - -
- - - -
-
-

insertMultiple(insertColumns, insertValues, insertOptions)

- - -
-
- - -
- Insert multiple records in table. Method can't be called twice on same object - -Example 1: -insertMultiple(['name', 'symbol'], [['ABC', '123'], ['ABD', '456']]) -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
insertColumns - - -array - - - - - list of columns. also columns are mandatory
insertValues - - -array - - - - - array of array with values
insertOptions - - -object - - - - - - -
Properties
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeArgumentDescription
touch - - -object - - - - - - - <optional>
- - - - - -
if true, auto insert created_at and updated_at values. Default is true.
- -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- oThis -
- - - -
-
- Type -
-
- -object.<self> - - - -
-
- - - - - -
- - - -
-
-

limit((number))

- - -
-
- - -
- Limit of records to be fetched. If called multiple times, it will overwrite the previous value - -Example 1: -limit(100) -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
(number) - - recordsLimit - limit for select query
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- oThis -
- - - -
-
- Type -
-
- -object.<self> - - - -
-
- - - - - -
- - - -
-
-

offset((number))

- - -
-
- - -
- Offset for records to be fetched. If called multiple times, it will overwrite the previous value. limit is mandatory for offset - -Example 1: -offset(10) -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
(number) - - recordsOffset - offset for select query
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- oThis -
- - - -
-
- Type -
-
- -object.<self> - - - -
-
- - - - - -
- - - -
-
-

onDuplicate()

- - -
-
- - -
- On Duplicate conditions to be applied to the INSERT query. If called multiple times, conditions will be joined by COMMA. - -Possible data types: -* Array - index 0 should have the On Duplicate sub query and other indexes should have the valued to be replaced in sub query -* Object - key and value pairs of columns and values to be joined by COMMA to form On Duplicate sub query -* String - sub query, used as it is. - -Example 1: ON DUPLICATE in array format -onDuplicate(['name=? , id=?', 'ACMA', 10]) - -Example 2: ON DUPLICATE in object format. Conditions will be joined by , -onDuplicate({name: 'ACMA', id: 10}) - -Example 3: ON DUPLICATE in string. Will be used as it is -onDuplicate('id=10') -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- oThis -
- - - -
-
- Type -
-
- -object.<self> - - - -
-
- - - - - -
- - - -
-
-

order_by()

- - -
-
- - -
- List of fields to be ordered by from table. If called multiple times, order by conditions will be joined by COMMA. - -Possible data types: -* Object - where keys are column names and value is order -* String - order will be used as it is - -Example 1: -order_by({'name': 'ASC', 'created_at': 'DESC'}) - -Example 2: -order_by('name ASC, created_at DESC') - -Example 3: -order_by([1, 2, 3]) -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- oThis -
- - - -
-
- Type -
-
- -object.<self> - - - -
-
- - - - - -
- - - -
-
-

select()

- - -
-
- - -
- List of fields to be selected from table. If called multiple times, select columns will be joined by COMMA. - -Possible data types: -* blank/undefined - '*' will be used to fetch all columns -* Array - list of field names will be joined by comma -* String - list of field names will be used as it is - -Example 1: '*' will be used to fetch all columns -select() - -Example 2: list of field names in array. Will be joined by comma -select(['name', 'created_at']) - -Example 3: list of field names in string. Will be used as it is -select('name, created_at') -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- oThis -
- - - -
-
- Type -
-
- -object.<self> - - - -
-
- - - - - -
- - - -
-
-

update(updateFields, insertOptions)

- - -
-
- - -
- Update columns to be applied to the query. If called multiple times, update fields will be joined by COMMA. - -Possible data types: -* Array - index 0 should have the update sub query and other indexes should have the valued to be replaced in sub query -* Object - key and value pairs of columns and values to be joined by COMMA to form update sub query -* String - update sub query, used as it is. -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
updateFields - - -* - - - - - refer possible data types
insertOptions - - -object - - - - - - -
Properties
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeArgumentDescription
touch - - -object - - - - - - - <optional>
- - - - - -
if true, auto insert created_at and updated_at values. Default is true. - -Example 1: update in array format -update(['name=?, id=?', 'ACMA', 10]) - -Example 2: Update in object format. Fields will be joined by {,} -update({name: 'ACMA', id: 10}) - -Example 3: Update in string. Will be used as it is -update('id=10')
- -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- oThis -
- - - -
-
- Type -
-
- -object.<self> - - - -
-
- - - - - -
- - - -
-
-

where()

- - -
-
- - -
- Where conditions to be applied to the query. If called multiple times, where conditions will be joined by AND. - -Possible data types: -* Array - index 0 should have the where sub query and other indexes should have the valued to be replaced in sub query -* Object - key and value pairs of columns and values to be joined by AND to form where sub query -* String - where sub query, used as it is. - -Example 1: Where in array format -where(['name=? AND id=?', 'ACMA', 10]) - -Example 2: Where in object format. Conditions will be joined by AND -where({name: 'ACMA', id: 10}) -where({name: [1,2,3], id: 10}) - -Example 3: condition in string. Will be used as it is -where('id=10') -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- oThis -
- - - -
-
- Type -
-
- -object.<self> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_query_builder_mysql.html b/docs/module-lib_query_builder_mysql.html deleted file mode 100644 index 0fd7ba0..0000000 --- a/docs/module-lib_query_builder_mysql.html +++ /dev/null @@ -1,339 +0,0 @@ - - - - - - - OpenST Payments Module: lib/query_builder/mysql - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/query_builder/mysql

-
- -
- -
- - -
-
- - -
Form mysql query

- - -Max supported SELECT query: -SELECT [columns] - FROM [table] - WHERE [where conditions] - GROUP BY [columns] - ORDER BY [order by columns] - HAVING [having condition] - LIMIT [limit and offset]; - -Max supported INSERT query: -INSERT INTO [table] ([columns]) - VALUES ([values]), ([values]) - ON DUPLICATE KEY UPDATE [conditions]; - -Max supported UPDATE query: -UPDATE [table] - SET [column=value], [column=value] - WHERE [where conditions] - ORDER BY [order by columns] - LIMIT [limit]; - -Max supported DELETE query: -DELETE FROM [table] - WHERE [where conditions] - ORDER BY [order by columns] - LIMIT [limit];
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
MySQLQueryBuilderKlass
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_set_worker_and_ops-SetWorkerOps.html b/docs/module-lib_set_worker_and_ops-SetWorkerOps.html deleted file mode 100644 index 4e4ced0..0000000 --- a/docs/module-lib_set_worker_and_ops-SetWorkerOps.html +++ /dev/null @@ -1,603 +0,0 @@ - - - - - - - OpenST Payments Class: SetWorkerOps - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: SetWorkerOps

-
- -
- -

- lib/set_worker_and_ops~ - - SetWorkerOps -

- - -
- - -
-
- - -
-
-

new SetWorkerOps()

- - -
-
- - -
- Set Worker Contract and OPS Address -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

perform( [options])

- - -
-
- - -
- Set Worker and Ops for a contract. -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeArgumentDescription
options - - -object - - - - - - - <optional>
- - - - - -
-
Properties
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeArgumentDescription
gasPrice - - -number - - - - - - - <optional>
- - - - - -
Gas Price to use
chainId - - -number - - - - - - - <optional>
- - - - - -
Chain Id where contract need to be deployed
- -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise.<result> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_set_worker_and_ops.html b/docs/module-lib_set_worker_and_ops.html deleted file mode 100644 index 934c5d1..0000000 --- a/docs/module-lib_set_worker_and_ops.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/set_worker_and_ops - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/set_worker_and_ops

-
- -
- -
- - -
-
- - -
Set Worker Contract and OPS Address
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
SetWorkerOps
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_transaction_helper-TransactionHelper.html b/docs/module-lib_transaction_helper-TransactionHelper.html deleted file mode 100644 index 6f7a7b2..0000000 --- a/docs/module-lib_transaction_helper-TransactionHelper.html +++ /dev/null @@ -1,4093 +0,0 @@ - - - - - - - OpenST Payments Class: TransactionHelper - - - - - - - - - - - - - -
-
- - -
- -
- - -

Class: TransactionHelper

-
- -
- -

- lib/transaction_helper~ - - TransactionHelper -

- - -
- - -
-
- - -
-
-

new TransactionHelper(chainId)

- - -
-
- - -
- constructor -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
chainId - - -string - - - - - chain id
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -
- - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

_getPromiseArrayForBalanceChange(brandedTokenAddress, airdropAddress, addressToBalanceChangeMap, addressToAirdropBalanceChangeMap)

- - -
-
- - -
- Get promise array for balance change -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - branded token address
airdropAddress - - -string - - - - - airdrop contract address
addressToBalanceChangeMap - - -string - - - - - address to balance change map
addressToAirdropBalanceChangeMap - - -BigNumber - - - - - address to airdrop balance change map
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -array.<promise> - - - -
-
- - - - - -
- - - -
-
-

afterAirdropPayFailure(brandedTokenAddress, airdropAddress, spender, estimatedPayAmount, estimatedAirdropAmount, airdropBugdetAddress)

- - -
-
- - -
- After airdrop pay function, this is called after the pay is failed -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - branded token address
airdropAddress - - -string - - - - - airdrop contract address
spender - - -string - - - - - spender address
estimatedPayAmount - - -BigNumber - - - - - estimated pay amount in weis
estimatedAirdropAmount - - -BigNumber - - - - - estimated airdrop amount
airdropBugdetAddress - - -string - - - - - airdrop budget holder address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

afterAirdropPaySuccess(brandedTokenAddress, airdropAddress, spender, estimatedPayAmount, estimatedAirdropAmount, beneficiaryAddress, actualBeneficiaryAmount, commissionBeneficiaryAddress, actualCommissionBeneficiaryAmount, actualAirdropAmount, airdropBugdetAddress)

- - -
-
- - -
- After airdrop pay function, this is called after the pay is successfull -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - branded token address
airdropAddress - - -string - - - - - airdrop contract address
spender - - -string - - - - - spender address
estimatedPayAmount - - -BigNumber - - - - - estimated pay amount in weis
estimatedAirdropAmount - - -BigNumber - - - - - estimated airdrop amount
beneficiaryAddress - - -string - - - - - beneficiary address
actualBeneficiaryAmount - - -BigNumber - - - - - actual beneficiary amount in weis
commissionBeneficiaryAddress - - -string - - - - - commission beneficiary address
actualCommissionBeneficiaryAmount - - -BigNumber - - - - - actual commission beneficiary amount
actualAirdropAmount - - -BigNumber - - - - - actual airdrop amount
airdropBugdetAddress - - -string - - - - - airdrop budget holder address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

afterPayFailure(brandedTokenAddress, spender, estimatedPayAmount)

- - -
-
- - -
- After pay function, this is called after the pay is failed -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - branded token address
spender - - -string - - - - - spender address
estimatedPayAmount - - -BigNumber - - - - - estimated pay amount in weis
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

afterPaySuccess(brandedTokenAddress, spender, estimatedPayAmount, beneficiaryAddress, actualBeneficiaryAmount, commissionBeneficiaryAddress, actualCommissionBeneficiaryAmount)

- - -
-
- - -
- After pay function, this is called after the pay is successfull -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - branded token address
spender - - -string - - - - - spender address
estimatedPayAmount - - -BigNumber - - - - - estimated pay amount in weis
beneficiaryAddress - - -string - - - - - beneficiary address
actualBeneficiaryAmount - - -BigNumber - - - - - actual beneficiary amount in weis
commissionBeneficiaryAddress - - -string - - - - - commission beneficiary address
actualCommissionBeneficiaryAmount - - -BigNumber - - - - - actual commission beneficiary amount
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

beforeAirdropPay(brandedTokenAddress, airdropAddress, spender, estimatedPayAmount, estimatedAirdropAmount, airdropBugdetAddress)

- - -
-
- - -
- Before airdrop pay function, this is called before the pay is called -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - branded token address
airdropAddress - - -string - - - - - airdrop contract address
spender - - -string - - - - - spender address
estimatedPayAmount - - -BigNumber - - - - - estimated pay amount in weis
estimatedAirdropAmount - - -BigNumber - - - - - estimated airdrop amount
airdropBugdetAddress - - -string - - - - - airdrop budget holder address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

beforePay(brandedTokenAddress, spender, estimatedPayAmount)

- - -
-
- - -
- Before pay function, this is called before the pay is called -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - branded token address
spender - - -string - - - - - spender address
estimatedPayAmount - - -BigNumber - - - - - estimated pay amount in weis
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

clearUserDetailCache(airdropContractAddress, owner)

- - -
-
- - -
- Clear user detail cache for the user addressess -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
airdropContractAddress - - -string - - - - - airdrop contract address
owner - - -string - - - - - Account address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

creditAirdropBalance(airdropContractAddress, owner, bigAmount)

- - -
-
- - -
- Credit airdrop balance in db and clear cache -It decreases airdrop_used_amount for user in user_airdrop_details table -Clears the cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
airdropContractAddress - - -string - - - - - airdrop contract address
owner - - -string - - - - - Account address
bigAmount - - -BigNumber - - - - - amount to be credited
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

creditBalance(brandedTokenAddress, owner, bigAmount)

- - -
-
- - -
- Credit balance in cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - branded token address
owner - - -string - - - - - Account address
bigAmount - - -BigNumber - - - - - amount to be credited
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

debitAirdropBalance(airdropContractAddress, owner, bigAmount)

- - -
-
- - -
- Debit airdrop balance in db and clear cache -It increases airdrop_used_amount for user in user_airdrop_details table -Clears the cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
airdropContractAddress - - -string - - - - - airdrop contract address
owner - - -string - - - - - Account address
bigAmount - - -BigNumber - - - - - amount to be debited
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

debitBalance(brandedTokenAddress, owner, bigAmount)

- - -
-
- - -
- Debit balance in cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - branded token address
owner - - -string - - - - - Account address
bigAmount - - -BigNumber - - - - - amount to be debited
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

getActualAmountsFromReceipt(transactionReceipt, addressToNameMap)

- - -
-
- - -
- Get actual beneficiary amount, actual commission amount and actual airdrop amount from transaction receipt -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
transactionReceipt - - -Object - - - - - transaction receipt
addressToNameMap - - -Object - - - - - address to name map object
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -result - - - -
-
- - - - - -
- - - -
-
-

isAllResponseSuccessful(results)

- - -
-
- - -
- Check if all response is success -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
results - - -array - - - - - response array
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -boolean - - - -
-
- - - - - -
- - - -
-
-

setBalanceInCache(brandedTokenAddress, owner, bigAmount)

- - -
-
- - -
- Set balance in cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - branded token address
owner - - -string - - - - - Account address
bigAmount - - -BigNumber - - - - - amount to be set
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

updateAirdropBalance(airdropContractAddress, owner, toCreditBigAmount)

- - -
-
- - -
- Update airdrop balance -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
airdropContractAddress - - -string - - - - - airdrop contract address
owner - - -string - - - - - Account address
toCreditBigAmount - - -BigNumber - - - - - to credit amount - this can be negative also
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- - - -
-
-

updateBalance(brandedTokenAddress, owner, toCreditBigAmount)

- - -
-
- - -
- Update balance to cache -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
brandedTokenAddress - - -string - - - - - branded token address
owner - - -string - - - - - Account address
toCreditBigAmount - - -BigNumber - - - - - to credit amount - this can be negative also
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -promise.<result> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_transaction_helper.html b/docs/module-lib_transaction_helper.html deleted file mode 100644 index 5f1a819..0000000 --- a/docs/module-lib_transaction_helper.html +++ /dev/null @@ -1,311 +0,0 @@ - - - - - - - OpenST Payments Module: lib/transaction_helper - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/transaction_helper

-
- -
- -
- - -
-
- - -
This is transaction helper that manages the cache updation

- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
TransactionHelper
-
-
- - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_web3_events_formatter-web3EventsDecoder.html b/docs/module-lib_web3_events_formatter-web3EventsDecoder.html deleted file mode 100644 index d03956b..0000000 --- a/docs/module-lib_web3_events_formatter-web3EventsDecoder.html +++ /dev/null @@ -1,491 +0,0 @@ - - - - - - - OpenST Payments Namespace: web3EventsDecoder - - - - - - - - - - - - - -
-
- - -
- -
- - -

Namespace: web3EventsDecoder

-
- -
- -

- lib/web3/events/formatter~ - - web3EventsDecoder -

- - -
- - -
-
- - -
Ivent Decoder.
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

perform(txReceipt, addressToNameMap)

- - -
-
- - -
- performer -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
txReceipt - - -Object - - - - -
addressToNameMap - - -Hash - - - - - Map of the address(key) to name(value)
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - -
- object of resulthelpwe\\er -
- - - -
-
- Type -
-
- -result - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_web3_events_formatter-web3EventsFormatter.html b/docs/module-lib_web3_events_formatter-web3EventsFormatter.html deleted file mode 100644 index e940659..0000000 --- a/docs/module-lib_web3_events_formatter-web3EventsFormatter.html +++ /dev/null @@ -1,457 +0,0 @@ - - - - - - - OpenST Payments Namespace: web3EventsFormatter - - - - - - - - - - - - - -
-
- - -
- -
- - -

Namespace: web3EventsFormatter

-
- -
- -

- lib/web3/events/formatter~ - - web3EventsFormatter -

- - -
- - -
-
- - -
Event Formatter.
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

perform(formattedTransactionReceipt)

- - -
-
- - -
- performer -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
formattedTransactionReceipt - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise.<{}> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-lib_web3_events_formatter.html b/docs/module-lib_web3_events_formatter.html deleted file mode 100644 index 48a3719..0000000 --- a/docs/module-lib_web3_events_formatter.html +++ /dev/null @@ -1,407 +0,0 @@ - - - - - - - OpenST Payments Module: lib/web3/events/formatter - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: lib/web3/events/formatter

-
- -
- -
- - -
-
- - -
Format decoded event into Hash with all the events received into it.
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - - - - - -

Namespaces

- -
-
web3EventsDecoder
-
- -
web3EventsFormatter
-
-
- - - - - - - - - -
- -
- - - - -

Module: lib/web3/events/formatter

-
- -
- -
- - -
-
- - -
Decode logs from a transaction receipt
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - - - - - -

Namespaces

- -
-
web3EventsDecoder
-
- -
web3EventsFormatter
-
-
- - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-tools_deploy_DeployHelper.html b/docs/module-tools_deploy_DeployHelper.html deleted file mode 100644 index 655db06..0000000 --- a/docs/module-tools_deploy_DeployHelper.html +++ /dev/null @@ -1,821 +0,0 @@ - - - - - - - OpenST Payments Module: tools/deploy/DeployHelper - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: tools/deploy/DeployHelper

-
- -
- -
- - -
-
- - -
Deploy Helper class to perform deploy
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

<static> writeContractAddressToFile(fileName, contractAddress)

- - -
-
- - -
- Write contract address to file based on parameter -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
fileName - - -String - - - - - file name
contractAddress - - -Hex - - - - - contract Address
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- - - -
-
-

<async, inner> perform(contractName, web3Provider, contractAbi, contractBin, deployerName [, customOptions] [, constructorArgs])

- - -
-
- - -
- Method deploys contract -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeArgumentDescription
contractName - - -String - - - - - - - - - - - Contract Name to be deployed
web3Provider - - -Web3 - - - - - - - - - - - Web3 Provider object
contractAbi - - -String - - - - - - - - - - - Contract Abi to be deployed
contractBin - - -String - - - - - - - - - - - Contract Bin file to be deployed
deployerName - - -String - - - - - - - - - - - Deployer name
customOptions - - -Object - - - - - - - <optional>
- - - - - -
Custom options for value/utility chain
constructorArgs - - -Object - - - - - - - <optional>
- - - - - -
Arguments to be passed while deploying contract
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - -
-
- Type -
-
- -Promise.<Object> - - - -
-
- - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-tools_deploy_EIP20TokenMock.html b/docs/module-tools_deploy_EIP20TokenMock.html deleted file mode 100644 index dafd63c..0000000 --- a/docs/module-tools_deploy_EIP20TokenMock.html +++ /dev/null @@ -1,448 +0,0 @@ - - - - - - - OpenST Payments Module: tools/deploy/EIP20TokenMock - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: tools/deploy/EIP20TokenMock

-
- -
- -
- - -
-
- - -
This is script for deploying Pricer contract on any chain.

- - Prerequisite: -
    -
  1. Deployer Address
  2. -
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

<async, inner> performer(arguments)

- - -
-
- - -
- It is the main performer method of this deployment script -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
arguments - - -Array - - - - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-tools_deploy_helper.html b/docs/module-tools_deploy_helper.html deleted file mode 100644 index 86c008d..0000000 --- a/docs/module-tools_deploy_helper.html +++ /dev/null @@ -1,306 +0,0 @@ - - - - - - - OpenST Payments Module: tools/deploy/helper - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: tools/deploy/helper

-
- -
- -
- - -
-
- - -
This is utility class for deploying contract

- -Ref: module:tools/deploy/DeployHelper
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - - - - - - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-tools_deploy_pricer.html b/docs/module-tools_deploy_pricer.html deleted file mode 100644 index 996ef44..0000000 --- a/docs/module-tools_deploy_pricer.html +++ /dev/null @@ -1,1495 +0,0 @@ - - - - - - - OpenST Payments Module: tools/deploy/pricer - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: tools/deploy/pricer

-
- -
- -
- - -
-
- - -
This is script for deploying Pricer contract on any chain.

- - Prerequisite: -
    -
  1. Deployer Address
  2. -
- - These are the following steps:
-
    -
  1. Deploy Pricer contract
  2. -
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

<async, inner> performer(arguments)

- - -
-
- - -
- It is the main performer method of this deployment script -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
arguments - - -Array - - - - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- - - -
-
-

<async, inner> performer(arguments)

- - -
-
- - -
- It is the main performer method of this deployment script -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
arguments - - -Array - - - - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- - - -
-
-

<inner> validate(arguments)

- - -
-
- - -
- Validation Method -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
arguments - - -Array - - - - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- - - -
-
-

<inner> validate(arguments)

- - -
-
- - -
- Validation Method -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
arguments - - -Array - - - - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- -
- - - - - -
- -
- - - - -

Module: tools/deploy/pricer

-
- -
- -
- - -
-
- - -
This is script for deploying Pricer contract on any chain.

- - Prerequisite: -
    -
  1. Deployer Address
  2. -
- - These are the following steps:
-
    -
  1. Deploy Airdrop contract
  2. -
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

<async, inner> performer(arguments)

- - -
-
- - -
- It is the main performer method of this deployment script -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
arguments - - -Array - - - - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- - - -
-
-

<async, inner> performer(arguments)

- - -
-
- - -
- It is the main performer method of this deployment script -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
arguments - - -Array - - - - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- - - -
-
-

<inner> validate(arguments)

- - -
-
- - -
- Validation Method -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
arguments - - -Array - - - - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- - - -
-
-

<inner> validate(arguments)

- - -
-
- - -
- Validation Method -
- - - - - - - - -
Parameters:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameTypeDescription
arguments - - -Array - - - - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/module-tools_deploy_workers.html b/docs/module-tools_deploy_workers.html deleted file mode 100644 index fdda390..0000000 --- a/docs/module-tools_deploy_workers.html +++ /dev/null @@ -1,406 +0,0 @@ - - - - - - - OpenST Payments Module: tools/deploy/workers - - - - - - - - - - - - - -
-
- - -
- -
- - -

Module: tools/deploy/workers

-
- -
- -
- - -
-
- - -
This is script for deploying Workers contract on any chain.

- - Prerequisite: -
    -
  1. Deployer Address
  2. -
- - These are the following steps:
-
    -
  1. Deploy Workers contract
  2. -
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - - - - - - - - - -

Methods

- -
- -
-
-

<async, inner> performer()

- - -
-
- - -
- It is the main performer method of this deployment script - -Example: -node tools/deploy/worker.js gasPrice chainId -
- - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - -
Returns:
- - - - - - - - -
- -
- - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/modules.list.html b/docs/modules.list.html deleted file mode 100644 index 08dfae7..0000000 --- a/docs/modules.list.html +++ /dev/null @@ -1,396 +0,0 @@ - - - - - - - OpenST Payments Modules - - - - - - - - - - - - - -
-
- - -
- -
- - -

Modules

-
- -
- -

- -

- - -
- - -
-
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
baseCacheMultiManagementKlass
-
- -
BasicHelperKlass
-
- -
approve
-
- -
base
-
- -
batchAllocator
-
- -
register
-
- -
transfer
-
- -
AdjustAirdropAmountKlass
-
- -
AirdropUserBalanceKlass
-
- -
AirdropBalanceCache
-
- -
BalanceCache
-
- -
PricerCache
-
- -
Airdrop
-
- -
BrandedToken
-
- -
ContractInteractHelper
-
- -
OpsManagedContract
-
- -
OwnedContract
-
- -
MockToken
-
- -
Pricer
-
- -
Workers
-
- -
Deploy
-
- -
MySQLQueryBuilderKlass
-
- -
SetWorkerOps
-
- -
TransactionHelper
-
- -
userAirdropDetailCache
-
-
- - - - - -

Namespaces

- -
-
web3EventsDecoder
-
- -
web3EventsFormatter
-
-
- - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/namespaces.list.html b/docs/namespaces.list.html deleted file mode 100644 index 05e55e7..0000000 --- a/docs/namespaces.list.html +++ /dev/null @@ -1,396 +0,0 @@ - - - - - - - OpenST Payments Namespaces - - - - - - - - - - - - - -
-
- - -
- -
- - -

Namespaces

-
- -
- -

- -

- - -
- - -
-
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - - - - -

Classes

- -
-
baseCacheMultiManagementKlass
-
- -
BasicHelperKlass
-
- -
approve
-
- -
base
-
- -
batchAllocator
-
- -
register
-
- -
transfer
-
- -
AdjustAirdropAmountKlass
-
- -
AirdropUserBalanceKlass
-
- -
AirdropBalanceCache
-
- -
BalanceCache
-
- -
PricerCache
-
- -
Airdrop
-
- -
BrandedToken
-
- -
ContractInteractHelper
-
- -
OpsManagedContract
-
- -
OwnedContract
-
- -
MockToken
-
- -
Pricer
-
- -
Workers
-
- -
Deploy
-
- -
MySQLQueryBuilderKlass
-
- -
SetWorkerOps
-
- -
TransactionHelper
-
- -
userAirdropDetailCache
-
-
- - - - - -

Namespaces

- -
-
web3EventsDecoder
-
- -
web3EventsFormatter
-
-
- - - - - - - - - -
- -
- - - - -
-
- -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/docs/quicksearch.html b/docs/quicksearch.html deleted file mode 100644 index a57571d..0000000 --- a/docs/quicksearch.html +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - - - - - - - - diff --git a/docs/scripts/docstrap.lib.js b/docs/scripts/docstrap.lib.js deleted file mode 100644 index 09d9272..0000000 --- a/docs/scripts/docstrap.lib.js +++ /dev/null @@ -1,11 +0,0 @@ -if(!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){function c(a){var b="length"in a&&a.length,c=_.type(a);return"function"!==c&&!_.isWindow(a)&&(!(1!==a.nodeType||!b)||("array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a))}function d(a,b,c){if(_.isFunction(b))return _.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return _.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(ha.test(b))return _.filter(b,a,c);b=_.filter(b,a)}return _.grep(a,function(a){return U.call(b,a)>=0!==c})}function e(a,b){for(;(a=a[b])&&1!==a.nodeType;);return a}function f(a){var b=oa[a]={};return _.each(a.match(na)||[],function(a,c){b[c]=!0}),b}function g(){Z.removeEventListener("DOMContentLoaded",g,!1),a.removeEventListener("load",g,!1),_.ready()}function h(){Object.defineProperty(this.cache={},0,{get:function(){return{}}}),this.expando=_.expando+h.uid++}function i(a,b,c){var d;if(void 0===c&&1===a.nodeType)if(d="data-"+b.replace(ua,"-$1").toLowerCase(),c=a.getAttribute(d),"string"==typeof c){try{c="true"===c||"false"!==c&&("null"===c?null:+c+""===c?+c:ta.test(c)?_.parseJSON(c):c)}catch(a){}sa.set(a,b,c)}else c=void 0;return c}function j(){return!0}function k(){return!1}function l(){try{return Z.activeElement}catch(a){}}function m(a,b){return _.nodeName(a,"table")&&_.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function n(a){return a.type=(null!==a.getAttribute("type"))+"/"+a.type,a}function o(a){var b=Ka.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function p(a,b){for(var c=0,d=a.length;d>c;c++)ra.set(a[c],"globalEval",!b||ra.get(b[c],"globalEval"))}function q(a,b){var c,d,e,f,g,h,i,j;if(1===b.nodeType){if(ra.hasData(a)&&(f=ra.access(a),g=ra.set(b,f),j=f.events)){delete g.handle,g.events={};for(e in j)for(c=0,d=j[e].length;d>c;c++)_.event.add(b,e,j[e][c])}sa.hasData(a)&&(h=sa.access(a),i=_.extend({},h),sa.set(b,i))}}function r(a,b){var c=a.getElementsByTagName?a.getElementsByTagName(b||"*"):a.querySelectorAll?a.querySelectorAll(b||"*"):[];return void 0===b||b&&_.nodeName(a,b)?_.merge([a],c):c}function s(a,b){var c=b.nodeName.toLowerCase();"input"===c&&ya.test(a.type)?b.checked=a.checked:("input"===c||"textarea"===c)&&(b.defaultValue=a.defaultValue)}function t(b,c){var d,e=_(c.createElement(b)).appendTo(c.body),f=a.getDefaultComputedStyle&&(d=a.getDefaultComputedStyle(e[0]))?d.display:_.css(e[0],"display");return e.detach(),f}function u(a){var b=Z,c=Oa[a];return c||(c=t(a,b),"none"!==c&&c||(Na=(Na||_("