home *** CD-ROM | disk | FTP | other *** search
/ OpenStep (Enterprise) / OpenStepENTCD.toast / OEDEPLOY / INFORMAD.Z / InformixChannel.h < prev    next >
Text File  |  1996-09-09  |  2KB  |  62 lines

  1. // InformixChannel.h 
  2. // Copyright (c) 1994, NeXT Software, Inc.  All rights reserved.
  3. //
  4.  
  5. #import "InformixDefines.h"
  6. #import <EOAccess/EOAccess.h>
  7.  
  8. @class InformixContext;
  9.  
  10. @interface InformixChannel:EOAdaptorChannel
  11. {
  12.     struct informix_cursor _cursor;
  13.     
  14.     id _currentExpression;
  15.     
  16.     NSArray *_selectedAttributes;
  17.     NSMutableArray *_selectedColumns;
  18.     unsigned _fetchBufferLength;
  19.     unsigned _rowCapacity;
  20.     unsigned _rowsInBuffer;
  21.     unsigned _nextRowInBuffer;
  22.     unsigned _rowsProcessedCount;
  23.     
  24.     BOOL _fetchInProgress;
  25.     BOOL _opened;
  26.     BOOL _beganTransaction;
  27.  
  28.     long _connection;
  29. }
  30.  
  31. - initWithInformixContext:(InformixContext *)logon;
  32.  
  33. - (struct informix_cursor *)cursorDataArea;
  34.     // This returns NULL if the channel is not connected.
  35.  
  36. - (void)setFetchBufferLength:(unsigned)length;
  37. - (unsigned)fetchBufferLength;
  38.     // These are to manipulate how much memory to use as a fetch buffer.  The
  39.     // larger the buffer, the more rows that can be returned for each round
  40.     // trip to the server.
  41.  
  42. - (void)informixSetIsolationTo:(InformixIsolationLevel)isol;
  43.     // Used for configuring the isolation transaction characteristics of this
  44.     // connection.
  45.  
  46. @end
  47.  
  48.  
  49. @interface NSObject (InformixChannelDelegation)
  50.  
  51. - (BOOL)informixChannel:(InformixChannel *)channel
  52.     willReportDatabaseError:(NSString *)error;
  53.     // This delegate message is called whenever the channel encounters an
  54.     // error reported by the Informix 5.00 server.  The ... can be
  55.     // gotten from the channel and context to determine exactly what error has
  56.     // occurred.  The string error is the text of the error message which will
  57.     // be sent to the adaptor's reportError: method.  The delegate can return
  58.     // NO to prevent the channel from calling reportError:.
  59.  
  60. @end
  61.  
  62.