diff options
author | rowanbeentje <rowan@beent.je> | 2009-04-19 14:34:30 +0000 |
---|---|---|
committer | rowanbeentje <rowan@beent.je> | 2009-04-19 14:34:30 +0000 |
commit | d4dd7e79ce8373fe94521da2294a076887758ee2 (patch) | |
tree | 85d6828f2131b3e14afee0bcb0d88d09cb23fa1e /Source/CMMCPConnection.h | |
parent | 39adddc081ea010756886ce5819ec4565469d893 (diff) | |
download | sequelpro-d4dd7e79ce8373fe94521da2294a076887758ee2.tar.gz sequelpro-d4dd7e79ce8373fe94521da2294a076887758ee2.tar.bz2 sequelpro-d4dd7e79ce8373fe94521da2294a076887758ee2.zip |
Bring Tiger branch up to version 0.9.5:
- Merge in revisions up to r592 from trunk
- Rewrite code where appropriate to use Tiger-compaible methods (no easy object enumeriation, no @properties, etc)
- Remove printing again - problems printing, and template engine is 10.5-only
- Rework xibs as nibs, and ensure everything looks and works correctly on Tiger; revert interface elements where necessary.
- Add a method to check whether the app is being run on 10.5+, and show appropriate warning about interface and features
- Alter strings and change sparkle URL to Tiger-specific appcast
Diffstat (limited to 'Source/CMMCPConnection.h')
-rw-r--r-- | Source/CMMCPConnection.h | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/Source/CMMCPConnection.h b/Source/CMMCPConnection.h index 584b8056..8473c962 100644 --- a/Source/CMMCPConnection.h +++ b/Source/CMMCPConnection.h @@ -26,15 +26,11 @@ #import <MCPKit_bundled/MCPKit_bundled.h> #import "CMMCPResult.h" -// Set the connection timeout to enforce for all connections - used for the initial connection -// timeout and ping timeouts, but not for long queries/reads/writes. -// Probably worth moving this to a preference at some point. -#define SP_CONNECTION_TIMEOUT 10 - @interface NSObject (CMMCPConnectionDelegate) - (void)willQueryString:(NSString *)query; - (void)queryGaveError:(NSString *)error; +- (BOOL)connectionEncodingViaLatin1; @end @@ -49,6 +45,10 @@ NSString *connectionHost; int connectionPort; NSString *connectionSocket; + float lastQueryExecutionTime; + int connectionTimeout; + BOOL useKeepAlive; + float keepAliveInterval; NSTimer *keepAliveTimer; NSDate *lastKeepAliveSuccess; @@ -66,6 +66,8 @@ - (void) setParentWindow:(NSWindow *)theWindow; - (BOOL) selectDB:(NSString *) dbName; - (CMMCPResult *) queryString:(NSString *) query; +- (CMMCPResult *) queryString:(NSString *) query usingEncoding:(NSStringEncoding) encoding; +- (float) lastQueryExecutionTime; - (MCPResult *) listDBsLike:(NSString *) dbsName; - (BOOL) checkConnection; - (void) setDelegate:(id)object; @@ -75,5 +77,6 @@ - (void) stopKeepAliveTimer; - (void) keepAlive:(NSTimer *)theTimer; - (void) threadedKeepAlive; +- (const char *) cStringFromString:(NSString *) theString usingEncoding:(NSStringEncoding) encoding; @end |