[Zope3-checkins] CVS: Zope3/src/zope/app - _app.py:1.1.2.2 configure.zcml:1.1.2.2 dependable.py:1.1.2.2 rdb.py:1.1.2.2
Jim Fulton
jim@zope.com
Tue, 24 Dec 2002 07:51:45 -0500
Update of /cvs-repository/Zope3/src/zope/app
In directory cvs.zope.org:/tmp/cvs-serv1158/src/zope/app
Modified Files:
Tag: NameGeddon-branch
_app.py configure.zcml dependable.py rdb.py
Log Message:
Searched for and changed over 1200 references to Zope.something.
Most of these were either comments, doc strings, or permission ids.
Many were imports or ids in zcml. (much zcml fixup is still needed.
=== Zope3/src/zope/app/_app.py 1.1.2.1 => 1.1.2.2 ===
--- Zope3/src/zope/app/_app.py:1.1.2.1 Mon Dec 23 14:30:56 2002
+++ Zope3/src/zope/app/_app.py Tue Dec 24 07:50:44 2002
@@ -68,7 +68,7 @@
# XXX When bootstrapping a new database, the following will fail
# while trying to add services when no config_file was passed
# to Application() below. So, don't do that. :-)
- from Zope.App.StartUp import bootstrap
+ from zope.app.startup import bootstrap
bootstrap.bootstrapInstance(db)
return db
=== Zope3/src/zope/app/configure.zcml 1.1.2.1 => 1.1.2.2 ===
--- Zope3/src/zope/app/configure.zcml:1.1.2.1 Mon Dec 23 14:30:56 2002
+++ Zope3/src/zope/app/configure.zcml Tue Dec 24 07:50:44 2002
@@ -28,8 +28,8 @@
>
<browser:view
- permission="Zope.ManageContent"
- factory="Zope.App.Undo." >
+ permission="zope.ManageContent"
+ factory="zope.app.undo.Undo" >
<browser:page name="undoForm.html" attribute="index" />
<browser:page name="undo.html" attribute="action" />
@@ -44,25 +44,25 @@
<content class="zope.app.rdb.ZopeConnection">
<require
- permission="Zope.ManageContent"
+ permission="zope.ManageContent"
interface="zope.app.interfaces.rdb.IZopeConnection" />
</content>
<content class="zope.app.rdb.ZopeCursor">
<require
- permission="Zope.ManageContent"
+ permission="zope.ManageContent"
interface="zope.app.interfaces.rdb.IZopeCursor" />
</content>
<content class="zope.app.rdb.ResultSet">
<require
- permission="Zope.ManageContent"
+ permission="zope.ManageContent"
interface="zope.app.interfaces.rdb.IResultSet" />
</content>
<content class="zope.app.rdb.Row">
<require
- permission="Zope.ManageContent"
+ permission="zope.ManageContent"
attributes="__getattr__" />
</content>
@@ -101,8 +101,8 @@
xmlns:browser='http://namespaces.zope.org/browser'>
<adapter
- factory="Zope.App.OFS.Introspector."
- permission="Zope.View"
+ factory="zope.app.introspector.Introspector"
+ permission="zope.View"
provides="zope.app.interfaces.introspector.IIntrospector" />
<include package=".Browser" />
=== Zope3/src/zope/app/dependable.py 1.1.2.1 => 1.1.2.2 ===
--- Zope3/src/zope/app/dependable.py:1.1.2.1 Mon Dec 23 14:30:56 2002
+++ Zope3/src/zope/app/dependable.py Tue Dec 24 07:50:44 2002
@@ -22,7 +22,7 @@
import IAnnotations
from zope.component import getAdapter
-key = 'Zope.App.DependencyFramework.Dependents'
+key = 'zope.app.dependable.Dependents'
class Dependable:
__doc__ = IDependable.__doc__
@@ -34,18 +34,18 @@
def addDependent(self, location):
- "See Zope.App.DependencyFramework.IDependable.IDependable"
+ "See IDependable"
annotations = getAdapter(self.context, IAnnotations)
annotations [key] = annotations.get(key, ()) + (location, )
def removeDependent(self, location):
- "See Zope.App.DependencyFramework.IDependable.IDependable"
+ "See IDependable"
annotations = getAdapter(self.context, IAnnotations)
annotations[key] = tuple([loc
for loc in annotations.get(key, ())
if loc != location])
def dependents(self):
- "See Zope.App.DependencyFramework.IDependable.IDependable"
+ "See IDependable"
annotations = getAdapter(self.context, IAnnotations)
return annotations.get(key, ())
=== Zope3/src/zope/app/rdb.py 1.1.2.1 => 1.1.2.2 ===
--- Zope3/src/zope/app/rdb.py:1.1.2.1 Mon Dec 23 14:30:56 2002
+++ Zope3/src/zope/app/rdb.py Tue Dec 24 07:50:44 2002
@@ -86,12 +86,8 @@
self.connectionName = connection_name
self.sql = sql
- ############################################################
- # Implementation methods for interface
- # Zope.App.RDB.ISQLCommand.
-
def getConnection(self):
- 'See Zope.App.RDB.ISQLCommand.ISQLCommand'
+ 'See ISQLCommand'
connection_service = getNextService(self, "SQLDatabaseConnections")
connection = connection_service.getConnection(self.connectionName)
return connection
@@ -99,9 +95,6 @@
def __call__(self):
return queryForResults(self.getConnection(), self.sql)
- #
- ############################################################
-
"""The connection adapters contained by ConnectionService.
@@ -129,59 +122,45 @@
"""This method should be overwritten by all subclasses"""
conn_info = parseDSN(self.dsn)
- ############################################################
- # Implementation methods for interface
- # Zope.App.RDB.IZopeDatabaseAdapter.
-
def setDSN(self, dsn):
- 'See Zope.App.RDB.IZopeDatabaseAdapter.IZopeDatabaseAdapter'
+ 'See IZopeDatabaseAdapter'
assert dsn.startswith('dbi://'), "The DSN has to start with 'dbi://'"
self.dsn = dsn
def getDSN(self):
- 'See Zope.App.RDB.IZopeDatabaseAdapter.IZopeDatabaseAdapter'
+ 'See IZopeDatabaseAdapter'
return self.dsn
def connect(self):
- 'See Zope.App.RDB.IZopeDatabaseAdapter.IZopeDatabaseAdapter'
+ 'See IZopeDatabaseAdapter'
if not self.isConnected():
self._v_connection = ZopeConnection(self._connection_factory(),
self)
def disconnect(self):
- 'See Zope.App.RDB.IZopeDatabaseAdapter.IZopeDatabaseAdapter'
+ 'See IZopeDatabaseAdapter'
if self.isConnected():
self._v_connection.close()
self._v_connection = None
def isConnected(self):
- 'See Zope.App.RDB.IZopeDatabaseAdapter.IZopeDatabaseAdapter'
+ 'See IZopeDatabaseAdapter'
return hasattr(self, '_v_connection') and \
self._v_connection is not None
def __call__(self):
- 'See Zope.App.RDB.IZopeDatabaseAdapter.IZopeDatabaseAdapter'
+ 'See IZopeDatabaseAdapter'
self.connect()
return self._v_connection
- #
- ############################################################
-
- ############################################################
- # Implementation methods for interface
- # Zope.App.RDB.IDBITypeInfo.IDBITypeInfo
-
# Pessimistic defaults
paramstyle = 'pyformat'
threadsafety = 0
def getConverter(self, type):
- 'See Zope.App.RDB.IDBITypeInfo.IDBITypeInfo'
+ 'See IDBITypeInfo'
return identity
- #
- ############################################################
-
def identity(x):
return x
@@ -329,29 +308,29 @@
return getattr(self.conn, key)
def cursor(self):
- 'See Zope.App.RDB.IZopeConnection.IZopeConnection'
+ 'See IZopeConnection'
return ZopeCursor(self.conn.cursor(), self)
def registerForTxn(self):
- 'See Zope.App.RDB.IZopeConnection.IZopeConnection'
+ 'See IZopeConnection'
if not self._txn_registered:
tm = ZopeDBTransactionManager(self)
get_transaction().join(tm)
self._txn_registered = True
def commit(self):
- 'See Zope.App.RDB.IDBIConnection.IDBIConnection'
+ 'See IDBIConnection'
self._txn_registered = False
self.conn.commit()
def rollback(self):
- 'See Zope.App.RDB.IDBIConnection.IDBIConnection'
+ 'See IDBIConnection'
self._txn_registered = False
self.conn.rollback()
def getTypeInfo(self):
- 'See Zope.App.RDB.IDBITypeInfoProvider.IDBITypeInfoProvider'
+ 'See IDBITypeInfoProvider'
return self._type_info
@@ -429,7 +408,7 @@
"""
$Id$
"""
-from Zope.Security import Checker
+from zope.security import checker
class Row(object):
"""Represents a row in a ResultSet"""
@@ -457,7 +436,7 @@
"""Creates a Row object"""
klass_namespace = {}
- klass_namespace['__Security_checker__'] = Checker.NamesChecker(columns)
+ klass_namespace['__Security_checker__'] = checker.NamesChecker(columns)
klass_namespace['__slots__'] = tuple(columns)
return type('GeneratedRowClass', (Row,), klass_namespace)