aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRalph Sennhauser <sera@gentoo.org>2013-12-28 11:49:39 +0100
committerRalph Sennhauser <sera@gentoo.org>2013-12-28 13:28:00 +0100
commita98d389c9bbc5f691938780c22557533fb885e8b (patch)
treec68930ff47135e9d2c6d41aa8314c9b7ff994258
parentShould be instance variables (diff)
downloadjava-config-a98d389c9bbc5f691938780c22557533fb885e8b.tar.gz
java-config-a98d389c9bbc5f691938780c22557533fb885e8b.tar.bz2
java-config-a98d389c9bbc5f691938780c22557533fb885e8b.zip
Rename variable active to active_vm
Self-documenting code is good
-rw-r--r--src/java_config_2/EnvironmentManager.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/java_config_2/EnvironmentManager.py b/src/java_config_2/EnvironmentManager.py
index ab83dd1..d573d64 100644
--- a/src/java_config_2/EnvironmentManager.py
+++ b/src/java_config_2/EnvironmentManager.py
@@ -24,7 +24,7 @@ class EnvironmentManager(object):
self.virtuals = {}
self.virtuals_pref = None
self.virtual_machines = None
- self.active = None
+ self.active_vm = None
self.eprefix = eprefix
self.eroot = root + eprefix
@@ -107,7 +107,7 @@ class EnvironmentManager(object):
if vm_name:
vm = self.get_vm(vm_name)
if vm:
- self.active = vm
+ self.active_vm = vm
return vm
for link in self.vm_links():
@@ -115,17 +115,17 @@ class EnvironmentManager(object):
vm_name = basename(os.readlink(link))
vm = self.get_vm(vm_name)
if vm:
- self.active = vm
+ self.active_vm = vm
return vm
raise InvalidVMError("Unable to determine valid vm. Please see http://www.gentoo.org/doc/en/java.xml#doc_chap4")
def set_active_vm(self, vm):
- self.active = vm
+ self.active_vm = vm
def get_active_vm(self):
- if self.active is None:
+ if self.active_vm is None:
self.load_active_vm()
- return self.active
+ return self.active_vm
def get_virtual_machines(self):
if self.virtual_machines is None: