Skip to main content
Version: v2.0_alpha

IPollFactory

PollFactory interface

deploy

function deploy(uint256 _duration, uint256 _maxVoteOptions, struct Params.TreeDepths _treeDepths, uint8 _messageBatchSize, struct DomainObjs.PubKey _coordinatorPubKey, address _maci) external returns (address)

Deploy a new Poll contract

Parameters

NameTypeDescription
_durationuint256The duration of the poll
_maxVoteOptionsuint256The max vote options for the poll
_treeDepthsstruct Params.TreeDepthsThe depths of the merkle trees
_messageBatchSizeuint8The size of message batch
_coordinatorPubKeystruct DomainObjs.PubKeyThe coordinator's public key
_maciaddressThe MACI contract interface reference

Return Values

NameTypeDescription
[0]addressThe deployed Poll contract