API Wrapper for CollectiveStorage contract

Hierarchy

Implements

Constructors

Properties

contract: Contract
contractAbi: any[]
contractAddress: string
gas: number
gasPriceGwei: string
logger: Logger = ...
web3: default
ABI_NAME: string = 'Storage.json'

Methods

  • get the number of choices for a choice vote

    Parameters

    • proposalId: number

      The id of the vote

    Returns Promise<number>

    number - The number of choices

  • get the end time for the vote

    Parameters

    • proposalId: number

      The id of the vote

    Returns Promise<number>

    number - The number of seconds referenced from the unix epoch, January 1, 1970

  • get the choice parameterization for a specific choice

    Parameters

    • proposalId: number

      The id of the vote

    • choiceId: number

      The id of the choice

    Returns Promise<{
        description: string;
        name: string;
        transactionId: number;
        voteCount: number;
    }>

    string - the name

  • get the start time for the vote

    Parameters

    • proposalId: number

      The id of the vote

    Returns Promise<number>

    number - The number of seconds referenced from the unix epoch, January 1, 1970

  • get the delay for this vote

    Parameters

    • proposalId: number

      The id of the vote

    Returns Promise<number>

    number - The number of seconds

  • get the amount of time for the vote

    Parameters

    • proposalId: number

      The id of the vote

    Returns Promise<number>

    number - The number of seconds

Generated using TypeDoc