Class Polls

    • Constructor Detail

      • Polls

        public Polls​(VkApiClient client)
        Constructor
        Parameters:
        client - vk api client
    • Method Detail

      • addVote

        public PollsAddVoteQuery addVote​(UserActor actor,
                                         int pollId,
                                         java.lang.Integer... answerIds)
        Adds the current user's vote to the selected answer in the poll.
        Parameters:
        actor - vk actor
        pollId - Poll ID.
        answerIds -
        Returns:
        query
      • addVote

        public PollsAddVoteQuery addVote​(UserActor actor,
                                         int pollId,
                                         java.util.List<java.lang.Integer> answerIds)
        Adds the current user's vote to the selected answer in the poll.
        Parameters:
        actor - vk actor
        pollId - Poll ID.
        answerIds -
        Returns:
        query
      • create

        public PollsCreateQuery create​(UserActor actor)
        Creates polls that can be attached to the users' or communities' posts.
        Parameters:
        actor - vk actor
        Returns:
        query
      • deleteVote

        public PollsDeleteVoteQuery deleteVote​(UserActor actor,
                                               int pollId,
                                               int answerId)
        Deletes the current user's vote from the selected answer in the poll.
        Parameters:
        actor - vk actor
        pollId - Poll ID.
        answerId - Answer ID.
        Returns:
        query
      • edit

        public PollsEditQuery edit​(UserActor actor,
                                   int pollId)
        Edits created polls
        Parameters:
        actor - vk actor
        pollId - edited poll's id
        Returns:
        query
      • getById

        public PollsGetByIdQuery getById​(UserActor actor,
                                         int pollId)
        Returns detailed information about a poll by its ID.
        Parameters:
        actor - vk actor
        pollId - Poll ID.
        Returns:
        query
      • getVoters

        public PollsGetVotersQuery getVoters​(UserActor actor,
                                             int pollId,
                                             java.lang.Integer... answerIds)
        Returns a list of IDs of users who selected specific answers in the poll.
        Parameters:
        actor - vk actor
        pollId - Poll ID.
        answerIds - Answer IDs.
        Returns:
        query
      • getVoters

        public PollsGetVotersQuery getVoters​(UserActor actor,
                                             int pollId,
                                             java.util.List<java.lang.Integer> answerIds)
        Returns a list of IDs of users who selected specific answers in the poll.
        Parameters:
        actor - vk actor
        pollId - Poll ID.
        answerIds - Answer IDs.
        Returns:
        query
      • savePhoto

        public PollsSavePhotoQuery savePhoto​(UserActor actor,
                                             java.lang.String photo,
                                             java.lang.String hash)
        Parameters:
        actor - vk actor
        photo -
        hash -
        Returns:
        query