Changeset 3690
- Timestamp:
- 07/30/08 11:42:58 (4 months ago)
- Files:
-
- trunk/bknr/datastore/src/data/object.lisp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/bknr/datastore/src/data/object.lisp
r3689 r3690 455 455 ;; running Lisp image and objects of this class will be ignored. 456 456 (when class 457 (setf (next-object-id (store-object-subsystem)) object-id) 457 458 (let ((object (allocate-instance class))) 459 (assert (= object-id (slot-value object 'id))) 458 460 (dolist (index (class-slot-indices class 'id)) 459 (assert (= object-id (slot-value object 'id)))460 461 (index-add index object))))))) 461 462 … … 642 643 (defun make-object (class-name &rest initargs) 643 644 "Make a persistent object of class named CLASS-NAME. Calls MAKE-INSTANCE with INITARGS." 644 (with-store-guard () 645 (execute (make-instance 'transaction 646 :function-symbol 'tx-make-object 647 :args (append (list class-name 648 :id (next-object-id (store-object-subsystem))) 649 initargs))))) 645 (if (in-anonymous-transaction-p) 646 (apply #'make-instance class-name initargs) 647 (with-store-guard () 648 (execute (make-instance 'transaction 649 :function-symbol 'tx-make-object 650 :args (append (list class-name 651 :id (next-object-id (store-object-subsystem))) 652 initargs)))))) 650 653 651 654 (defun tx-delete-object (id)
