Class: PlayTime::Promote
- Inherits:
-
Object
- Object
- PlayTime::Promote
- Defined in:
- lib/play_time/promote.rb
Instance Attribute Summary collapse
-
#client ⇒ Object
readonly
Returns the value of attribute client.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(client) ⇒ Promote
constructor
A new instance of Promote.
- #promote(track, version_code) ⇒ Object
Constructor Details
#initialize(client) ⇒ Promote
Returns a new instance of Promote.
13 14 15 |
# File 'lib/play_time/promote.rb', line 13 def initialize(client) @client = client end |
Instance Attribute Details
#client ⇒ Object (readonly)
Returns the value of attribute client.
11 12 13 |
# File 'lib/play_time/promote.rb', line 11 def client @client end |
Class Method Details
.promote(track, version_code) ⇒ Object
6 7 8 |
# File 'lib/play_time/promote.rb', line 6 def promote(track, version_code) new(Client.new).promote(track, version_code) end |
Instance Method Details
#promote(track, version_code) ⇒ Object
17 18 19 20 |
# File 'lib/play_time/promote.rb', line 17 def promote(track, version_code) client. client.update(track, version_code) end |