Commit 9f93b7f5 authored by Marius Gedminas's avatar Marius Gedminas

Typo fixes

parent cb8fe119
...@@ -22,9 +22,9 @@ $Id$ ...@@ -22,9 +22,9 @@ $Id$
# Persistent classes are non-ghostable. This has some interesting # Persistent classes are non-ghostable. This has some interesting
# ramifications: # ramifications:
# #
# - When an object is invalidated, it must reload it's state # - When an object is invalidated, it must reload its state
# #
# - When an object is loaded from the database, it's state must be # - When an object is loaded from the database, its state must be
# loaded. Unfortunately, there isn't a clear signal when an object is # loaded. Unfortunately, there isn't a clear signal when an object is
# loaded from the database. This should probably be fixed. # loaded from the database. This should probably be fixed.
# #
...@@ -65,7 +65,7 @@ class _p_DataDescr(object): ...@@ -65,7 +65,7 @@ class _p_DataDescr(object):
class _p_oid_or_jar_Descr(_p_DataDescr): class _p_oid_or_jar_Descr(_p_DataDescr):
# Special descr for _p_oid and _p_jar that loads # Special descr for _p_oid and _p_jar that loads
# state when set if both are set and and _p_changed is None # state when set if both are set and _p_changed is None
# #
# See notes above # See notes above
...@@ -84,7 +84,7 @@ class _p_oid_or_jar_Descr(_p_DataDescr): ...@@ -84,7 +84,7 @@ class _p_oid_or_jar_Descr(_p_DataDescr):
jar.setstate(inst) jar.setstate(inst)
class _p_ChangedDescr(object): class _p_ChangedDescr(object):
# descriptor to handle special weird emantics of _p_changed # descriptor to handle special weird semantics of _p_changed
def __get__(self, inst, cls): def __get__(self, inst, cls):
if inst is None: if inst is None:
......
...@@ -39,7 +39,7 @@ the methods outside of the class. Why? Because all of the items in a ...@@ -39,7 +39,7 @@ the methods outside of the class. Why? Because all of the items in a
persistent class must be picklable. We defined the methods as global persistent class must be picklable. We defined the methods as global
functions to make them picklable. functions to make them picklable.
Also note that we explictly set the module. Persistent classes don't Also note that we explicitly set the module. Persistent classes don't
live in normal Python modules. Rather, they live in the database. We live in normal Python modules. Rather, they live in the database. We
use information in ``__module__`` to record where in the database. When use information in ``__module__`` to record where in the database. When
we want to use a database, we will need to supply a custom class we want to use a database, we will need to supply a custom class
...@@ -138,7 +138,7 @@ We can open another connection and access the class there. ...@@ -138,7 +138,7 @@ We can open another connection and access the class there.
>>> c2.bar() >>> c2.bar()
bar other bar other
If we make changes without commiting them: If we make changes without committing them:
>>> C.bar = baz >>> C.bar = baz
>>> c.bar() >>> c.bar()
...@@ -225,7 +225,7 @@ able to access the root object and it must be loaded first. If the ...@@ -225,7 +225,7 @@ able to access the root object and it must be loaded first. If the
instance was in the root object, we'd be unable to create it while instance was in the root object, we'd be unable to create it while
loading the root object. loading the root object.
Now, if we try to load it, we get a broken oject: Now, if we try to load it, we get a broken object:
>>> connection2.sync() >>> connection2.sync()
>>> connection2.root()['obs']['p'] >>> connection2.root()['obs']['p']
...@@ -286,6 +286,6 @@ share the same class: ...@@ -286,6 +286,6 @@ share the same class:
True True
>>> tm.abort() >>> tm.abort()
XXX test abort of import XXX test abort of import
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment