aboutsummaryrefslogtreecommitdiffstats
path: root/Frameworks/MCPKit/MCPFoundationKit/MCPConnection.h
diff options
context:
space:
mode:
authorrowanbeentje <rowan@beent.je>2010-08-25 23:58:52 +0000
committerrowanbeentje <rowan@beent.je>2010-08-25 23:58:52 +0000
commitdc9d005f21b3e281294f61d4d8e49d0ad003e8fb (patch)
tree02ac106ff98341c4b87d420c5ec9c9c2f1acb130 /Frameworks/MCPKit/MCPFoundationKit/MCPConnection.h
parent47b27a6d2b5d3cd7fa7152d2679283e7fba3e82d (diff)
downloadsequelpro-dc9d005f21b3e281294f61d4d8e49d0ad003e8fb.tar.gz
sequelpro-dc9d005f21b3e281294f61d4d8e49d0ad003e8fb.tar.bz2
sequelpro-dc9d005f21b3e281294f61d4d8e49d0ad003e8fb.zip
Encoding changes and improvements, particularly to increase compatibility with extended characters in MySQL identifiers (names of dbs/tables/cols):
- Move encoding queries and control into MCPKit, with newly cleaned-up methods, and switch a number of locations to using the new code. - Use UTF8 connections for many identifier-based queries (selecting and listing databases, tables, stored procs, table information). This fixes selection and creation of table and database names containing extended characters, also fixing exceptions and errors. - Improve UTF8 over Latin1 to correctly set the client character set encoding as well, fixing custom queries and edits; remove custom code in SPTableContent achieving the same thing in a single location. - Fix database encoding detection routines - Update localisable strings
Diffstat (limited to 'Frameworks/MCPKit/MCPFoundationKit/MCPConnection.h')
-rw-r--r--Frameworks/MCPKit/MCPFoundationKit/MCPConnection.h30
1 files changed, 12 insertions, 18 deletions
diff --git a/Frameworks/MCPKit/MCPFoundationKit/MCPConnection.h b/Frameworks/MCPKit/MCPFoundationKit/MCPConnection.h
index adcecb05..7e60ccb2 100644
--- a/Frameworks/MCPKit/MCPFoundationKit/MCPConnection.h
+++ b/Frameworks/MCPKit/MCPFoundationKit/MCPConnection.h
@@ -51,11 +51,6 @@
/**
*
*/
-- (BOOL)connectionEncodingViaLatin1:(id)connection;
-
-/**
- *
- */
- (NSString *)keychainPasswordForConnection:(id)connection;
/**
@@ -66,11 +61,6 @@
/**
*
*/
-- (NSString *)onReconnectShouldUseEncoding:(id)connection;
-
-/**
- *
- */
- (void)noConnectionAvailable:(id)connection;
/**
@@ -91,11 +81,6 @@
/**
*
*/
-- (NSString *)connectionEncoding;
-
-/**
- *
- */
- (BOOL)navigatorSchemaPathExistsForDatabase:(NSString*)dbname;
/**
@@ -153,7 +138,11 @@
NSString *connectionSocket;
NSInteger maxAllowedPacketSize;
unsigned long connectionThreadId;
-
+
+ NSString *encoding, *previousEncoding;
+ NSStringEncoding *stringEncoding;
+ BOOL encodingUsesLatin1Transport, previousEncodingUsesLatin1Transport;
+
NSInteger currentProxyState;
double lastQueryExecutionTime;
@@ -318,8 +307,13 @@ void performThreadedKeepAlive(void *ptr);
- (NSString *)findSocketPath;
// Encoding
-- (void)setEncoding:(NSStringEncoding)theEncoding;
-- (NSStringEncoding)encoding;
+- (BOOL)setEncoding:(NSString *)theEncoding;
+- (NSString *)encoding;
+- (NSStringEncoding)stringEncoding;
+- (BOOL)setEncodingUsesLatin1Transport:(BOOL)useLatin1;
+- (BOOL)encodingUsesLatin1Transport;
+- (void)storeEncodingForRestoration;
+- (void)restoreStoredEncoding;
// Time zone
- (void)setTimeZone:(NSTimeZone *)iTimeZone;