Note that I want to rename configure to setup
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
# Copyright (c) 2012-2015, Eucalyptus Systems, Inc.
|
||||
# Copyright (c) 2012-2016 Hewlett Packard Enterprise Development LP
|
||||
#
|
||||
# Permission to use, copy, modify, and/or distribute this software for
|
||||
# any purpose with or without fee is hereby granted, provided that the
|
||||
@@ -35,6 +35,7 @@ class BaseAuth(object):
|
||||
self.log.level = loglevel
|
||||
|
||||
def configure(self):
|
||||
# TODO: rename this to setup
|
||||
pass
|
||||
|
||||
def apply_to_request(self, request, service):
|
||||
|
||||
@@ -270,18 +270,9 @@ class BaseCommand(object):
|
||||
route[key] = val
|
||||
|
||||
def configure(self):
|
||||
import pprint
|
||||
#pprint.pprint(self._cli_parser.__dict__)
|
||||
#for arg in self._cli_parser.args:
|
||||
for arg in self.ARGS:
|
||||
pprint.pprint(arg.__dict__)
|
||||
# TODO: Come up with something that can enforce arg constraints based
|
||||
# on the info we can get from self._cli_parser
|
||||
# TODO: rename this to setup
|
||||
pass
|
||||
|
||||
def setup(self):
|
||||
pass ## TODO
|
||||
|
||||
@classmethod
|
||||
def run(cls):
|
||||
try:
|
||||
|
||||
@@ -127,6 +127,7 @@ class BaseRequest(BaseCommand):
|
||||
self.auth.args.update(self.args)
|
||||
|
||||
def configure(self):
|
||||
# TODO: rename this to setup
|
||||
BaseCommand.configure(self)
|
||||
if self.service is not None:
|
||||
self.service.configure()
|
||||
|
||||
@@ -72,6 +72,8 @@ class BaseService(RegionConfigurableMixin):
|
||||
return new
|
||||
|
||||
def configure(self):
|
||||
# TODO: rename this to setup
|
||||
#
|
||||
# Configure user and region before grabbing endpoint info since
|
||||
# the latter may depend upon the former
|
||||
self.update_config_view()
|
||||
|
||||
Reference in New Issue
Block a user