Commit 3ed14841 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent 4dc558f1
...@@ -139,7 +139,6 @@ func (e *wrongClassError) Error() string { ...@@ -139,7 +139,6 @@ func (e *wrongClassError) Error() string {
return fmt.Sprintf("wrong class: want %q; have %q", e.want, e.have) return fmt.Sprintf("wrong class: want %q; have %q", e.want, e.have)
} }
// get is like Get, but used when we already know object class. // get is like Get, but used when we already know object class.
// //
// Use-case: in ZODB references are (pyclass, oid), so new ghost is created // Use-case: in ZODB references are (pyclass, oid), so new ghost is created
...@@ -173,7 +172,6 @@ func (conn *Connection) get(class string, oid Oid) (IPersistent, error) { ...@@ -173,7 +172,6 @@ func (conn *Connection) get(class string, oid Oid) (IPersistent, error) {
return obj, nil return obj, nil
} }
// Get returns in-RAM object corresponding to specified ZODB object according to current database view. // Get returns in-RAM object corresponding to specified ZODB object according to current database view.
// //
// If there is already in-RAM object that corresponds to oid, that in-RAM object is returned. // If there is already in-RAM object that corresponds to oid, that in-RAM object is returned.
...@@ -221,16 +219,12 @@ func (conn *Connection) Get(ctx context.Context, oid Oid) (_ IPersistent, err er ...@@ -221,16 +219,12 @@ func (conn *Connection) Get(ctx context.Context, oid Oid) (_ IPersistent, err er
return obj, nil return obj, nil
} }
// load loads object specified by oid. // load loads object specified by oid.
func (conn *Connection) load(ctx context.Context, oid Oid) (_ *mem.Buf, serial Tid, _ error) { func (conn *Connection) load(ctx context.Context, oid Oid) (_ *mem.Buf, serial Tid, _ error) {
conn.checkTxnCtx(ctx, "load") conn.checkTxnCtx(ctx, "load")
return conn.stor.Load(ctx, Xid{Oid: oid, At: conn.at}) return conn.stor.Load(ctx, Xid{Oid: oid, At: conn.at})
} }
// ---------------------------------------- // ----------------------------------------
// checkTxnCtx asserts that current transaction is the same as conn.txn . // checkTxnCtx asserts that current transaction is the same as conn.txn .
......
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