Class: Spotted::Models::AudiobookRetrieveResponse::Chapters

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/spotted/models/audiobook_retrieve_response.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(href:, limit:, next_:, offset:, previous:, total:, items: nil, published: nil) ⇒ Object

Some parameter documentations has been truncated, see Spotted::Models::AudiobookRetrieveResponse::Chapters for more details.

The chapters of the audiobook.

Parameters:

  • href (String)

    A link to the Web API endpoint returning the full result of the request

  • limit (Integer)

    The maximum number of items in the response (as set in the query or by default).

  • next_ (String, nil)

    URL to the next page of items. ( ‘null` if none)

  • offset (Integer)

    The offset of the items returned (as set in the query or by default)

  • previous (String, nil)

    URL to the previous page of items. ( ‘null` if none)

  • total (Integer)

    The total number of items available to return.

  • items (Array<Spotted::Models::SimplifiedChapterObject>) (defaults to: nil)
  • published (Boolean) (defaults to: nil)

    The playlist’s public/private status (if it should be added to the user’s profil



19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
# File 'lib/spotted/models/audiobook_retrieve_response.rb', line 19

class Chapters < Spotted::Internal::Type::BaseModel
  # @!attribute href
  #   A link to the Web API endpoint returning the full result of the request
  #
  #   @return [String]
  required :href, String

  # @!attribute limit
  #   The maximum number of items in the response (as set in the query or by default).
  #
  #   @return [Integer]
  required :limit, Integer

  # @!attribute next_
  #   URL to the next page of items. ( `null` if none)
  #
  #   @return [String, nil]
  required :next_, String, api_name: :next, nil?: true

  # @!attribute offset
  #   The offset of the items returned (as set in the query or by default)
  #
  #   @return [Integer]
  required :offset, Integer

  # @!attribute previous
  #   URL to the previous page of items. ( `null` if none)
  #
  #   @return [String, nil]
  required :previous, String, nil?: true

  # @!attribute total
  #   The total number of items available to return.
  #
  #   @return [Integer]
  required :total, Integer

  # @!attribute items
  #
  #   @return [Array<Spotted::Models::SimplifiedChapterObject>, nil]
  optional :items, -> { Spotted::Internal::Type::ArrayOf[Spotted::SimplifiedChapterObject] }

  # @!attribute published
  #   The playlist's public/private status (if it should be added to the user's
  #   profile or not): `true` the playlist will be public, `false` the playlist will
  #   be private, `null` the playlist status is not relevant. For more about
  #   public/private status, see
  #   [Working with Playlists](/documentation/web-api/concepts/playlists)
  #
  #   @return [Boolean, nil]
  optional :published, Spotted::Internal::Type::Boolean

  # @!method initialize(href:, limit:, next_:, offset:, previous:, total:, items: nil, published: nil)
  #   Some parameter documentations has been truncated, see
  #   {Spotted::Models::AudiobookRetrieveResponse::Chapters} for more details.
  #
  #   The chapters of the audiobook.
  #
  #   @param href [String] A link to the Web API endpoint returning the full result of the request
  #
  #   @param limit [Integer] The maximum number of items in the response (as set in the query or by default).
  #
  #   @param next_ [String, nil] URL to the next page of items. ( `null` if none)
  #
  #   @param offset [Integer] The offset of the items returned (as set in the query or by default)
  #
  #   @param previous [String, nil] URL to the previous page of items. ( `null` if none)
  #
  #   @param total [Integer] The total number of items available to return.
  #
  #   @param items [Array<Spotted::Models::SimplifiedChapterObject>]
  #
  #   @param published [Boolean] The playlist's public/private status (if it should be added to the user's profil
end

Instance Attribute Details

#hrefString

A link to the Web API endpoint returning the full result of the request

Returns:

  • (String)


24
# File 'lib/spotted/models/audiobook_retrieve_response.rb', line 24

required :href, String

#itemsArray<Spotted::Models::SimplifiedChapterObject>?



59
# File 'lib/spotted/models/audiobook_retrieve_response.rb', line 59

optional :items, -> { Spotted::Internal::Type::ArrayOf[Spotted::SimplifiedChapterObject] }

#limitInteger

The maximum number of items in the response (as set in the query or by default).

Returns:

  • (Integer)


30
# File 'lib/spotted/models/audiobook_retrieve_response.rb', line 30

required :limit, Integer

#next_String?

URL to the next page of items. ( ‘null` if none)

Returns:

  • (String, nil)


36
# File 'lib/spotted/models/audiobook_retrieve_response.rb', line 36

required :next_, String, api_name: :next, nil?: true

#offsetInteger

The offset of the items returned (as set in the query or by default)

Returns:

  • (Integer)


42
# File 'lib/spotted/models/audiobook_retrieve_response.rb', line 42

required :offset, Integer

#previousString?

URL to the previous page of items. ( ‘null` if none)

Returns:

  • (String, nil)


48
# File 'lib/spotted/models/audiobook_retrieve_response.rb', line 48

required :previous, String, nil?: true

#publishedBoolean?

The playlist’s public/private status (if it should be added to the user’s profile or not): ‘true` the playlist will be public, `false` the playlist will be private, `null` the playlist status is not relevant. For more about public/private status, see [Working with Playlists](/documentation/web-api/concepts/playlists)

Returns:

  • (Boolean, nil)


69
# File 'lib/spotted/models/audiobook_retrieve_response.rb', line 69

optional :published, Spotted::Internal::Type::Boolean

#totalInteger

The total number of items available to return.

Returns:

  • (Integer)


54
# File 'lib/spotted/models/audiobook_retrieve_response.rb', line 54

required :total, Integer