Class: Vk::API::Wall::Methods::GetComments

Inherits:
Schema::Method
  • Object
show all
Defined in:
lib/vk/api/wall/methods/get_comments.rb

Overview

Returns a list of comments on a post on a user wall or community wall.

Arguments collapse

Instance Method Summary collapse

Methods inherited from Schema::Method

#call, #method, #to_hash

Constructor Details

#initialize(arguments) ⇒ Wall::Methods::GetComments

Parameters:

  • arguments (Hash)

Options Hash (arguments):

  • :owner_id (Integer) —

    User ID or community ID. Use a negative value to designate a community ID.

  • :post_id (Integer) —

    Post ID.

  • :need_likes (Boolean) —

    '1' — to return the 'likes' field; '0' — not to return the 'likes' field (default)

  • :start_comment_id (Integer) —
  • :offset (Integer) —

    Offset needed to return a specific subset of comments.

  • :count (Integer) —

    Number of comments to return (maximum 100).

  • :sort (String) —

    Sort order:; 'asc' — chronological; 'desc' — reverse chronological

  • :preview_length (Integer) —

    Number of characters at which to truncate comments when previewed. By default, '90'. Specify '0' if you do not want to truncate comments.;

  • :extended (Boolean) —


# File 'lib/vk/api/wall/methods/get_comments.rb', line 15

Instance Method Details

#count ⇒ Integer

Returns Number of comments to return (maximum 100).

Returns:

  • (Integer) —

    Number of comments to return (maximum 100).



41
# File 'lib/vk/api/wall/methods/get_comments.rb', line 41

attribute :count, API::Types::Coercible::Int.optional.default(nil)

#extended ⇒ Boolean



47
# File 'lib/vk/api/wall/methods/get_comments.rb', line 47

attribute :extended, API::Types::Form::Bool.optional.default(nil)

#need_likes ⇒ Boolean

Returns '1' — to return the 'likes' field; '0' — not to return the 'likes' field (default).

Returns:

  • (Boolean) —

    '1' — to return the 'likes' field; '0' — not to return the 'likes' field (default)



35
# File 'lib/vk/api/wall/methods/get_comments.rb', line 35

attribute :need_likes, API::Types::Form::Bool.optional.default(nil)

#offset ⇒ Integer

Returns Offset needed to return a specific subset of comments.

Returns:

  • (Integer) —

    Offset needed to return a specific subset of comments.



39
# File 'lib/vk/api/wall/methods/get_comments.rb', line 39

attribute :offset, API::Types::Coercible::Int.optional.default(nil)

#owner_id ⇒ Integer

Returns User ID or community ID. Use a negative value to designate a community ID.

Returns:

  • (Integer) —

    User ID or community ID. Use a negative value to designate a community ID.



31
# File 'lib/vk/api/wall/methods/get_comments.rb', line 31

attribute :owner_id, API::Types::Coercible::Int.optional.default(nil)

#post_id ⇒ Integer

Returns Post ID.

Returns:

  • (Integer) —

    Post ID.



33
# File 'lib/vk/api/wall/methods/get_comments.rb', line 33

attribute :post_id, API::Types::Coercible::Int

#preview_length ⇒ Integer

Returns Number of characters at which to truncate comments when previewed. By default, '90'. Specify '0' if you do not want to truncate comments.;.

Returns:

  • (Integer) —

    Number of characters at which to truncate comments when previewed. By default, '90'. Specify '0' if you do not want to truncate comments.;



45
# File 'lib/vk/api/wall/methods/get_comments.rb', line 45

attribute :preview_length, API::Types::Coercible::Int.optional.default(nil)

#sort ⇒ String

Returns Sort order:; 'asc' — chronological; 'desc' — reverse chronological.

Returns:

  • (String) —

    Sort order:; 'asc' — chronological; 'desc' — reverse chronological



43
# File 'lib/vk/api/wall/methods/get_comments.rb', line 43

attribute :sort, API::Types::Coercible::String.optional.default(nil)

#start_comment_id ⇒ Integer



37
# File 'lib/vk/api/wall/methods/get_comments.rb', line 37

attribute :start_comment_id, API::Types::Coercible::Int.optional.default(nil)