Class: WavefrontCommandMetricspolicy

Inherits:
WavefrontCommandBase show all
Defined in:
lib/wavefront-cli/commands/metricspolicy.rb

Overview

Define the metricspolicy command.

Instance Method Summary collapse

Methods inherited from WavefrontCommandBase

#acl_commands, #commands, #common_options, #description, #docopt, #global_option_text, #global_options, #opt_row, #option_column_width, #options, #postscript, #sdk_file, #tag_commands, #word

Instance Method Details

#_commandsObject



20
21
22
23
24
25
# File 'lib/wavefront-cli/commands/metricspolicy.rb', line 20

def _commands
  ["describe #{CMN} [-v version]",
   "history #{CMN} [-o offset] [-L limit]",
   "revert #{CMN} <version>",
   "update #{CMN} <file>"]
end

#_optionsObject



27
28
29
30
31
32
# File 'lib/wavefront-cli/commands/metricspolicy.rb', line 27

def _options
  [common_options,
   "-o, --offset=n           start from nth #{thing}",
   "-L, --limit=COUNT        number of #{things} or revisions to list",
   "-v, --version=INTEGER    version of #{thing}"]
end

#sdk_classObject



16
17
18
# File 'lib/wavefront-cli/commands/metricspolicy.rb', line 16

def sdk_class
  'MetricsPolicy'
end

#thingObject



8
9
10
# File 'lib/wavefront-cli/commands/metricspolicy.rb', line 8

def thing
  'metrics policy'
end

#thingsObject



12
13
14
# File 'lib/wavefront-cli/commands/metricspolicy.rb', line 12

def things
  'metrics policies'
end