Fix some reST field lists in docstrings
Probably the most common format for documenting arguments is reST field lists [1]. This change updates some docstrings to comply with the field lists syntax. [1] http://sphinx-doc.org/domains.html#info-field-lists Change-Id: I1e4221e886a75177c4607817a78dbcda37dfa57a
This commit is contained in:
parent
329d9b5c87
commit
535e2bf4b8
|
@ -57,8 +57,8 @@ class ACLBehaviors(base_behaviors.BaseBehaviors):
|
|||
def acl_delete(self, entity_ref):
|
||||
"""Delete a secret or container acl
|
||||
|
||||
:param entity_ref Reference to secret or container entity
|
||||
:return If error returns stderr string otherwise returns None.
|
||||
:param entity_ref: Reference to secret or container entity
|
||||
:return: If error returns stderr string otherwise returns None.
|
||||
"""
|
||||
argv = ['acl', 'delete']
|
||||
self.add_auth_and_endpoint(argv)
|
||||
|
@ -74,8 +74,8 @@ class ACLBehaviors(base_behaviors.BaseBehaviors):
|
|||
def acl_get(self, entity_ref):
|
||||
"""Get a 'read' ACL setting for a secret or a container.
|
||||
|
||||
:param entity_ref Reference to secret or container entity
|
||||
:return dict of 'read' operation ACL settings if found otherwise empty
|
||||
:param entity_ref: Reference to secret or container entity
|
||||
:return: dict of 'read' operation ACL settings if found otherwise empty
|
||||
dict in case of error.
|
||||
"""
|
||||
argv = ['acl', 'get']
|
||||
|
@ -95,14 +95,14 @@ class ACLBehaviors(base_behaviors.BaseBehaviors):
|
|||
operation_type='read'):
|
||||
"""Submits a secret or container ACL
|
||||
|
||||
:param entity_ref Reference to secret or container entity
|
||||
:param users List of users for ACL
|
||||
:param entity_ref: Reference to secret or container entity
|
||||
:param users: List of users for ACL
|
||||
:param project_access: Flag to pass for project access behavior
|
||||
:param use_short_arg: Flag to indicate if use short arguments in cli.
|
||||
Default is False
|
||||
:param operation_type: ACL operation type. Default is 'read' as
|
||||
Barbican currently supports only that type of operation.
|
||||
:return dict of 'read' operation ACL settings if found otherwise empty
|
||||
:return: dict of 'read' operation ACL settings if found otherwise empty
|
||||
dict in case of error.
|
||||
"""
|
||||
argv = ['acl', 'submit']
|
||||
|
@ -128,14 +128,14 @@ class ACLBehaviors(base_behaviors.BaseBehaviors):
|
|||
operation_type='read'):
|
||||
"""Add to a secret or container ACL
|
||||
|
||||
:param entity_ref Reference to secret or container entity
|
||||
:param users List of users to be added in ACL
|
||||
:param entity_ref: Reference to secret or container entity
|
||||
:param users: List of users to be added in ACL
|
||||
:param project_access: Flag to pass for project access behavior
|
||||
:param use_short_arg: Flag to indicate if use short arguments in cli.
|
||||
Default is False
|
||||
:param operation_type: ACL operation type. Default is 'read' as
|
||||
Barbican currently supports only that type of operation.
|
||||
:return dict of 'read' operation ACL settings if found otherwise empty
|
||||
:return: dict of 'read' operation ACL settings if found otherwise empty
|
||||
dict in case of error.
|
||||
"""
|
||||
argv = ['acl', 'user', 'add']
|
||||
|
@ -162,14 +162,14 @@ class ACLBehaviors(base_behaviors.BaseBehaviors):
|
|||
operation_type='read'):
|
||||
"""Remove users from a secret or container ACL
|
||||
|
||||
:param entity_ref Reference to secret or container entity
|
||||
:param users List of users to be removed from ACL
|
||||
:param entity_ref: Reference to secret or container entity
|
||||
:param users: List of users to be removed from ACL
|
||||
:param project_access: Flag to pass for project access behavior
|
||||
:param use_short_arg: Flag to indicate if use short arguments in cli.
|
||||
Default is False
|
||||
:param operation_type: ACL operation type. Default is 'read' as
|
||||
Barbican currently supports only that type of operation.
|
||||
:return dict of 'read' operation ACL settings if found otherwise empty
|
||||
:return: dict of 'read' operation ACL settings if found otherwise empty
|
||||
dict in case of error.
|
||||
"""
|
||||
argv = ['acl', 'user', 'remove']
|
||||
|
|
|
@ -62,7 +62,7 @@ class ContainerBehaviors(base_behaviors.BaseBehaviors):
|
|||
"""Get a container
|
||||
|
||||
:param: the href to a container
|
||||
:return dict of container values, or an empty dict if the container
|
||||
:return: dict of container values, or an empty dict if the container
|
||||
is not found.
|
||||
"""
|
||||
argv = ['secret', 'container', 'get']
|
||||
|
|
|
@ -83,7 +83,7 @@ class SecretBehaviors(base_behaviors.BaseBehaviors):
|
|||
"""Get a secret
|
||||
|
||||
:param: the href to a secret
|
||||
:return dict of secret values, or an empty dict if the secret
|
||||
:return: dict of secret values, or an empty dict if the secret
|
||||
is not found.
|
||||
"""
|
||||
argv = ['secret', 'get']
|
||||
|
@ -104,7 +104,7 @@ class SecretBehaviors(base_behaviors.BaseBehaviors):
|
|||
:param: the href to a secret
|
||||
:param raw if True then add "-f value" to get raw payload (ie not
|
||||
within a PrettyTable). If False then omit -f.
|
||||
:return string representing the secret payload.
|
||||
:return: string representing the secret payload.
|
||||
"""
|
||||
argv = ['secret', 'get']
|
||||
self.add_auth_and_endpoint(argv)
|
||||
|
|
|
@ -126,7 +126,7 @@ def create_timestamp_w_tz_and_offset(timezone=None, days=0, hours=0, minutes=0,
|
|||
:param hours: The offset in hours
|
||||
:param minutes: The offset in minutes
|
||||
|
||||
:return a timestamp
|
||||
:return: a timestamp
|
||||
"""
|
||||
if timezone is None:
|
||||
timezone = time.strftime("%z")
|
||||
|
|
Loading…
Reference in New Issue