summaryrefslogtreecommitdiff
path: root/projects/net.wotonomy.test/src/main/java/net/wotonomy/test/TestObjectStore.java
diff options
context:
space:
mode:
Diffstat (limited to 'projects/net.wotonomy.test/src/main/java/net/wotonomy/test/TestObjectStore.java')
-rw-r--r--projects/net.wotonomy.test/src/main/java/net/wotonomy/test/TestObjectStore.java12
1 files changed, 12 insertions, 0 deletions
diff --git a/projects/net.wotonomy.test/src/main/java/net/wotonomy/test/TestObjectStore.java b/projects/net.wotonomy.test/src/main/java/net/wotonomy/test/TestObjectStore.java
index 316fcf7..cbd16fa 100644
--- a/projects/net.wotonomy.test/src/main/java/net/wotonomy/test/TestObjectStore.java
+++ b/projects/net.wotonomy.test/src/main/java/net/wotonomy/test/TestObjectStore.java
@@ -34,6 +34,7 @@ public class TestObjectStore extends EOObjectStore {
/**
* This implementation simply returns objectsWithSourceGlobalID.
*/
+ @Override
public NSArray arrayFaultWithSourceGlobalID(EOGlobalID aGlobalID, String aRelationship, EOEditingContext aContext) {
return objectsForSourceGlobalID(aGlobalID, aRelationship, aContext);
}
@@ -41,6 +42,7 @@ public class TestObjectStore extends EOObjectStore {
/**
* This implementation returns the actual object for the specified id.
*/
+ @Override
public Object faultForGlobalID(EOGlobalID aGlobalID, EOEditingContext aContext) {
System.out.println("TestObjectStore: * reading object * : " + aGlobalID);
return soup.getObjectByKey(((DataKeyID) aGlobalID).getKey());
@@ -51,6 +53,7 @@ public class TestObjectStore extends EOObjectStore {
* values from the specified dictionary. The fault should belong to the
* specified editing context.
*/
+ @Override
public Object faultForRawRow(Map aDictionary, String anEntityName, EOEditingContext aContext) {
// TODO: faults are not yet supported
throw new WotonomyException("Faults are not yet supported.");
@@ -61,6 +64,7 @@ public class TestObjectStore extends EOObjectStore {
* values appropriate for the specified id. The object should belong to the
* specified editing context. This method is called to populate faults.
*/
+ @Override
public void initializeObject(Object anObject, EOGlobalID aGlobalID, EOEditingContext aContext) {
System.out.println("TestObjectStore: * reading object * : " + aGlobalID);
Object original = soup.getObjectByKey(((DataKeyID) aGlobalID).getKey());
@@ -73,6 +77,7 @@ public class TestObjectStore extends EOObjectStore {
* Remove all values from all objects in memory, turning them into faults, and
* posts a notification that all objects have been invalidated.
*/
+ @Override
public void invalidateAllObjects() {
// does nothing
}
@@ -81,6 +86,7 @@ public class TestObjectStore extends EOObjectStore {
* Removes values with the specified ids from memory, turning them into faults,
* and posts a notification that those objects have been invalidated.
*/
+ @Override
public void invalidateObjectsWithGlobalIDs(List aList) {
// does nothing
}
@@ -88,6 +94,7 @@ public class TestObjectStore extends EOObjectStore {
/**
* Returns false because locking is not permitted.
*/
+ @Override
public boolean isObjectLockedWithGlobalID(EOGlobalID aGlobalID, EOEditingContext aContext) {
return false;
}
@@ -95,6 +102,7 @@ public class TestObjectStore extends EOObjectStore {
/**
* Does nothing because locking is not permitted.
*/
+ @Override
public void lockObjectWithGlobalID(EOGlobalID aGlobalID, EOEditingContext aContext) {
// does nothing
}
@@ -104,6 +112,7 @@ public class TestObjectStore extends EOObjectStore {
* for the specified property relationship. Faults are not allowed in the array.
* All objects should belong to the specified editing context.
*/
+ @Override
public NSArray objectsForSourceGlobalID(EOGlobalID aGlobalID, String aRelationship, EOEditingContext aContext) {
// TODO: relationships are not yet supported
throw new WotonomyException("Relationships are not yet supported.");
@@ -116,6 +125,7 @@ public class TestObjectStore extends EOObjectStore {
* the specified context, it is not refetched and that object should be used in
* the array.
*/
+ @Override
public NSArray objectsWithFetchSpecification(EOFetchSpecification aFetchSpec, EOEditingContext aContext) {
// TODO: fetch specs are not yet supported
@@ -144,6 +154,7 @@ public class TestObjectStore extends EOObjectStore {
* Removes all values from the specified object, converting it into a fault for
* the specified id. New or deleted objects should not be refaulted.
*/
+ @Override
public void refaultObject(Object anObject, EOGlobalID aGlobalID, EOEditingContext aContext) {
// TODO: faults are not yet supported
// just re-initialize the object
@@ -153,6 +164,7 @@ public class TestObjectStore extends EOObjectStore {
/**
* Writes all changes in the specified editing context to the respository.
*/
+ @Override
public void saveChangesInEditingContext(EOEditingContext aContext) {
Object o;
DataKeyID id;