         }
     }
     
-    func deleteObject(aObj: T) {
+    func deleteObject(inout aObj: T) {
         //self.delete(aObj.id)
         aObj.uid = nil;
     }

        
        var result: T = T()
        
        self.addObject(result)
        
        return result
    }
    

    func addObject(aObj: T) -> Identifier {
        
        aObj.uid = create(aObj.encodeData())
        
        aObj.dirty = false
        

import Foundation


class ObjectStore<T: Coding> : DataStore {
    
    //var objectType : Class!
    
