Class: Azure::MediaServices::Mgmt::V2018_07_01::Models::LiveOutputListResult

Inherits:
Object
  • Object
show all
Includes:
MsRest::JSONable, MsRestAzure
Defined in:
lib/2018-07-01/generated/azure_mgmt_media_services/models/live_output_list_result.rb

Overview

The LiveOutput list result.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#next_methodObject

return [Proc] with next page method call.



28
29
30
# File 'lib/2018-07-01/generated/azure_mgmt_media_services/models/live_output_list_result.rb', line 28

def next_method
  @next_method
end

#odatacountInteger

Returns The number of result.

Returns:

  • (Integer)

    The number of result.



21
22
23
# File 'lib/2018-07-01/generated/azure_mgmt_media_services/models/live_output_list_result.rb', line 21

def odatacount
  @odatacount
end

contains incomplete list of Live Outputs.

Returns:

  • (String)

    Th link to the next set of results. Not empty if value



25
26
27
# File 'lib/2018-07-01/generated/azure_mgmt_media_services/models/live_output_list_result.rb', line 25

def odatanext_link
  @odatanext_link
end

#valueArray<LiveOutput>

operation.

Returns:

  • (Array<LiveOutput>)

    The result of the List Live Output



18
19
20
# File 'lib/2018-07-01/generated/azure_mgmt_media_services/models/live_output_list_result.rb', line 18

def value
  @value
end

Class Method Details

.mapperObject

Mapper for LiveOutputListResult class as Ruby Hash. This will be used for serialization/deserialization.



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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
# File 'lib/2018-07-01/generated/azure_mgmt_media_services/models/live_output_list_result.rb', line 63

def self.mapper()
  {
    client_side_validation: true,
    required: false,
    serialized_name: 'LiveOutputListResult',
    type: {
      name: 'Composite',
      class_name: 'LiveOutputListResult',
      model_properties: {
        value: {
          client_side_validation: true,
          required: false,
          serialized_name: 'value',
          type: {
            name: 'Sequence',
            element: {
                client_side_validation: true,
                required: false,
                serialized_name: 'LiveOutputElementType',
                type: {
                  name: 'Composite',
                  class_name: 'LiveOutput'
                }
            }
          }
        },
        odatacount: {
          client_side_validation: true,
          required: false,
          serialized_name: '@odata\\.count',
          type: {
            name: 'Number'
          }
        },
        odatanext_link: {
          client_side_validation: true,
          required: false,
          serialized_name: '@odata\\.nextLink',
          type: {
            name: 'String'
          }
        }
      }
    }
  }
end

Instance Method Details

#get_all_itemsArray<LiveOutput>

Gets the rest of the items for the request, enabling auto-pagination.

Returns:



35
36
37
38
39
40
41
42
43
# File 'lib/2018-07-01/generated/azure_mgmt_media_services/models/live_output_list_result.rb', line 35

def get_all_items
  items = @value
  page = self
  while page.odatanext_link != nil && !page.odatanext_link.strip.empty? do
    page = page.get_next_page
    items.concat(page.value)
  end
  items
end

#get_next_pageLiveOutputListResult

Gets the next page of results.

Returns:



50
51
52
53
54
55
56
57
# File 'lib/2018-07-01/generated/azure_mgmt_media_services/models/live_output_list_result.rb', line 50

def get_next_page
  response = @next_method.call(@odatanext_link).value! unless @next_method.nil?
  unless response.nil?
    @odatanext_link = response.body.odatanext_link
    @value = response.body.value
    self
  end
end