Merge "Fix some reST field lists in docstrings"
This commit is contained in:
commit
e97186372a
@ -584,7 +584,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")
|
||||
|
@ -85,7 +85,7 @@ class CABehaviors(base_behaviors.BaseBehaviors):
|
||||
:param user_name: The user name used to create the subCA
|
||||
:param admin: The user with permissions to delete the subCA
|
||||
:return: A tuple containing the response from the create
|
||||
and the href to the newly created subCA
|
||||
and the href to the newly created subCA
|
||||
"""
|
||||
|
||||
resp = self.client.post('cas', request_model=model,
|
||||
@ -113,7 +113,7 @@ class CABehaviors(base_behaviors.BaseBehaviors):
|
||||
:param expected_fail: If test is expected to fail the deletion
|
||||
:param use_auth: Boolean for whether to send authentication headers
|
||||
:param user_name: The user name used to delete the entity
|
||||
:return A request response object
|
||||
:return: A request response object
|
||||
"""
|
||||
resp = self.client.delete(ca_ref, extra_headers=extra_headers,
|
||||
use_auth=use_auth, user_name=user_name)
|
||||
|
@ -80,7 +80,7 @@ class OrderBehaviors(base_behaviors.BaseBehaviors):
|
||||
:param extra_headers: Optional HTTP headers to add to the request
|
||||
:param user_name: the user used to do the get
|
||||
:param use_auth: Boolean to determine whether auth headers are sent
|
||||
:return the response, a list of orders and the next/pref hrefs
|
||||
:return: the response, a list of orders and the next/pref hrefs
|
||||
"""
|
||||
params = {'limit': limit, 'offset': offset}
|
||||
|
||||
@ -116,7 +116,7 @@ class OrderBehaviors(base_behaviors.BaseBehaviors):
|
||||
list for housekeeping.
|
||||
:param user_name: the user used to do the delete
|
||||
:param use_auth: Boolean to determine whether auth headers are sent
|
||||
:return A request response object
|
||||
:return: A request response object
|
||||
"""
|
||||
resp = self.client.delete(order_ref, extra_headers=extra_headers,
|
||||
user_name=user_name, use_auth=use_auth)
|
||||
|
@ -32,7 +32,7 @@ class BaseModel(object):
|
||||
def obj_to_json(self):
|
||||
"""Convert this object to a JSON string.
|
||||
|
||||
:return A string of JSON containing the fields in this object
|
||||
:return: A string of JSON containing the fields in this object
|
||||
"""
|
||||
|
||||
return json.dumps(self.obj_to_dict())
|
||||
@ -43,7 +43,7 @@ class BaseModel(object):
|
||||
If there are fields that are not set in this object then those
|
||||
will NOT have entries in the returned dict.
|
||||
|
||||
:return A dict representing this model
|
||||
:return: A dict representing this model
|
||||
"""
|
||||
the_dict = self.__dict__
|
||||
retval = self._remove_empty_fields_from_dict(the_dict)
|
||||
@ -72,7 +72,7 @@ class BaseModel(object):
|
||||
"""Create a model from a JSON string.
|
||||
|
||||
:param serialized_str: the JSON string
|
||||
:return a secret object
|
||||
:return: a secret object
|
||||
"""
|
||||
try:
|
||||
json_dict = json.loads(serialized_str)
|
||||
@ -86,6 +86,6 @@ class BaseModel(object):
|
||||
"""Create an object from a dict.
|
||||
|
||||
:param input_dict: A dict of fields.
|
||||
:return a model object build from the passed in dict.
|
||||
:return: a model object build from the passed in dict.
|
||||
"""
|
||||
return cls(**input_dict)
|
||||
|
@ -202,7 +202,7 @@ class BarbicanClient(object):
|
||||
:param item_list: the json returned from a barbican GET request for
|
||||
a list of objects
|
||||
:param model_type: The model used in the creation of the list of models
|
||||
:return A list of models and the refs for next and previous lists.
|
||||
:return: A list of models and the refs for next and previous lists.
|
||||
"""
|
||||
|
||||
models, next_ref, prev_ref = [], None, None
|
||||
|
Loading…
Reference in New Issue
Block a user