You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by da...@apache.org on 2015/09/10 14:07:34 UTC
[35/50] [abbrv] isis git commit: ISIS-1194: renamed
PersistenceSession#destroyObject to ...InTransaction
ISIS-1194: renamed PersistenceSession#destroyObject to ...InTransaction
Project: http://git-wip-us.apache.org/repos/asf/isis/repo
Commit: http://git-wip-us.apache.org/repos/asf/isis/commit/05f54a0a
Tree: http://git-wip-us.apache.org/repos/asf/isis/tree/05f54a0a
Diff: http://git-wip-us.apache.org/repos/asf/isis/diff/05f54a0a
Branch: refs/heads/ISIS-1194
Commit: 05f54a0ab5f5b1f3480f9a159d53af2f2742274a
Parents: 63000d6
Author: Dan Haywood <da...@haywood-associates.co.uk>
Authored: Thu Sep 10 10:09:16 2015 +0100
Committer: Dan Haywood <da...@haywood-associates.co.uk>
Committed: Thu Sep 10 10:09:16 2015 +0100
----------------------------------------------------------------------
.../persistence/internal/RuntimeContextFromSession.java | 2 +-
.../core/runtime/system/persistence/PersistenceSession.java | 8 ++++----
.../runtime/system/persistence/PersistenceSessionTest.java | 4 ++--
3 files changed, 7 insertions(+), 7 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/isis/blob/05f54a0a/core/runtime/src/main/java/org/apache/isis/core/runtime/persistence/internal/RuntimeContextFromSession.java
----------------------------------------------------------------------
diff --git a/core/runtime/src/main/java/org/apache/isis/core/runtime/persistence/internal/RuntimeContextFromSession.java b/core/runtime/src/main/java/org/apache/isis/core/runtime/persistence/internal/RuntimeContextFromSession.java
index 3788277..2918903 100644
--- a/core/runtime/src/main/java/org/apache/isis/core/runtime/persistence/internal/RuntimeContextFromSession.java
+++ b/core/runtime/src/main/java/org/apache/isis/core/runtime/persistence/internal/RuntimeContextFromSession.java
@@ -169,7 +169,7 @@ public class RuntimeContextFromSession extends RuntimeContextAbstract {
@Override
public void remove(final ObjectAdapter adapter) {
- getPersistenceSession().destroyObject(adapter);
+ getPersistenceSession().destroyObjectInTransaction(adapter);
}
};
this.domainObjectServices = new DomainObjectServicesAbstract() {
http://git-wip-us.apache.org/repos/asf/isis/blob/05f54a0a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/persistence/PersistenceSession.java
----------------------------------------------------------------------
diff --git a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/persistence/PersistenceSession.java b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/persistence/PersistenceSession.java
index af9561f..9972461 100644
--- a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/persistence/PersistenceSession.java
+++ b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/persistence/PersistenceSession.java
@@ -825,13 +825,13 @@ public class PersistenceSession implements TransactionalResource, SessionScopedC
//endregion
- //region > destroyObject
+ //region > destroyObjectInTransaction
/**
* Removes the specified object from the system. The specified object's data
* should be removed from the persistence mechanism.
*/
- public void destroyObject(final ObjectAdapter adapter) {
+ public void destroyObjectInTransaction(final ObjectAdapter adapter) {
final ObjectSpecification spec = adapter.getSpecification();
if (spec.isParented()) {
return;
@@ -843,7 +843,7 @@ public class PersistenceSession implements TransactionalResource, SessionScopedC
@Override
public void execute() {
- final DestroyObjectCommand command = createDestroyObjectCommand(adapter);
+ final DestroyObjectCommand command = newDestroyObjectCommand(adapter);
getTransactionManager().addCommand(command);
}
@@ -893,7 +893,7 @@ public class PersistenceSession implements TransactionalResource, SessionScopedC
- public DestroyObjectCommand createDestroyObjectCommand(final ObjectAdapter adapter) {
+ public DestroyObjectCommand newDestroyObjectCommand(final ObjectAdapter adapter) {
ensureOpened();
ensureInSession();
http://git-wip-us.apache.org/repos/asf/isis/blob/05f54a0a/core/runtime/src/test/java/org/apache/isis/core/runtime/system/persistence/PersistenceSessionTest.java
----------------------------------------------------------------------
diff --git a/core/runtime/src/test/java/org/apache/isis/core/runtime/system/persistence/PersistenceSessionTest.java b/core/runtime/src/test/java/org/apache/isis/core/runtime/system/persistence/PersistenceSessionTest.java
index c338489..54fa13d 100644
--- a/core/runtime/src/test/java/org/apache/isis/core/runtime/system/persistence/PersistenceSessionTest.java
+++ b/core/runtime/src/test/java/org/apache/isis/core/runtime/system/persistence/PersistenceSessionTest.java
@@ -196,7 +196,7 @@ public class PersistenceSessionTest {
});
transactionManager.startTransaction();
- persistenceSession.destroyObject(persistentAdapter);
+ persistenceSession.destroyObjectInTransaction(persistentAdapter);
transactionManager.abortTransaction();
}
@@ -232,7 +232,7 @@ public class PersistenceSessionTest {
});
transactionManager.startTransaction();
- persistenceSession.destroyObject(persistentAdapter);
+ persistenceSession.destroyObjectInTransaction(persistentAdapter);
transactionManager.endTransaction();
}