summaryrefslogtreecommitdiff
path: root/lib/chef/api_client_v1.rb
diff options
context:
space:
mode:
authorTim Smith <tsmith@chef.io>2018-01-22 16:09:48 -0800
committerTim Smith <tsmith@chef.io>2018-01-22 16:09:48 -0800
commit98a89f1548de156d8995d8240a672df3d6e0f0dd (patch)
tree2dc456918db3f110a16079ef448c4fd4afe80d08 /lib/chef/api_client_v1.rb
parent9eb78fa2d0edb9366fc2bc34f9ec3954fda48261 (diff)
downloadchef-98a89f1548de156d8995d8240a672df3d6e0f0dd.tar.gz
Cleanup a bit of YARD and add a few things
Mostly remove some warnings when running yard on the CLI Signed-off-by: Tim Smith <tsmith@chef.io>
Diffstat (limited to 'lib/chef/api_client_v1.rb')
-rw-r--r--lib/chef/api_client_v1.rb13
1 files changed, 7 insertions, 6 deletions
diff --git a/lib/chef/api_client_v1.rb b/lib/chef/api_client_v1.rb
index a3a5780cc2..7fbff6d6ba 100644
--- a/lib/chef/api_client_v1.rb
+++ b/lib/chef/api_client_v1.rb
@@ -70,7 +70,7 @@ class Chef
# Gets or sets the client name.
#
- # @param [Optional String] The name must be alpha-numeric plus - and _.
+ # @param arg [Optional String] The name must be alpha-numeric plus - and _.
# @return [String] The current value of the name.
def name(arg = nil)
set_or_return(
@@ -82,7 +82,7 @@ class Chef
# Gets or sets whether this client is an admin.
#
- # @param [Optional True/False] Should be true or false - default is false.
+ # @param arg [Optional True/False] Should be true or false - default is false.
# @return [True/False] The current value
def admin(arg = nil)
set_or_return(
@@ -94,7 +94,7 @@ class Chef
# Gets or sets the public key.
#
- # @param [Optional String] The string representation of the public key.
+ # @param arg [Optional String] The string representation of the public key.
# @return [String] The current value.
def public_key(arg = nil)
set_or_return(
@@ -106,7 +106,7 @@ class Chef
# Gets or sets whether this client is a validator.
#
- # @param [Boolean] whether or not the client is a validator. If
+ # @param arg [Boolean] whether or not the client is a validator. If
# `nil`, retrieves the already-set value.
# @return [Boolean] The current value
def validator(arg = nil)
@@ -120,7 +120,7 @@ class Chef
# Private key. The server will return it as a string.
# Set to true under API V0 to have the server regenerate the default key.
#
- # @param [Optional String] The string representation of the private key.
+ # @param arg [Optional String] The string representation of the private key.
# @return [String] The current value.
def private_key(arg = nil)
set_or_return(
@@ -132,7 +132,7 @@ class Chef
# Used to ask server to generate key pair under api V1
#
- # @param [Optional True/False] Should be true or false - default is false.
+ # @param arg [Optional True/False] Should be true or false - default is false.
# @return [True/False] The current value
def create_key(arg = nil)
set_or_return(
@@ -200,6 +200,7 @@ class Chef
end
# Load a client by name via the API
+ # @param name [String] the client name
def self.load(name)
response = http_api.get("clients/#{name}")
Chef::ApiClientV1.from_hash(response)