/* FBMetaData.h created by geert on Thu 16-Apr-1998*/

#import <Foundation/NSString.h>
#import <Foundation/NSArray.h>
#import <Foundation/NSDate.h>
#import <Foundation/NSTimeZone.h>

@class FBDatabaseConnection;
@class FBErrorMetaData;
@class FBRowHandler;
@class FBColumnMetaData;
@class FBDatatypeMetaData;
@class FBBlobHandle;

@interface FBMetaData : NSObject
{
   void*                 metaData;
   FBDatabaseConnection* connection;
   NSString*             fetchHandle;
   NSArray*              metaDataArray;
   FBRowHandler*         rowHandler;
   
   int                   ltzOffset;
   BOOL                  ltsIsSet;
   
}

- (void)release;

@property(readonly) FBDatabaseConnection* connection;
@property(readonly) NSString*             catalogName;
@property(readonly) NSString*             message;
@property(readonly) NSString*             executionTime;
@property(readonly) NSTimeInterval        wallTime;
@property(readonly) NSTimeInterval        cpuTime;
@property(readonly) NSTimeInterval        waitTime;
@property(readonly) NSTimeInterval        wallTimeInterval;  // Alias for wallTime
@property(readonly) NSTimeInterval        cpuTimeInterval;   // Alias for cpuTime
@property(readonly) NSTimeInterval        waitTimeInterval;  // Alias for waitTime
@property(readonly) FBBlobHandle*         blobHandle;
@property(readonly) NSString*             statementHandle;
@property(readonly) NSString*             statementType;
@property(readonly) NSString*             errorClass;
@property(readonly) NSString*             planInfo;
@property(readonly) NSString*             agentID;
@property(readonly) NSString*             description;
@property(readonly) NSDictionary*         transactionDescription;
@property(readonly) BOOL                  hasMetaDataArray;
@property(readonly) NSArray*              metaDataArray;
@property(readonly) FBErrorMetaData*      errorMetaData;
@property(readonly) BOOL                  errorsFound;
@property(readonly) BOOL                  warningsFound;
@property(readonly) unsigned long long    rowCount;
@property(readonly) unsigned long long    rowIndex;
@property(readonly) unsigned int          warningCount;
@property(readonly) unsigned int          errorCount;
@property(readonly) unsigned int          batchSize;
@property(readonly) unsigned int          uniqueKey;
@property(readonly) int                   localTzOffset;
@property(readonly) NSString*             timeZoneName;
@property(readonly) NSTimeZone*           timeZone;
@property(readonly) NSString*             fetchHandle;
@property(readonly) BOOL                  anyRows;
@property(readonly) BOOL                  allRowsFetched;
@property(readonly) unsigned long long    fetchedRows;
@property(readonly) NSArray*              fetchRow;
@property(readonly) FBMetaData*           cancelFetch;
- (NSArray*) fetchRowsCount:(unsigned int)count;
@property(readonly) unsigned int          columnCount;
- (FBColumnMetaData*)columnMetaDataAtIndex:(unsigned)index;
- (FBDatatypeMetaData*)datatypeMetaDataAtIndex:(unsigned)index;
@end
