Class: PowerBI::RefreshArray

Inherits:
Array
  • Object
show all
Defined in:
lib/power-bi/refresh.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Array

#reload

Constructor Details

#initialize(tenant, dataset) ⇒ RefreshArray

Returns a new instance of RefreshArray.



26
27
28
29
# File 'lib/power-bi/refresh.rb', line 26

def initialize(tenant, dataset)
  super(tenant, dataset)
  @dataset = dataset
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class PowerBI::Array

Class Method Details

.get_classObject



31
32
33
# File 'lib/power-bi/refresh.rb', line 31

def self.get_class
  Refresh
end

Instance Method Details

#get_dataObject



35
36
37
# File 'lib/power-bi/refresh.rb', line 35

def get_data
  @tenant.get("/groups/#{@dataset.workspace.id}/datasets/#{@dataset.id}/refreshes", {'$top': '1'})[:value]
end