mirror of
https://github.com/gnustep/libs-gdl2.git
synced 2025-02-19 01:30:48 +00:00
* EOAccess/EODatabaseContext.m
-isValidQualifierTypeForAttribute: reformat, remove useless code -qualifierForLockingAttributes:primaryKeyAttributes:entity:snapshot: reformat * EOAdaptors/PostgreSQLAdaptor/PostgreSQLAdaptor.m -isValidQualifierType:model: remove logs, format * Apps/EOModelEditor/Inspectors/AttributeInspector.gsmarkup * Apps/EOModeler/EOModelExtensions.m Rename the char into BOOL You can use BOOL to create code that has BOOL values. Apple seems to do this in newer code git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@30874 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
4ba46c20a5
commit
a5a47b954d
5 changed files with 103 additions and 83 deletions
|
@ -115,7 +115,7 @@
|
|||
<popUpButtonItem tag="0" title="int" />
|
||||
<popUpButtonItem tag="1" title="double" />
|
||||
<popUpButtonItem tag="2" title="float" />
|
||||
<popUpButtonItem tag="3" title="char" />
|
||||
<popUpButtonItem tag="3" title="BOOL" />
|
||||
<popUpButtonItem tag="4" title="short" />
|
||||
<popUpButtonItem tag="5" title="unsigned int" />
|
||||
<popUpButtonItem tag="6" title="unsigned char" />
|
||||
|
|
|
@ -214,6 +214,30 @@
|
|||
|
||||
- (BOOL)isScalar
|
||||
{
|
||||
NSString * vClassName = [self valueClassName];
|
||||
|
||||
if ([vClassName isEqual:@"NSNumber"] == NO) {
|
||||
return NO;
|
||||
} else {
|
||||
NSString * vType = [self valueType];
|
||||
unichar myChar;
|
||||
|
||||
if ([vType length] < 1) {
|
||||
return NO;
|
||||
}
|
||||
myChar = [vType characterAtIndex:0];
|
||||
switch (myChar) {
|
||||
case 'c': /* this is what newer WO versions do */
|
||||
return YES;
|
||||
break;
|
||||
case 'i':
|
||||
return NO; /* we want NSNumbers */
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return NO;
|
||||
}
|
||||
|
||||
|
@ -229,7 +253,7 @@
|
|||
myChar = [vType characterAtIndex:0];
|
||||
|
||||
switch (myChar) {
|
||||
case 'c': return @"char";
|
||||
case 'c': return @"BOOL"; /* this is what newer WO versions do */
|
||||
break;
|
||||
case 'C': return @"unsigned char";
|
||||
break;
|
||||
|
|
15
ChangeLog
15
ChangeLog
|
@ -1,3 +1,18 @@
|
|||
2010-06-27 David Wetzel <dave@turbocat.de>
|
||||
* EOAccess/EODatabaseContext.m
|
||||
-isValidQualifierTypeForAttribute:
|
||||
reformat, remove useless code
|
||||
-qualifierForLockingAttributes:primaryKeyAttributes:entity:snapshot:
|
||||
reformat
|
||||
* EOAdaptors/PostgreSQLAdaptor/PostgreSQLAdaptor.m
|
||||
-isValidQualifierType:model:
|
||||
remove logs, format
|
||||
* Apps/EOModelEditor/Inspectors/AttributeInspector.gsmarkup
|
||||
* Apps/EOModeler/EOModelExtensions.m
|
||||
Rename the char into BOOL
|
||||
You can use BOOL to create code that has BOOL values.
|
||||
Apple seems to do this in newer code
|
||||
|
||||
2010-06-26 David Wetzel <dave@turbocat.de>
|
||||
* EOAccess/EOAccessFault.m
|
||||
-unableToFaultObject:databaseContext:
|
||||
|
|
|
@ -4793,8 +4793,6 @@ Raises an exception is the adaptor is unable to perform the operations.
|
|||
EOAdaptor *adaptor = nil;
|
||||
NSString *externalType = nil;
|
||||
|
||||
|
||||
|
||||
entity = [attribute entity];
|
||||
|
||||
NSAssert1(entity, @"No entity for attribute %@", attribute);
|
||||
|
@ -4806,16 +4804,6 @@ Raises an exception is the adaptor is unable to perform the operations.
|
|||
isValid = [adaptor isValidQualifierType: externalType
|
||||
model: model];
|
||||
|
||||
//TODO REMOVE
|
||||
if (!isValid)
|
||||
{
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
return isValid;
|
||||
}
|
||||
|
||||
|
|
|
@ -286,16 +286,9 @@ static NSString *typeNames[][2] = {
|
|||
|
||||
for (i = 0, c = sizeof(typeNames) / sizeof(typeNames[0]); i < c; i++)
|
||||
{
|
||||
//TODO REMOVE
|
||||
NSDebugMLog(@"externalTypeNames[i]=%@", typeNames[i][0]);
|
||||
|
||||
if ([typeNames[i][0] isEqualToString: typeName])
|
||||
return YES;
|
||||
}
|
||||
//TODO REMOVE
|
||||
|
||||
NSDebugMLog(@"typeName=%@", typeName);
|
||||
|
||||
return NO;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue