Bug 747102 - Remove SmallCommit method from db. r=dbienvenu
authoraceman <acelists@atlas.sk>
Mon, 23 Apr 2012 19:07:20 -0400
changeset 11715 33e93567f9f3f7d43fc8e9553d8a28d22d95ea67
parent 11714 9aace1fa76ffa6a2b96e01e10681da2f7c70b95a
child 11716 9b83555adeb2daf130476db5ba4f1cb72fa78e36
push idunknown
push userunknown
push dateunknown
reviewersdbienvenu
bugs747102
Bug 747102 - Remove SmallCommit method from db. r=dbienvenu
db/mork/public/mdb.h
db/mork/src/morkStore.cpp
db/mork/src/morkStore.h
--- a/db/mork/public/mdb.h
+++ b/db/mork/public/mdb.h
@@ -1306,21 +1306,20 @@ public:
 **| a store is closed, presumably this precipitates the closure of all tables,
 **| rows, and cells in the store as well.   So an application can revert the
 **| state of a store in the user interface by quietly closing and reopening a
 **| store, because this will discard uncommited changes and show old content.
 **| This implies an app that closes a store will need to send a "scramble"
 **| event notification to any views that depend on old discarded content.
 |*/
 
-#define NS_IMDBSTORE_IID_STR "726618d3-f15b-49b9-9f4a-efcc9db53d0d"
-
+#define NS_IMDBSTORE_IID_STR "74d6218d-44b0-43b5-9ebe-69a17dfb562c"
 #define NS_IMDBSTORE_IID \
-{0x726618d3, 0xf15b, 0x49b9, \
-{0x9f, 0x4a, 0xef, 0xcc, 0x9d, 0xb5, 0x3d, 0x0d}}
+{0x74d6218d, 0x44b0, 0x43b5, \
+{0x9e, 0xbe, 0x69, 0xa1, 0x7d, 0xfb, 0x56, 0x2c}}
 
 class nsIMdbStore : public nsIMdbPort {
 public:
   NS_DECLARE_STATIC_IID_ACCESSOR(NS_IMDBSTORE_IID)
 
 // { ===== begin nsIMdbStore methods =====
 
   // { ----- begin table methods -----
@@ -1397,19 +1396,16 @@ public:
 
   NS_IMETHOD
   AvoidAtomColumnsHint( // advise column with poor atomizing prospects
     nsIMdbEnv* ev, // context
     const mdbColumnSet* inColumnSet) = 0; // cols with poor atomizing prospects
   // } ----- end hinting methods -----
 
   // { ----- begin commit methods -----
-  NS_IMETHOD SmallCommit( // save minor changes if convenient and uncostly
-    nsIMdbEnv* ev) = 0; // context
-  
   NS_IMETHOD LargeCommit( // save important changes if at all possible
     nsIMdbEnv* ev, // context
     nsIMdbThumb** acqThumb) = 0; // acquire thumb for incremental commit
   // Call nsIMdbThumb::DoMore() until done, or until the thumb is broken, and
   // then the commit will be finished.  Note the store is effectively write
   // locked until commit is finished or canceled through the thumb instance.
   // Until the commit is done, the store will report it has readonly status.
 
--- a/db/mork/src/morkStore.cpp
+++ b/db/mork/src/morkStore.cpp
@@ -2195,30 +2195,16 @@ morkStore::AvoidAtomColumnsHint( // advi
     outErr = ev->AsErr();
   }
   return outErr;
 }
 // } ----- end hinting methods -----
 
 // { ----- begin commit methods -----
 NS_IMETHODIMP
-morkStore::SmallCommit( // save minor changes if convenient and uncostly
-  nsIMdbEnv* mev) // context
-{
-  mdb_err outErr = 0;
-  morkEnv* ev = CanUseStore(mev, /*inMutable*/ morkBool_kFalse, &outErr);
-  if ( ev )
-  {
-    // ev->StubMethodOnlyError(); // it's okay to do nothing for small commit
-    outErr = ev->AsErr();
-  }
-  return outErr;
-}
-
-NS_IMETHODIMP
 morkStore::LargeCommit( // save important changes if at all possible
   nsIMdbEnv* mev, // context
   nsIMdbThumb** acqThumb) // acquire thumb for incremental commit
 // Call nsIMdbThumb::DoMore() until done, or until the thumb is broken, and
 // then the commit will be finished.  Note the store is effectively write
 // locked until commit is finished or canceled through the thumb instance.
 // Until the commit is done, the store will report it has readonly status.
 {
--- a/db/mork/src/morkStore.h
+++ b/db/mork/src/morkStore.h
@@ -466,19 +466,16 @@ public: // other port methods
 
   NS_IMETHOD
   AvoidAtomColumnsHint( // advise column with poor atomizing prospects
     nsIMdbEnv* ev, // context
     const mdbColumnSet* inColumnSet); // cols with poor atomizing prospects
   // } ----- end hinting methods -----
 
   // { ----- begin commit methods -----
-  NS_IMETHOD SmallCommit( // save minor changes if convenient and uncostly
-    nsIMdbEnv* ev); // context
-  
   NS_IMETHOD LargeCommit( // save important changes if at all possible
     nsIMdbEnv* ev, // context
     nsIMdbThumb** acqThumb); // acquire thumb for incremental commit
   // Call nsIMdbThumb::DoMore() until done, or until the thumb is broken, and
   // then the commit will be finished.  Note the store is effectively write
   // locked until commit is finished or canceled through the thumb instance.
   // Until the commit is done, the store will report it has readonly status.