ObjPgSQL  Diff

Differences From Artifact [1b1566e654]:

To Artifact [b80f854ff0]:


1
2

3
4
5

6
7
8
9
10

11
12
13
14
15
16
17
1
2
3
4
5

6
7
8
9
10

11
12
13
14
15
16
17
18


+


-
+




-
+







#import "PGResult.h"
#import "PGResultRow.h"
#import "PGResultRow+Private.h"

@implementation PGResult
+ PG_resultWithResult: (PGresult *)result
+ (instancetype)PG_resultWithResult: (PGresult *)result
{
	return [[[self alloc] PG_initWithResult: result] autorelease];
}

- PG_initWithResult: (PGresult *)result
- (instancetype)PG_initWithResult: (PGresult *)result
{
	self = [super init];

	_result = result;

	return self;
}
30
31
32
33
34
35
36
37
38


39
40
41
42
43
44
45
31
32
33
34
35
36
37


38
39
40
41
42
43
44
45
46







-
-
+
+







}

- (id)objectAtIndex: (size_t)index
{
	if (index > PQntuples(_result))
		@throw [OFOutOfRangeException exception];

	return [PGResultRow rowWithResult: self
				      row: (int)index];
	return [PGResultRow PG_rowWithResult: self
					 row: (int)index];
}

- (PGresult *)PG_result
{
	return _result;
}
@end