Browse Source

renames to play nicer with other classes.

August Mueller 10 years ago
parent
commit
b8afed45b6
3 changed files with 30 additions and 10 deletions
  1. 20 0
      CHANGES_AND_TODO_LIST.txt
  2. 4 4
      src/fmdb/FMDatabase.h
  3. 6 6
      src/fmdb/FMDatabase.m

+ 20 - 0
CHANGES_AND_TODO_LIST.txt

@@ -3,6 +3,26 @@ Zip, nada, zilch.  Got any ideas?
 
 If you would like to contribute some code- awesome!  I just ask that you make it conform to the coding conventions already set in here, and to add a couple of tests for your new code to fmdb.m.  And of course, the code should be of general use to more than just a couple of folks.  Send your patches to gus@flyingmeat.com.
 
+
+
+
+
+# FMDB 3.0.
+
+## CHANGES
+setKey and friends on FMDatabase was changed to setEncryptionKey: (and friends).
+
+
+
+
+
+
+
+
+
+
+
+
 2015.01.23
     Added Swift renditions of the variadic methods of FMDatabaseAdditions.
 

+ 4 - 4
src/fmdb/FMDatabase.h

@@ -667,7 +667,7 @@ typedef int(^FMDBExecuteStatementsCallbackBlock)(NSDictionary *resultsDictionary
  @warning You need to have purchased the sqlite encryption extensions for this method to work.
  */
 
-- (BOOL)setKey:(NSString*)key;
+- (BOOL)setEncryptionKey:(NSString*)key;
 
 /** Reset encryption key
 
@@ -680,7 +680,7 @@ typedef int(^FMDBExecuteStatementsCallbackBlock)(NSDictionary *resultsDictionary
  @warning You need to have purchased the sqlite encryption extensions for this method to work.
  */
 
-- (BOOL)rekey:(NSString*)key;
+- (BOOL)rekeyEncryptionKey:(NSString*)key;
 
 /** Set encryption key using `keyData`.
  
@@ -693,7 +693,7 @@ typedef int(^FMDBExecuteStatementsCallbackBlock)(NSDictionary *resultsDictionary
  @warning You need to have purchased the sqlite encryption extensions for this method to work.
  */
 
-- (BOOL)setKeyWithData:(NSData *)keyData;
+- (BOOL)setEncryptionKeyWithData:(NSData *)keyData;
 
 /** Reset encryption key using `keyData`.
 
@@ -706,7 +706,7 @@ typedef int(^FMDBExecuteStatementsCallbackBlock)(NSDictionary *resultsDictionary
  @warning You need to have purchased the sqlite encryption extensions for this method to work.
  */
 
-- (BOOL)rekeyWithData:(NSData *)keyData;
+- (BOOL)rekeyEncryptionKeyWithData:(NSData *)keyData;
 
 
 ///------------------------------

+ 6 - 6
src/fmdb/FMDatabase.m

@@ -347,13 +347,13 @@ - (void)setCachedStatement:(FMStatement*)statement forQuery:(NSString*)query {
 
 #pragma mark Key routines
 
-- (BOOL)rekey:(NSString*)key {
+- (BOOL)rekeyEncryptionKey:(NSString*)key {
     NSData *keyData = [NSData dataWithBytes:(void *)[key UTF8String] length:(NSUInteger)strlen([key UTF8String])];
     
-    return [self rekeyWithData:keyData];
+    return [self rekeyEncryptionKeyWithData:keyData];
 }
 
-- (BOOL)rekeyWithData:(NSData *)keyData {
+- (BOOL)rekeyEncryptionKeyWithData:(NSData *)keyData {
 #ifdef SQLITE_HAS_CODEC
     if (!keyData) {
         return NO;
@@ -372,13 +372,13 @@ - (BOOL)rekeyWithData:(NSData *)keyData {
 #endif
 }
 
-- (BOOL)setKey:(NSString*)key {
+- (BOOL)setEncryptionKey:(NSString*)key {
     NSData *keyData = [NSData dataWithBytes:[key UTF8String] length:(NSUInteger)strlen([key UTF8String])];
     
-    return [self setKeyWithData:keyData];
+    return [self setEncryptionKeyWithData:keyData];
 }
 
-- (BOOL)setKeyWithData:(NSData *)keyData {
+- (BOOL)setEncryptionKeyWithData:(NSData *)keyData {
 #ifdef SQLITE_HAS_CODEC
     if (!keyData) {
         return NO;