1.1 --- a/micropython/table.py Sat Jun 09 19:53:00 2012 +0200
1.2 +++ b/micropython/table.py Sat Jun 09 23:24:18 2012 +0200
1.3 @@ -3,7 +3,7 @@
1.4 """
1.5 Preparation of run-time attribute lookup tables.
1.6
1.7 -Copyright (C) 2007, 2008, 2009, 2010, 2011 Paul Boddie <paul@boddie.org.uk>
1.8 +Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012 Paul Boddie <paul@boddie.org.uk>
1.9
1.10 This program is free software; you can redistribute it and/or modify it under
1.11 the terms of the GNU General Public License as published by the Free Software
1.12 @@ -450,6 +450,18 @@
1.13 self.any_cache[names] = self._objects_plus_status(names, self.any_possible_objects)
1.14 return self.any_cache[names]
1.15
1.16 + def get_object(self, objname):
1.17 +
1.18 + """
1.19 + Return the object for the given 'objname' using a special entry in the
1.20 + table.
1.21 + """
1.22 +
1.23 + # NOTE: This depends on a special entry in the table for class
1.24 + # NOTE: equivalence tests.
1.25 +
1.26 + return self.access(objname, "#" + objname)
1.27 +
1.28 class ParameterTable(Table):
1.29
1.30 "A parameter table."