Class: Ralph::CLI::Commands::Get

Inherits:
Base
  • Object
show all
Defined in:
lib/ralph/cli/commands/get.rb

Class Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Base

#gen_client

Class Attribute Details

.pathObject

Returns the value of attribute path.



4
5
6
# File 'lib/ralph/cli/commands/get.rb', line 4

def path
  @path
end

Instance Method Details

#call(**options) ⇒ Object



13
14
15
16
# File 'lib/ralph/cli/commands/get.rb', line 13

def call(**options)
  client = gen_client
  puts JSON.dump(client.get(path, options).body)
end

#pathObject



6
7
8
# File 'lib/ralph/cli/commands/get.rb', line 6

def path
  self.class.path
end

#path=(v) ⇒ Object



9
10
11
# File 'lib/ralph/cli/commands/get.rb', line 9

def path=(v)
  self.class.path = v
end