From 8155427474847368a7dee8c9d18d138d24f967fc Mon Sep 17 00:00:00 2001 From: jlgijsbers Date: Sun, 16 Nov 2003 18:41:40 +0000 Subject: [PATCH] - Remove implementations of Class.getnode from back_anydbm and rdbms_common, it's already in hyperdb.Class. - Implementations of hyperdb.Database do need to implement the getnode method themselves. git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@1995 57a73879-2fb5-44c3-a270-3262357dd7e2 --- roundup/backends/back_anydbm.py | 13 +------------ roundup/backends/rdbms_common.py | 12 +----------- roundup/hyperdb.py | 6 +++--- 3 files changed, 5 insertions(+), 26 deletions(-) diff --git a/roundup/backends/back_anydbm.py b/roundup/backends/back_anydbm.py index d2897ad..d6aebc4 100644 --- a/roundup/backends/back_anydbm.py +++ b/roundup/backends/back_anydbm.py @@ -15,7 +15,7 @@ # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. # -#$Id: back_anydbm.py,v 1.131 2003-11-14 00:11:18 richard Exp $ +#$Id: back_anydbm.py,v 1.132 2003-11-16 18:41:40 jlgijsbers Exp $ ''' This module defines a backend that saves the hyperdatabase in a database chosen by anydbm. It is guaranteed to always be available in python @@ -1094,17 +1094,6 @@ class Class(hyperdb.Class): return d[propname] - # not in spec - def getnode(self, nodeid, cache=1): - ''' Return a convenience wrapper for the node. - - 'nodeid' must be the id of an existing node of this class or an - IndexError is raised. - - 'cache' exists for backwards compatibility, and is not used. - ''' - return Node(self, nodeid) - def set(self, nodeid, **propvalues): '''Modify a property on an existing node of this class. diff --git a/roundup/backends/rdbms_common.py b/roundup/backends/rdbms_common.py index 627ecec..bdb60ac 100644 --- a/roundup/backends/rdbms_common.py +++ b/roundup/backends/rdbms_common.py @@ -1,4 +1,4 @@ -# $Id: rdbms_common.py,v 1.70 2003-11-14 00:11:19 richard Exp $ +# $Id: rdbms_common.py,v 1.71 2003-11-16 18:41:40 jlgijsbers Exp $ ''' Relational database (SQL) backend common code. Basics: @@ -1373,16 +1373,6 @@ class Class(hyperdb.Class): return d[propname] - def getnode(self, nodeid, cache=1): - ''' Return a convenience wrapper for the node. - - 'nodeid' must be the id of an existing node of this class or an - IndexError is raised. - - 'cache' exists for backwards compatibility, and is not used. - ''' - return Node(self, nodeid) - def set(self, nodeid, **propvalues): '''Modify a property on an existing node of this class. diff --git a/roundup/hyperdb.py b/roundup/hyperdb.py index 245b917..2933a99 100644 --- a/roundup/hyperdb.py +++ b/roundup/hyperdb.py @@ -15,7 +15,7 @@ # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. # -# $Id: hyperdb.py,v 1.91 2003-11-11 00:35:13 richard Exp $ +# $Id: hyperdb.py,v 1.92 2003-11-16 18:41:40 jlgijsbers Exp $ """ Hyperdatabase implementation, especially field types. @@ -163,8 +163,7 @@ transaction. Implementation -------------- -All methods except __repr__ and getnode must be implemented by a -concrete backend Class. +All methods except __repr__ must be implemented by a concrete backend Database. ''' @@ -374,6 +373,7 @@ class Class: """ raise NotImplementedError + # not in spec def getnode(self, nodeid, cache=1): ''' Return a convenience wrapper for the node. -- 2.30.2