ch01-12: clean up by @eumiro

This commit is contained in:
Luciano Ramalho
2021-02-14 20:28:07 -03:00
parent 584a7f21ca
commit 03ace4f4ae
33 changed files with 1383 additions and 86 deletions

View File

@@ -1,3 +1,6 @@
#!/usr/bin/env jython
# NOTE: Jython is still Python 2.7 in late2020
from java.lang.reflect import Modifier
import Confidential
@@ -7,5 +10,5 @@ for field in fields:
# list private fields only
if Modifier.isPrivate(field.getModifiers()):
field.setAccessible(True) # break the lock
print('field:', field)
print('\t', field.getName(), '=', field.get(message))
print 'field:', field
print '\t', field.getName(), '=', field.get(message)