2003-03-30 David Ayers <d.ayers@inode.at>

* *.h/m, *.h/m):
	Used #include instead of depricated #import.  Avoid including
	entire library headers.  Use export macro where applicable.

	* EOControl/GNUmakefile: Removed EOKeyValueCodingBase.m/h and
	EOUndoMananger.h.  Added EOArrayDataSource.m/h, EODefines.h
	and EODepricated.h.
	* EOControl/EODefines.h: Updated for GDL2 & gnustep-make.
	* EOControl/EODebug.h: Updated.
	* EOControl/EODepricated.h: Updated for current state of GDL2.
	([NSObject +flushClassKeyBindings]): Added declaration.
	([EOClassDescription +setDelegate:]): Added declaration.
	([EOClassDescription +delegate]): Added declaration.
	(EOUndoManager): Moved declaration of interface here.
	* EOControl/EOKeyValueCoding.m
	([EOClassDescription +flushClassKeyBindings]): Added empty
	implementation.
	([NSObject takeStoredValuesFromDictionary:]): Cache EONull
	instance and use it instead of isKindOfClass:.
	* EOControl/EOEditingContext.m
	([EOEditingContext +initialize]): Tidied.
	([EOEditingContest -deleteObject]): Use NSUndoManager instead of
	EOUndoManager.
	* EOControl/EOQualifier.m
	([NSArray -filteredArrayUsingQualifier:]): Added minor
	optimization tweak.
	* EOControl/EOClassDescription.m: Removed inactive commented
	code.  Added private declerations of EOAccess methods to avoid
	compiler warnings.
	([EOClassDescription +initialize]): Tidied.
	([EOClassDescription -classDescriptionForClass:]): Use
	GSObjCName() instead of objc runtime routines.
	* EOControl/EOFault.m: Exchanged direct usages of ObjC runtime
	routines with NS/GSObjCRuntime abstraction API.
	([EOFault +superclass]): Ditto.
	([EOFault +targetClassForFault:]): Ditto.
	([EOFault -respondsToSelector:]): Ditto.
	([EOFault +initialize]): Cache static class variable.
	([EOFault +isKindOfClass]): Use static class variable.
	([EOFault +handlerForFault:]): Ditto.
	([EOFault +targetClassForFault:]): Ditto.
	([EOFault -dealloc]): Ditto.
	* EOControl/EOGenericRecord.m:
	([EOGenericRecord +initialize]): Tidied.
	* EOControl/EOKeyComparisonQualifier.m: Tidied documentation.
	* EOControl/EOKeyValueQualifier.m: Ditto.
	* EOControl/EONSAddOns.h/m: Added declarations to surpress
	compiler warnings.
	([NSObject -eoCompareOnName:]): Adjusted casts to surpress
	compiler warnings.
	(GSUseStrictWO451Compatibility): Added function.
	(GDL2GlobalLock, GDL2GlobalRecursive): Ditto.
	* EOControl/EONull: Remove implementations for foundation
	libraries without key value coding and fully rely on NSNull.
	Added assertions in all intance methods as instances should never
	be created.
	([EONull +allocWithZone:]) Corrected method name so it will
	actually be used.
	* EOControl/EOSortOrdering.m
	([NSArray sortedArrayUsingKeyOrderArray:]): Tidied.
	([NSMutableArray sortUsingKeyOrderArray:]): Ditto.
	([EONull compareAscending:]): Sync with referencs implementation.
	([EONull compareDescending:]): Ditto.
	([EONull compareCaseInsensitiveAscending:]): Ditto.
	([EONull compareCaseInsensitiveDescending:]): Ditto.

	* EOAccess/EOAdaptor.h: Added comment about API compatibility.
	* EOAccess/EOAdaptor.m ([EOAdaptor -contexts]): Return array of
	adaptor contexts rather tham GC-wrapper objects containing adaptor
	contexts.
	([EOAdaptor -databaseEncoding]): Use GSEncodingName() instead of
	GetEncodingName().
	* EOAccess/EODatabaseContext.m
	([EODatabaseContext -_turnFault:gid:editingContext:isComplete:]):
	Use GSObjCClass() instead of trying to access isa by dereferencing
	from id with incorrect member.
	* EOAccess/EOModel.m ([EOModel -entityNames]): Sort returned array
	to insure comparable output.
	* EOAccess/EOSQLExpression.m
	([EOSQLExpression sqlStringForArrayOfQualifiers:operation:]):
	Added cast to surpress compiler warning.
	* EOAccess/EOUtilities.m
	([EOObjectStoreCoordinator setModelGroup:]): Ditto.
	* EOAccess/EORelationship.h ([EORelationship -docComment]):
	Added declaration.
	* EOAccess/GNUmakefile: Added EODefines.h and EODepricated.h.

	* Tools/*.m: Use RCS_ID macro.
	* Tools/EOAttribute+GSDoc.h:
	([EOAttribute gsdocContentWithTagName:idPtr:]): Corrected Typo.
	* Tools/EOModel+GSDoc.h/m:
	([EOModel gsdocContentSplittedByEntities:idPtr:]): Ditto.
	* Tools/EORelationship+GSDoc.m:
	([EORelationship gsdocContentWithTagName:idPtr:]): Change variable
	type to supress compiler warnings.
	* Tools/eoutil.m (dump): Initialize variables to supress compiler
	warnings.
	* Tools/gsdoc-model.m: Include GSCategories.h to supress compiler
	warnings.
	(main): Added cast to supress compiler warning.  Fixed typo in
	method invocation.

2003-03-25  Stephane Corthesy  <stephane@sente.ch>

	* EOControl/EODefines.h: Added new file for export/win32 support.
	* EOControl/EODepricated.h: Added new file for depricated features.
	* EOControl/EOControl.h: Added EOArrayDataSource.h and EODefines.h.
	* EOControl/EOArrayDataSource.h/m: Added new files.  Some methods
	(<NSCoding> and qualifier bindings) are empty stubs.
	* EOControl/EODebug.h: Use export macro instead of explicit extern for
	function and symbol declarations.
	* EOControl/EOGlobalID.h: Ditto.
	* EOControl/EONull.h: Ditto.
	* EOControl/EOObjectStore.h: Ditto.
	* EOControl/EOOrQualifier.m: Replaced autorelease by AUTORELEASE
	and fixed typo.
	* EOControl/EOQualifier.m
	([NSArray -filteredArrayUsingQualifier:]): Implemented.
	* EOControl/EONSAddOns.m: Use volatile in some exception handlers
	(man longjmp for more info).
	* EOControl/EOSortOrdering.h/m
	([EOSortOrdering -copyWithZone:]): Implemented <NSCopying>.
	([EOSortOrdering -encodeWithKeyValueArchiver:]): Implemented.

	* EOAccess/EODefines.h: Added new file for export/win32 support.
	* EOAccess/EODepricated.h: Added new file for depricated features.
	* EOAccess/EOAccess.h: Added EODefines.h.
	* EOAccess/EOSQLExpression.h/m: Fixed typo for
	EOPrimaryKeyConstraintKey.
	* EOAccess/EOExpressionArray.h/m: Use volatile for variables usein
	in exception handlers. (man longjmp for more info)
	* EOAccess/EODatabase.h: Use export macro instead of explicit
	extern for function and symbol declarations.
	* EOAccess/EOEntity.h: Ditto.
	* EOAccess/EOModel.h: Ditto.
	* EOAccess/EOSchemaGeneration.h: Ditto.
	* EOAccess/EOSQLExpression.h: Ditto.
	* EOAccess/EOUtilities.h: Ditto.
	* Tools/eoutil.m (dump): Implemented use of -postinstall option.
	Corrected bug when getting adaptor's expression class.  Renamed
	symbol EOPrimaryKeyContraintsKey into EOPrimaryKeyConstraintsKey.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@16298 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
ayers 2003-03-31 00:24:15 +00:00
parent 37a212e456
commit 5c161a4105
127 changed files with 2299 additions and 1055 deletions

144
ChangeLog
View file

@ -1,3 +1,147 @@
2003-03-30 David Ayers <d.ayers@inode.at>
* *.h/m, *.h/m):
Used #include instead of depricated #import. Avoid including
entire library headers. Use export macro where applicable.
* EOControl/GNUmakefile: Removed EOKeyValueCodingBase.m/h and
EOUndoMananger.h. Added EOArrayDataSource.m/h, EODefines.h
and EODepricated.h.
* EOControl/EODefines.h: Updated for GDL2 & gnustep-make.
* EOControl/EODebug.h: Updated.
* EOControl/EODepricated.h: Updated for current state of GDL2.
([NSObject +flushClassKeyBindings]): Added declaration.
([EOClassDescription +setDelegate:]): Added declaration.
([EOClassDescription +delegate]): Added declaration.
(EOUndoManager): Moved declaration of interface here.
* EOControl/EOKeyValueCoding.m
([EOClassDescription +flushClassKeyBindings]): Added empty
implementation.
([NSObject takeStoredValuesFromDictionary:]): Cache EONull
instance and use it instead of isKindOfClass:.
* EOControl/EOEditingContext.m
([EOEditingContext +initialize]): Tidied.
([EOEditingContest -deleteObject]): Use NSUndoManager instead of
EOUndoManager.
* EOControl/EOQualifier.m
([NSArray -filteredArrayUsingQualifier:]): Added minor
optimization tweak.
* EOControl/EOClassDescription.m: Removed inactive commented
code. Added private declerations of EOAccess methods to avoid
compiler warnings.
([EOClassDescription +initialize]): Tidied.
([EOClassDescription -classDescriptionForClass:]): Use
GSObjCName() instead of objc runtime routines.
* EOControl/EOFault.m: Exchanged direct usages of ObjC runtime
routines with NS/GSObjCRuntime abstraction API.
([EOFault +superclass]): Ditto.
([EOFault +targetClassForFault:]): Ditto.
([EOFault -respondsToSelector:]): Ditto.
([EOFault +initialize]): Cache static class variable.
([EOFault +isKindOfClass]): Use static class variable.
([EOFault +handlerForFault:]): Ditto.
([EOFault +targetClassForFault:]): Ditto.
([EOFault -dealloc]): Ditto.
* EOControl/EOGenericRecord.m:
([EOGenericRecord +initialize]): Tidied.
* EOControl/EOKeyComparisonQualifier.m: Tidied documentation.
* EOControl/EOKeyValueQualifier.m: Ditto.
* EOControl/EONSAddOns.h/m: Added declarations to surpress
compiler warnings.
([NSObject -eoCompareOnName:]): Adjusted casts to surpress
compiler warnings.
(GSUseStrictWO451Compatibility): Added function.
(GDL2GlobalLock, GDL2GlobalRecursive): Ditto.
* EOControl/EONull: Remove implementations for foundation
libraries without key value coding and fully rely on NSNull.
Added assertions in all intance methods as instances should never
be created.
([EONull +allocWithZone:]) Corrected method name so it will
actually be used.
* EOControl/EOSortOrdering.m
([NSArray sortedArrayUsingKeyOrderArray:]): Tidied.
([NSMutableArray sortUsingKeyOrderArray:]): Ditto.
([EONull compareAscending:]): Sync with referencs implementation.
([EONull compareDescending:]): Ditto.
([EONull compareCaseInsensitiveAscending:]): Ditto.
([EONull compareCaseInsensitiveDescending:]): Ditto.
* EOAccess/EOAdaptor.h: Added comment about API compatibility.
* EOAccess/EOAdaptor.m ([EOAdaptor -contexts]): Return array of
adaptor contexts rather tham GC-wrapper objects containing adaptor
contexts.
([EOAdaptor -databaseEncoding]): Use GSEncodingName() instead of
GetEncodingName().
* EOAccess/EODatabaseContext.m
([EODatabaseContext -_turnFault:gid:editingContext:isComplete:]):
Use GSObjCClass() instead of trying to access isa by dereferencing
from id with incorrect member.
* EOAccess/EOModel.m ([EOModel -entityNames]): Sort returned array
to insure comparable output.
* EOAccess/EOSQLExpression.m
([EOSQLExpression sqlStringForArrayOfQualifiers:operation:]):
Added cast to surpress compiler warning.
* EOAccess/EOUtilities.m
([EOObjectStoreCoordinator setModelGroup:]): Ditto.
* EOAccess/EORelationship.h ([EORelationship -docComment]):
Added declaration.
* EOAccess/GNUmakefile: Added EODefines.h and EODepricated.h.
* Tools/*.m: Use RCS_ID macro.
* Tools/EOAttribute+GSDoc.h:
([EOAttribute gsdocContentWithTagName:idPtr:]): Corrected Typo.
* Tools/EOModel+GSDoc.h/m:
([EOModel gsdocContentSplittedByEntities:idPtr:]): Ditto.
* Tools/EORelationship+GSDoc.m:
([EORelationship gsdocContentWithTagName:idPtr:]): Change variable
type to supress compiler warnings.
* Tools/eoutil.m (dump): Initialize variables to supress compiler
warnings.
* Tools/gsdoc-model.m: Include GSCategories.h to supress compiler
warnings.
(main): Added cast to supress compiler warning. Fixed typo in
method invocation.
2003-03-25 Stephane Corthesy <stephane@sente.ch>
* EOControl/EODefines.h: Added new file for export/win32 support.
* EOControl/EODepricated.h: Added new file for depricated features.
* EOControl/EOControl.h: Added EOArrayDataSource.h and EODefines.h.
* EOControl/EOArrayDataSource.h/m: Added new files. Some methods
(<NSCoding> and qualifier bindings) are empty stubs.
* EOControl/EODebug.h: Use export macro instead of explicit extern for
function and symbol declarations.
* EOControl/EOGlobalID.h: Ditto.
* EOControl/EONull.h: Ditto.
* EOControl/EOObjectStore.h: Ditto.
* EOControl/EOOrQualifier.m: Replaced autorelease by AUTORELEASE
and fixed typo.
* EOControl/EOQualifier.m
([NSArray -filteredArrayUsingQualifier:]): Implemented.
* EOControl/EONSAddOns.m: Use volatile in some exception handlers
(man longjmp for more info).
* EOControl/EOSortOrdering.h/m
([EOSortOrdering -copyWithZone:]): Implemented <NSCopying>.
([EOSortOrdering -encodeWithKeyValueArchiver:]): Implemented.
* EOAccess/EODefines.h: Added new file for export/win32 support.
* EOAccess/EODepricated.h: Added new file for depricated features.
* EOAccess/EOAccess.h: Added EODefines.h.
* EOAccess/EOSQLExpression.h/m: Fixed typo for
EOPrimaryKeyConstraintKey.
* EOAccess/EOExpressionArray.h/m: Use volatile for variables usein
in exception handlers. (man longjmp for more info)
* EOAccess/EODatabase.h: Use export macro instead of explicit
extern for function and symbol declarations.
* EOAccess/EOEntity.h: Ditto.
* EOAccess/EOModel.h: Ditto.
* EOAccess/EOSchemaGeneration.h: Ditto.
* EOAccess/EOSQLExpression.h: Ditto.
* EOAccess/EOUtilities.h: Ditto.
* Tools/eoutil.m (dump): Implemented use of -postinstall option.
Corrected bug when getting adaptor's expression class. Renamed
symbol EOPrimaryKeyContraintsKey into EOPrimaryKeyConstraintsKey.
2003-03-21 Manuel Guesdon <mguesdon@orange-concept.com> 2003-03-21 Manuel Guesdon <mguesdon@orange-concept.com>
* EOAccess/EODatabaseContext.m: * EOAccess/EODatabaseContext.m:
o added assert in _primaryKeyForObject: o added assert in _primaryKeyForObject:

View file

@ -27,24 +27,24 @@
#ifndef __EOAccess_h__ #ifndef __EOAccess_h__
#define __EOAccess_h__ #define __EOAccess_h__
#import <EOAccess/EOAdaptor.h> #include <EOAccess/EOAdaptor.h>
#import <EOAccess/EOAdaptorContext.h> #include <EOAccess/EOAdaptorContext.h>
#import <EOAccess/EOAdaptorChannel.h> #include <EOAccess/EOAdaptorChannel.h>
#import <EOAccess/EOAttribute.h> #include <EOAccess/EOAttribute.h>
#import <EOAccess/EODatabase.h> #include <EOAccess/EODatabase.h>
#import <EOAccess/EODatabaseChannel.h> #include <EOAccess/EODatabaseChannel.h>
#import <EOAccess/EODatabaseContext.h> #include <EOAccess/EODatabaseContext.h>
#import <EOAccess/EOEntity.h> #include <EOAccess/EOEntity.h>
#import <EOAccess/EOJoin.h> #include <EOAccess/EOJoin.h>
#import <EOAccess/EOModel.h> #include <EOAccess/EOModel.h>
#import <EOAccess/EOModelGroup.h> #include <EOAccess/EOModelGroup.h>
#import <EOAccess/EORelationship.h> #include <EOAccess/EORelationship.h>
#import <EOAccess/EOStoredProcedure.h> #include <EOAccess/EOStoredProcedure.h>
#import <EOAccess/EOSQLExpression.h> #include <EOAccess/EOSQLExpression.h>
#import <EOAccess/EOSQLQualifier.h> #include <EOAccess/EOSQLQualifier.h>
#import <EOAccess/EODatabaseDataSource.h> #include <EOAccess/EODatabaseDataSource.h>
#import <EOAccess/EOSchemaGeneration.h> #include <EOAccess/EOSchemaGeneration.h>
#import <EOAccess/EOUtilities.h> #include <EOAccess/EOUtilities.h>
#endif /* __EOAccess_h__ */ #endif /* __EOAccess_h__ */

View file

@ -28,9 +28,9 @@
#define __EOAccessFault_h__ #define __EOAccessFault_h__
#import <Foundation/NSObject.h> #include <EOControl/EOFault.h>
#import <EOControl/EOFault.h> #include <EOAccess/EODefines.h>
@class EODatabaseContext; @class EODatabaseContext;
@ -119,7 +119,7 @@
@end @end
extern NSString *EOAccessFaultObjectNotAvailableException; GDL2ACCESS_EXPORT NSString *EOAccessFaultObjectNotAvailableException;
#endif #endif

View file

@ -35,21 +35,23 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#ifdef GNUSTEP #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSObjCRuntime.h> #include <Foundation/NSObjCRuntime.h>
#include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif #endif
#import <Foundation/NSException.h> #include <EOControl/EOCheapArray.h>
#import <Foundation/NSDebug.h> #include <EOControl/EOKeyGlobalID.h>
#include <EOControl/EODebug.h>
#import <EOAccess/EOAccessFault.h> #include <EOAccess/EOAccessFault.h>
#import <EOAccess/EOAccessFaultPriv.h> #include <EOAccess/EOAccessFaultPriv.h>
#import <EOAccess/EODatabaseContext.h> #include <EOAccess/EODatabaseContext.h>
#import <EOAccess/EODatabaseContextPriv.h> #include <EOAccess/EODatabaseContextPriv.h>
#import <EOControl/EOCheapArray.h>
#import <EOControl/EOKeyGlobalID.h>
#import <EOControl/EODebug.h>
NSString *EOAccessFaultObjectNotAvailableException = @"EOAccessFaultObjectNotAvailableException"; NSString *EOAccessFaultObjectNotAvailableException = @"EOAccessFaultObjectNotAvailableException";

View file

@ -27,8 +27,13 @@
#ifndef __EOAdaptor_h__ #ifndef __EOAdaptor_h__
#define __EOAdaptor_h__ #define __EOAdaptor_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSString.h> #include <Foundation/NSString.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <EOAccess/EODefines.h>
@class NSArray; @class NSArray;
@ -46,7 +51,7 @@
@class EOLoginPanel; @class EOLoginPanel;
@class EOEntity; @class EOEntity;
extern NSString *EOGeneralAdaptorException; GDL2ACCESS_EXPORT NSString *EOGeneralAdaptorException;
@interface EOAdaptor : NSObject @interface EOAdaptor : NSObject
@ -56,6 +61,10 @@ extern NSString *EOGeneralAdaptorException;
NSString *_name; NSString *_name;
NSDictionary *_connectionDictionary; NSDictionary *_connectionDictionary;
NSMutableArray *_contexts; // values with contexts NSMutableArray *_contexts; // values with contexts
// Strictly speaking, the _context array is not API compatible
// with WO4.5 as the objects in the array are GC-wrappers.
// Subclasses should access this array via accessor method.
NSString *_expressionClassName; NSString *_expressionClassName;
Class _expressionClass; Class _expressionClass;
id _delegate; // not retained id _delegate; // not retained

View file

@ -46,29 +46,37 @@ RCS_ID("$Id$")
#endif /* !__WIN32__ */ #endif /* !__WIN32__ */
#endif #endif
#import <Foundation/NSArray.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSString.h> #include <Foundation/NSArray.h>
#import <Foundation/NSPathUtilities.h> #include <Foundation/NSString.h>
#import <Foundation/NSBundle.h> #include <Foundation/NSPathUtilities.h>
#import <Foundation/NSObjCRuntime.h> #include <Foundation/NSBundle.h>
#import <Foundation/NSUtilities.h> #include <Foundation/NSObjCRuntime.h>
#import <Foundation/NSValue.h> #include <Foundation/NSUtilities.h>
#import <Foundation/NSProcessInfo.h> #include <Foundation/NSValue.h>
#import <Foundation/NSException.h> #include <Foundation/NSProcessInfo.h>
#import <Foundation/NSFileManager.h> #include <Foundation/NSException.h>
#import <Foundation/NSData.h> #include <Foundation/NSFileManager.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSData.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOAdaptor.h> #include <gnustep/base/Unicode.h>
#import <EOAccess/EOAdaptorPriv.h>
#import <EOAccess/EOModel.h>
#import <EOAccess/EOAttribute.h>
#import <EOAccess/EOSQLExpression.h>
#import <EOAccess/EOAdaptor.h>
#import <EOAccess/EOAdaptorContext.h>
#import <EOAccess/EOAdaptorChannel.h>
#import <EOControl/EODebug.h>
#include <EOControl/EONSAddOns.h>
#include <EOControl/EODebug.h>
#include <EOAccess/EOAdaptor.h>
#include <EOAccess/EOAdaptorPriv.h>
#include <EOAccess/EOModel.h>
#include <EOAccess/EOAttribute.h>
#include <EOAccess/EOSQLExpression.h>
#include <EOAccess/EOAdaptor.h>
#include <EOAccess/EOAdaptorContext.h>
#include <EOAccess/EOAdaptorChannel.h>
NSString *EOGeneralAdaptorException = @"EOGeneralAdaptorException"; NSString *EOGeneralAdaptorException = @"EOGeneralAdaptorException";
@ -369,7 +377,8 @@ NSString *EOGeneralAdaptorException = @"EOGeneralAdaptorException";
- (NSArray *)contexts - (NSArray *)contexts
{ {
return _contexts; SEL sel = @selector(nonretainedObjectValue);
return [_contexts resultsOfPerformingSelector: sel];
} }
- (BOOL)hasOpenChannels - (BOOL)hasOpenChannels
@ -470,7 +479,7 @@ NSString *EOGeneralAdaptorException = @"EOGeneralAdaptorException";
{ {
availableEncodingValue = availableEncodingsArray[count++]; availableEncodingValue = availableEncodingsArray[count++];
availableEncodingString = (NSString *)GetEncodingName(availableEncodingValue); availableEncodingString = GSEncodingName(availableEncodingValue);
if (availableEncodingString) if (availableEncodingString)
{ {

View file

@ -27,8 +27,14 @@
#ifndef __EOAdaptorChannel_h__ #ifndef __EOAdaptorChannel_h__
#define __EOAdaptorChannel_h__ #define __EOAdaptorChannel_h__
#import <Foundation/NSException.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSZone.h> #include <Foundation/NSObject.h>
#include <Foundation/NSZone.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <EOAccess/EODefines.h>
@class NSArray; @class NSArray;
@ -38,6 +44,7 @@
@class NSString; @class NSString;
@class NSMutableString; @class NSMutableString;
@class NSCalendarDate; @class NSCalendarDate;
@class NSException;
@class EOModel; @class EOModel;
@class EOEntity; @class EOEntity;
@ -224,10 +231,10 @@ shouldReturnValuesForStoredProcedure: (NSDictionary *)returnValues;
@end /* NSObject(EOAdaptorChannelDelegation) */ @end /* NSObject(EOAdaptorChannelDelegation) */
extern NSString *EOAdaptorOperationsKey; GDL2ACCESS_EXPORT NSString *EOAdaptorOperationsKey;
extern NSString *EOFailedAdaptorOperationKey; GDL2ACCESS_EXPORT NSString *EOFailedAdaptorOperationKey;
extern NSString *EOAdaptorFailureKey; GDL2ACCESS_EXPORT NSString *EOAdaptorFailureKey;
extern NSString *EOAdaptorOptimisticLockingFailure; GDL2ACCESS_EXPORT NSString *EOAdaptorOptimisticLockingFailure;
#endif /* __EOAdaptorChannel_h__ */ #endif /* __EOAdaptorChannel_h__ */

View file

@ -35,20 +35,31 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/Foundation.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSString.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSEnumerator.h>
#include <Foundation/NSException.h>
#include <Foundation/NSZone.h>
#include <Foundation/NSObjCRuntime.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOEntity.h> #include <EOControl/EOMutableKnownKeyDictionary.h>
#import <EOAccess/EOAttribute.h> #include <EOControl/EOFetchSpecification.h>
#import <EOAccess/EOAdaptor.h> #include <EOControl/EONSAddOns.h>
#import <EOAccess/EOAdaptorContext.h> #include <EOControl/EODebug.h>
#import <EOAccess/EOAdaptorChannel.h>
#import <EOAccess/EOSQLExpression.h>
#import <EOAccess/EODatabaseOperation.h>
#import <EOControl/EOMutableKnownKeyDictionary.h> #include <EOAccess/EOEntity.h>
#import <EOControl/EOFetchSpecification.h> #include <EOAccess/EOAttribute.h>
#import <EOControl/EONSAddOns.h> #include <EOAccess/EOAdaptor.h>
#import <EOControl/EODebug.h> #include <EOAccess/EOAdaptorContext.h>
#include <EOAccess/EOAdaptorChannel.h>
#include <EOAccess/EOSQLExpression.h>
#include <EOAccess/EODatabaseOperation.h>
NSString *EOAdaptorOperationsKey = @"EOAdaptorOperationsKey"; NSString *EOAdaptorOperationsKey = @"EOAdaptorOperationsKey";

View file

@ -27,7 +27,11 @@
#ifndef __EOAdaptorContext_h__ #ifndef __EOAdaptorContext_h__
#define __EOAdaptorContext_h__ #define __EOAdaptorContext_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSObject.h>
#else
#include <Foundation/Foundation.h>
#endif
@class NSMutableArray; @class NSMutableArray;
@ -131,8 +135,8 @@ typedef enum {
@end /* NSObject(EOAdaptorContextDelegate) */ @end /* NSObject(EOAdaptorContextDelegate) */
extern NSString *EOAdaptorContextBeginTransactionNotification; GDL2ACCESS_EXPORT NSString *EOAdaptorContextBeginTransactionNotification;
extern NSString *EOAdaptorContextCommitTransactionNotification; GDL2ACCESS_EXPORT NSString *EOAdaptorContextCommitTransactionNotification;
extern NSString *EOAdaptorContextRollbackTransactionNotification; GDL2ACCESS_EXPORT NSString *EOAdaptorContextRollbackTransactionNotification;
#endif /* __EOAdaptorContext_h__*/ #endif /* __EOAdaptorContext_h__*/

View file

@ -35,19 +35,23 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSArray.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSValue.h> #include <Foundation/NSArray.h>
#import <Foundation/NSUtilities.h> #include <Foundation/NSValue.h>
#import <Foundation/NSNotification.h> #include <Foundation/NSUtilities.h>
#import <Foundation/NSUserDefaults.h> #include <Foundation/NSNotification.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSUserDefaults.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOAdaptor.h> #include <EOControl/EODebug.h>
#import <EOAccess/EOAdaptorPriv.h>
#import <EOAccess/EOAdaptorContext.h>
#import <EOAccess/EOAdaptorChannel.h>
#import <EOControl/EODebug.h> #include <EOAccess/EOAdaptor.h>
#include <EOAccess/EOAdaptorPriv.h>
#include <EOAccess/EOAdaptorContext.h>
#include <EOAccess/EOAdaptorChannel.h>
NSString *EOAdaptorContextBeginTransactionNotification = @"EOAdaptorContextBeginTransactionNotofication"; NSString *EOAdaptorContextBeginTransactionNotification = @"EOAdaptorContextBeginTransactionNotofication";

View file

@ -35,16 +35,19 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSException.h> #include <Foundation/NSException.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EODatabaseOperation.h> #include <EOAccess/EODatabaseOperation.h>
#import <EOAccess/EOAttribute.h> #include <EOAccess/EOAttribute.h>
#import <EOAccess/EOEntity.h> #include <EOAccess/EOEntity.h>
#import <EOControl/EOSortOrdering.h> #include <EOControl/EOSortOrdering.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
@implementation EOAdaptorOperation @implementation EOAdaptorOperation

View file

@ -27,12 +27,16 @@
#ifndef __EOAttribute_h__ #ifndef __EOAttribute_h__
#define __EOAttribute_h__ #define __EOAttribute_h__
#import <Foundation/NSString.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSZone.h> #include <Foundation/NSString.h>
#include <Foundation/NSZone.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <gnustep/base/GCObject.h> #include <gnustep/base/GCObject.h>
#import <EOAccess/EOPropertyListEncoding.h> #include <EOAccess/EOPropertyListEncoding.h>
@class NSDictionary; @class NSDictionary;

View file

@ -41,30 +41,34 @@ RCS_ID("$Id$")
#include <ctype.h> #include <ctype.h>
#include <string.h> #include <string.h>
#import <Foundation/NSUtilities.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSArchiver.h> #include <Foundation/NSUtilities.h>
#import <Foundation/NSObjCRuntime.h> #include <Foundation/NSArchiver.h>
#import <Foundation/NSException.h> #include <Foundation/NSObjCRuntime.h>
#import <Foundation/NSTimeZone.h> #include <Foundation/NSException.h>
#import <Foundation/NSData.h> #include <Foundation/NSTimeZone.h>
#import <Foundation/NSInvocation.h> #include <Foundation/NSData.h>
#import <Foundation/NSDecimalNumber.h> #include <Foundation/NSInvocation.h>
#import <Foundation/NSValue.h> #include <Foundation/NSDecimalNumber.h>
#import <Foundation/NSCalendarDate.h> #include <Foundation/NSValue.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSCalendarDate.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOModel.h> #include <EOControl/EONull.h>
#import <EOAccess/EOEntity.h> #include <EOControl/EOObserver.h>
#import <EOAccess/EOEntityPriv.h> #include <EOControl/EODebug.h>
#import <EOAccess/EOAttribute.h>
#import <EOAccess/EOAttributePriv.h>
#import <EOAccess/EOStoredProcedure.h>
#import <EOAccess/EORelationship.h>
#import <EOAccess/EOExpressionArray.h>
#import <EOControl/EONull.h> #include <EOAccess/EOModel.h>
#import <EOControl/EOObserver.h> #include <EOAccess/EOEntity.h>
#import <EOControl/EODebug.h> #include <EOAccess/EOEntityPriv.h>
#include <EOAccess/EOAttribute.h>
#include <EOAccess/EOAttributePriv.h>
#include <EOAccess/EOStoredProcedure.h>
#include <EOAccess/EORelationship.h>
#include <EOAccess/EOExpressionArray.h>
#include <string.h> #include <string.h>

View file

@ -28,8 +28,13 @@
#define __EODatabase_h__ #define __EODatabase_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSObject.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <EOAccess/EODefines.h>
@class NSArray; @class NSArray;
@class NSMutableArray; @class NSMutableArray;
@ -46,7 +51,7 @@
@class EOEditingContext; @class EOEditingContext;
extern NSString *EOGeneralDatabaseException; GDL2ACCESS_EXPORT NSString *EOGeneralDatabaseException;
@interface EODatabase : NSObject @interface EODatabase : NSObject

View file

@ -35,28 +35,31 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSArray.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSDictionary.h> #include <Foundation/NSArray.h>
#import <Foundation/NSString.h> #include <Foundation/NSDictionary.h>
#import <Foundation/NSException.h> #include <Foundation/NSString.h>
#import <Foundation/NSValue.h> #include <Foundation/NSException.h>
#import <Foundation/NSUtilities.h> #include <Foundation/NSValue.h>
#import <Foundation/NSNotification.h> #include <Foundation/NSUtilities.h>
#import <Foundation/NSSet.h> #include <Foundation/NSNotification.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSSet.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOAccessFault.h> #include <EOControl/EOObjectStore.h>
#import <EOAccess/EOAdaptor.h> #include <EOControl/EOKeyGlobalID.h>
#import <EOAccess/EOModel.h> #include <EOControl/EONull.h>
#import <EOAccess/EOEntity.h> #include <EOControl/EODebug.h>
#import <EOAccess/EODatabase.h>
#import <EOAccess/EODatabaseContext.h>
#import <EOControl/EOObjectStore.h>
#import <EOControl/EOKeyGlobalID.h>
#import <EOControl/EONull.h>
#import <EOControl/EODebug.h>
#include <EOAccess/EOAccessFault.h>
#include <EOAccess/EOAdaptor.h>
#include <EOAccess/EOModel.h>
#include <EOAccess/EOEntity.h>
#include <EOAccess/EODatabase.h>
#include <EOAccess/EODatabaseContext.h>
/* TODO /* TODO

View file

@ -28,7 +28,11 @@
#define __EODatabaseChannel_h__ #define __EODatabaseChannel_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSObject.h>
#else
#include <Foundation/Foundation.h>
#endif
@class NSMutableArray; @class NSMutableArray;

View file

@ -38,32 +38,43 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/Foundation.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSString.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSEnumerator.h>
#include <Foundation/NSNotification.h>
#include <Foundation/NSException.h>
#include <Foundation/NSObjCRuntime.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EODatabaseChannel.h> #include <EOControl/EOEditingContext.h>
#import <EOAccess/EODatabaseChannelPriv.h> #include <EOControl/EOKeyValueCoding.h>
#import <EOAccess/EODatabaseContext.h> #include <EOControl/EOFetchSpecification.h>
#import <EOAccess/EODatabaseContextPriv.h> #include <EOControl/EOClassDescription.h>
#import <EOAccess/EODatabase.h> #include <EOControl/EOKeyGlobalID.h>
#include <EOControl/EOObjectStore.h>
#include <EOControl/EODebug.h>
#import <EOAccess/EOAdaptor.h> #include <EOAccess/EODatabaseChannel.h>
#import <EOAccess/EOAdaptorChannel.h> #include <EOAccess/EODatabaseChannelPriv.h>
#import <EOAccess/EOAdaptorContext.h> #include <EOAccess/EODatabaseContext.h>
#import <EOAccess/EOEntity.h> #include <EOAccess/EODatabaseContextPriv.h>
#import <EOAccess/EOAttribute.h> #include <EOAccess/EODatabase.h>
#import <EOAccess/EORelationship.h>
#import <EOAccess/EOModel.h>
#import <EOAccess/EOAccessFault.h>
#import <EOAccess/EOSQLExpression.h>
#import <EOAccess/EOSQLQualifier.h>
#import <EOControl/EOEditingContext.h> #include <EOAccess/EOAdaptor.h>
#import <EOControl/EOKeyValueCoding.h> #include <EOAccess/EOAdaptorChannel.h>
#import <EOControl/EOFetchSpecification.h> #include <EOAccess/EOAdaptorContext.h>
#import <EOControl/EOClassDescription.h> #include <EOAccess/EOEntity.h>
#import <EOControl/EOKeyGlobalID.h> #include <EOAccess/EOAttribute.h>
#import <EOControl/EOObjectStore.h> #include <EOAccess/EORelationship.h>
#import <EOControl/EODebug.h> #include <EOAccess/EOModel.h>
#include <EOAccess/EOAccessFault.h>
#include <EOAccess/EOSQLExpression.h>
#include <EOAccess/EOSQLQualifier.h>
@implementation EODatabaseChannel @implementation EODatabaseChannel

View file

@ -28,13 +28,19 @@
#define __EODatabaseContext_h__ #define __EODatabaseContext_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSHashTable.h> #include <Foundation/NSObject.h>
#import <Foundation/NSMapTable.h> #include <Foundation/NSHashTable.h>
#import <Foundation/NSLock.h> #include <Foundation/NSMapTable.h>
#import <Foundation/NSDate.h> #include <Foundation/NSLock.h>
#include <Foundation/NSDate.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOObjectStoreCoordinator.h> #include <EOControl/EOObjectStoreCoordinator.h>
#include <EOAccess/EODefines.h>
@class NSMutableSet; @class NSMutableSet;
@ -363,7 +369,7 @@ Only searches locally (in the transaction scope), not in the EODatabase. **/
@end @end
// Notifications: // Notifications:
extern NSString *EODatabaseChannelNeededNotification; GDL2ACCESS_EXPORT NSString *EODatabaseChannelNeededNotification;
@interface NSObject (EODatabaseContextDelegation) @interface NSObject (EODatabaseContextDelegation)
@ -432,10 +438,10 @@ shouldRaiseExceptionForLockFailure: (NSException *)exception;
@end @end
extern NSString *EOCustomQueryExpressionHintKey; GDL2ACCESS_EXPORT NSString *EOCustomQueryExpressionHintKey;
extern NSString *EODatabaseContextKey; GDL2ACCESS_EXPORT NSString *EODatabaseContextKey;
extern NSString *EODatabaseOperationsKey; GDL2ACCESS_EXPORT NSString *EODatabaseOperationsKey;
extern NSString *EOFailedDatabaseOperationKey; GDL2ACCESS_EXPORT NSString *EOFailedDatabaseOperationKey;
#endif /* __EODatabaseContext_h__ */ #endif /* __EODatabaseContext_h__ */

View file

@ -38,57 +38,59 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSArray.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSDictionary.h> #include <Foundation/NSArray.h>
#import <Foundation/NSString.h> #include <Foundation/NSDictionary.h>
#import <Foundation/NSException.h> #include <Foundation/NSString.h>
#import <Foundation/NSValue.h> #include <Foundation/NSException.h>
#import <Foundation/NSUtilities.h> #include <Foundation/NSValue.h>
#import <Foundation/NSZone.h> #include <Foundation/NSUtilities.h>
#import <Foundation/NSNotification.h> #include <Foundation/NSZone.h>
#import <Foundation/NSSet.h> #include <Foundation/NSNotification.h>
#import <Foundation/NSData.h> #include <Foundation/NSSet.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSData.h>
#if FOUNDATION_HAS_KVC #include <Foundation/NSKeyValueCoding.h>
#import <Foundation/NSKeyValueCoding.h> #include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif #endif
#include <string.h> #include <gnustep/base/GSObjCRuntime.h>
#import <EOAccess/EOAdaptor.h> #include <EOControl/EOFault.h>
#import <EOAccess/EOAdaptorChannel.h> #include <EOControl/EOEditingContext.h>
#import <EOAccess/EOAdaptorContext.h> #include <EOControl/EOClassDescription.h>
#import <EOAccess/EOModel.h> #include <EOControl/EOGenericRecord.h>
#import <EOAccess/EOModelGroup.h> #include <EOControl/EOQualifier.h>
#import <EOAccess/EOEntity.h> #include <EOControl/EOKeyGlobalID.h>
#import <EOAccess/EORelationship.h> #include <EOControl/EOFetchSpecification.h>
#import <EOAccess/EOAttribute.h> #include <EOControl/EOSortOrdering.h>
#import <EOAccess/EOStoredProcedure.h> #include <EOControl/EOKeyValueCoding.h>
#import <EOAccess/EOJoin.h> #include <EOControl/EOMutableKnownKeyDictionary.h>
#include <EOControl/EOCheapArray.h>
#include <EOControl/EONSAddOns.h>
#include <EOControl/EONull.h>
#include <EOControl/EODebug.h>
#import <EOAccess/EODatabase.h> #include <EOAccess/EOAdaptor.h>
#import <EOAccess/EODatabaseContext.h> #include <EOAccess/EOAdaptorChannel.h>
#import <EOAccess/EODatabaseContextPriv.h> #include <EOAccess/EOAdaptorContext.h>
#import <EOAccess/EODatabaseChannel.h> #include <EOAccess/EOModel.h>
#import <EOAccess/EODatabaseOperation.h> #include <EOAccess/EOModelGroup.h>
#import <EOAccess/EOAccessFault.h> #include <EOAccess/EOEntity.h>
#import <EOAccess/EOAccessFaultPriv.h> #include <EOAccess/EORelationship.h>
#import <EOAccess/EOExpressionArray.h> #include <EOAccess/EOAttribute.h>
#include <EOAccess/EOStoredProcedure.h>
#include <EOAccess/EOJoin.h>
#import <EOControl/EOFault.h> #include <EOAccess/EODatabase.h>
#import <EOControl/EOEditingContext.h> #include <EOAccess/EODatabaseContext.h>
#import <EOControl/EOClassDescription.h> #include <EOAccess/EODatabaseContextPriv.h>
#import <EOControl/EOGenericRecord.h> #include <EOAccess/EODatabaseChannel.h>
#import <EOControl/EOQualifier.h> #include <EOAccess/EODatabaseOperation.h>
#import <EOControl/EOKeyGlobalID.h> #include <EOAccess/EOAccessFault.h>
#import <EOControl/EOFetchSpecification.h> #include <EOAccess/EOAccessFaultPriv.h>
#import <EOControl/EOSortOrdering.h> #include <EOAccess/EOExpressionArray.h>
#import <EOControl/EOKeyValueCoding.h>
#import <EOControl/EOMutableKnownKeyDictionary.h>
#import <EOControl/EOCheapArray.h>
#import <EOControl/EONSAddOns.h>
#import <EOControl/EONull.h>
#import <EOControl/EODebug.h>
#include <string.h> #include <string.h>
@ -700,12 +702,14 @@ May raise an exception if transaction has began or if you want pessimistic lock
editingContext: context]; editingContext: context];
EOFLOGObjectLevelArgs(@"EODatabaseContext", @"handler=%@", handler); EOFLOGObjectLevelArgs(@"EODatabaseContext", @"handler=%@", handler);
EOFLOGObjectLevelArgs(@"EODatabaseContext", @"object->isa=%p", object->isa); EOFLOGObjectLevelArgs(@"EODatabaseContext", @"object->class_pointer=%p",
GSObjCClass(object));
[EOFault makeObjectIntoFault: object [EOFault makeObjectIntoFault: object
withHandler: handler]; withHandler: handler];
EOFLOGObjectLevelArgs(@"EODatabaseContext", @"object->isa=%p", object->isa); EOFLOGObjectLevelArgs(@"EODatabaseContext", @"object->class_pointer=%p",
GSObjCClass(object));
[self _addBatchForGlobalID: (EOKeyGlobalID*)globalID [self _addBatchForGlobalID: (EOKeyGlobalID*)globalID
fault: object]; fault: object];

View file

@ -28,9 +28,7 @@
#define __EODatabaseDataSource_h__ #define __EODatabaseDataSource_h__
#import <Foundation/NSObject.h> #include <EOControl/EODataSource.h>
#import <EOControl/EODataSource.h>
@class NSDictionary; @class NSDictionary;

View file

@ -40,28 +40,32 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSString.h> #include <Foundation/NSString.h>
#import <Foundation/NSException.h> #include <Foundation/NSArray.h>
#import <Foundation/NSCoder.h> #include <Foundation/NSDictionary.h>
#import <Foundation/NSEnumerator.h> #include <Foundation/NSEnumerator.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSException.h>
#import <Foundation/NSEnumerator.h> #include <Foundation/NSCoder.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EODatabaseDataSource.h> #include <EOControl/EOEditingContext.h>
#import <EOAccess/EOEntity.h> #include <EOControl/EOQualifier.h>
#import <EOAccess/EOModel.h> #include <EOControl/EOFetchSpecification.h>
#import <EOAccess/EOModelGroup.h> #include <EOControl/EOKeyValueArchiver.h>
#import <EOAccess/EODatabase.h> #include <EOControl/EODataSource.h>
#import <EOAccess/EODatabaseContext.h> #include <EOControl/EODetailDataSource.h>
#include <EOControl/EODebug.h>
#import <EOControl/EOEditingContext.h> #include <EOAccess/EODatabaseDataSource.h>
#import <EOControl/EOQualifier.h> #include <EOAccess/EOEntity.h>
#import <EOControl/EOFetchSpecification.h> #include <EOAccess/EOModel.h>
#import <EOControl/EOKeyValueArchiver.h> #include <EOAccess/EOModelGroup.h>
#import <EOControl/EODataSource.h> #include <EOAccess/EODatabase.h>
#import <EOControl/EODetailDataSource.h> #include <EOAccess/EODatabaseContext.h>
#import <EOControl/EODebug.h>
@interface EODatabaseDataSource(Private) @interface EODatabaseDataSource(Private)

View file

@ -27,7 +27,11 @@
#ifndef __EODatabaseOperation_h__ #ifndef __EODatabaseOperation_h__
#define __EODatabaseOperation_h__ #define __EODatabaseOperation_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSObject.h>
#else
#include <Foundation/Foundation.h>
#endif
@class NSArray; @class NSArray;

View file

@ -35,16 +35,22 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSException.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSEnumerator.h> #include <Foundation/NSString.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSArray.h>
#import <Foundation/NSEnumerator.h> #include <Foundation/NSDictionary.h>
#include <Foundation/NSEnumerator.h>
#include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EODatabaseOperation.h> #include <EOControl/EODebug.h>
#import <EOAccess/EOAttribute.h>
#import <EOAccess/EOEntity.h>
#import <EOControl/EODebug.h> #include <EOAccess/EODatabaseOperation.h>
#include <EOAccess/EOAttribute.h>
#include <EOAccess/EOEntity.h>
@implementation EODatabaseOperation @implementation EODatabaseOperation

47
EOAccess/EODefines.h Normal file
View file

@ -0,0 +1,47 @@
/*
EODefines.h
Copyright (C) 2003 Free Software Foundation, Inc.
Author: Stephane Corthesy <stephane@sente.ch>
Date: Feb 2003
This file is part of the GNUstep Database Library.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; see the file COPYING.LIB.
If not, write to the Free Software Foundation,
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#ifndef __EOAccess_EODefines_h__
#define __EOAccess_EODefines_h__
#ifdef GNUSTEP_WITH_DLL
#if BUILD_libgnustep_db2_DLL
# define GDL2ACCESS_EXPORT __declspec(dllexport)
# define GDL2ACCESS_DECLARE __declspec(dllexport)
#else
# define GDL2ACCESS_EXPORT extern __declspec(dllimport)
# define GDL2ACCESS_DECLARE __declspec(dllimport)
#endif
#else /* GNUSTEP_WITH[OUT]_DLL */
# define GDL2ACCESS_EXPORT extern
# define GDL2ACCESS_DECLARE
#endif
#endif /* __EOAccess_EODefines_h__ */

33
EOAccess/EODepricated.h Normal file
View file

@ -0,0 +1,33 @@
/*
EODeprecated.h
Copyright (C) 2002 Free Software Foundation, Inc.
Author: Stephane Corthesy <stephane@sente.ch>
Date: Feb 2003
This file is part of the GNUstep Database Library.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; see the file COPYING.LIB.
If not, write to the Free Software Foundation,
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#ifndef __EOAccess_EODeprecated_h__
#define __EOAccess_EODeprecated_h__
#include <EOAccess/EOAdaptor.h>
#include <EOAccess/EOModelGroup.h>
#endif

View file

@ -27,12 +27,19 @@
#ifndef __EOEntity_h__ #ifndef __EOEntity_h__
#define __EOEntity_h__ #define __EOEntity_h__
#import <Foundation/NSString.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSException.h> #include <Foundation/NSString.h>
#include <Foundation/NSException.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOPropertyListEncoding.h> #include <gnustep/base/GCObject.h>
#import <EOControl/EOClassDescription.h>
#import <gnustep/base/GCObject.h> #include <EOControl/EOClassDescription.h>
#include <EOAccess/EODefines.h>
#include <EOAccess/EOPropertyListEncoding.h>
@class EOModel; @class EOModel;
@ -258,11 +265,11 @@
@end @end
extern NSString *EOFetchAllProcedureOperation; GDL2ACCESS_EXPORT NSString *EOFetchAllProcedureOperation;
extern NSString *EOFetchWithPrimaryKeyProcedureOperation; GDL2ACCESS_EXPORT NSString *EOFetchWithPrimaryKeyProcedureOperation;
extern NSString *EOInsertProcedureOperation; GDL2ACCESS_EXPORT NSString *EOInsertProcedureOperation;
extern NSString *EODeleteProcedureOperation; GDL2ACCESS_EXPORT NSString *EODeleteProcedureOperation;
extern NSString *EONextPrimaryKeyProcedureOperation; GDL2ACCESS_EXPORT NSString *EONextPrimaryKeyProcedureOperation;
@interface EOEntity (MethodSet11) @interface EOEntity (MethodSet11)
- (NSException *)validateObjectForDelete: (id)object; - (NSException *)validateObjectForDelete: (id)object;

View file

@ -40,26 +40,44 @@ RCS_ID("$Id$")
#include <ctype.h> #include <ctype.h>
#import <Foundation/Foundation.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSString.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSSet.h>
#include <Foundation/NSEnumerator.h>
#include <Foundation/NSValue.h>
#include <Foundation/NSNull.h>
#include <Foundation/NSProcessInfo.h>
#include <Foundation/NSFileManager.h>
#include <Foundation/NSFormatter.h>
#include <Foundation/NSAutoreleasePool.h>
#include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#include <Foundation/NSObjCRuntime.h>
#include <Foundation/NSZone.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOModel.h> #include <EOControl/EOKeyValueCoding.h>
#import <EOAccess/EOEntity.h> #include <EOControl/EOQualifier.h>
#import <EOAccess/EOEntityPriv.h> #include <EOControl/EOKeyGlobalID.h>
#import <EOAccess/EOAttribute.h> #include <EOControl/EOEditingContext.h>
#import <EOAccess/EOAttributePriv.h> #include <EOControl/EONull.h>
#import <EOAccess/EORelationship.h> #include <EOControl/EOMutableKnownKeyDictionary.h>
#import <EOAccess/EOStoredProcedure.h> #include <EOControl/EONSAddOns.h>
#import <EOAccess/EOExpressionArray.h> #include <EOControl/EOCheapArray.h>
#include <EOControl/EODebug.h>
#import <EOControl/EOKeyValueCoding.h> #include <EOAccess/EOModel.h>
#import <EOControl/EOQualifier.h> #include <EOAccess/EOEntity.h>
#import <EOControl/EOKeyGlobalID.h> #include <EOAccess/EOEntityPriv.h>
#import <EOControl/EOEditingContext.h> #include <EOAccess/EOAttribute.h>
#import <EOControl/EONull.h> #include <EOAccess/EOAttributePriv.h>
#import <EOControl/EOMutableKnownKeyDictionary.h> #include <EOAccess/EORelationship.h>
#import <EOControl/EONSAddOns.h> #include <EOAccess/EOStoredProcedure.h>
#import <EOControl/EOCheapArray.h> #include <EOAccess/EOExpressionArray.h>
#import <EOControl/EODebug.h>
NSString *EOFetchAllProcedureOperation = @"EOFetchAllProcedureOperation"; NSString *EOFetchAllProcedureOperation = @"EOFetchAllProcedureOperation";

View file

@ -28,8 +28,13 @@
#define __EOExpressionArray_h__ #define __EOExpressionArray_h__
#import <Foundation/NSString.h> #ifndef NeXT_Foundation_LIBRARY
#import <gnustep/base/GCObject.h> #include <Foundation/NSString.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <gnustep/base/GCObject.h>
@class NSArray; @class NSArray;

View file

@ -40,21 +40,24 @@ RCS_ID("$Id$")
#include <ctype.h> #include <ctype.h>
#import <Foundation/NSString.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSAutoreleasePool.h> #include <Foundation/NSString.h>
#import <Foundation/NSValue.h> #include <Foundation/NSAutoreleasePool.h>
#import <Foundation/NSDate.h> #include <Foundation/NSValue.h>
#import <Foundation/NSException.h> #include <Foundation/NSDate.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <gnustep/base/GSObjCRuntime.h> #include <gnustep/base/GSObjCRuntime.h>
#import <EOAccess/EOEntity.h> #include <EOControl/EODebug.h>
#import <EOAccess/EOExpressionArray.h>
#import <EOAccess/EORelationship.h>
#import <EOControl/EODebug.h>
#include <EOAccess/EOEntity.h>
#include <EOAccess/EOExpressionArray.h>
#include <EOAccess/EORelationship.h>
@implementation EOExpressionArray @implementation EOExpressionArray
@ -319,7 +322,8 @@ if it's a string return NO
{ {
//TODO verify //TODO verify
NSMutableString *value = [NSMutableString string]; NSMutableString *value = [NSMutableString string];
int i, count; volatile int i;
int count;
NS_DURING //Just for debugging NS_DURING //Just for debugging
{ {

View file

@ -27,7 +27,7 @@
#ifndef __EOJoin_h__ #ifndef __EOJoin_h__
#define __EOJoin_h__ #define __EOJoin_h__
#import <gnustep/base/GCObject.h> #include <gnustep/base/GCObject.h>
@class NSString; @class NSString;

View file

@ -35,17 +35,21 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSString.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSUtilities.h> #include <Foundation/NSString.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSUtilities.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOModel.h> #include <EOControl/EODebug.h>
#import <EOAccess/EOEntity.h>
#import <EOAccess/EOAttribute.h>
#import <EOAccess/EORelationship.h>
#import <EOAccess/EOJoin.h>
#import <EOControl/EODebug.h> #include <EOAccess/EOModel.h>
#include <EOAccess/EOEntity.h>
#include <EOAccess/EOAttribute.h>
#include <EOAccess/EORelationship.h>
#include <EOAccess/EOJoin.h>
@implementation EOJoin @implementation EOJoin

View file

@ -28,10 +28,15 @@
#define __EOModel_h__ #define __EOModel_h__
#import <Foundation/NSString.h> #ifndef NeXT_Foundation_LIBRARY
#import <gnustep/base/GCObject.h> #include <Foundation/NSString.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <gnustep/base/GCObject.h>
#import <EOAccess/EOPropertyListEncoding.h> #include <EOAccess/EODefines.h>
#include <EOAccess/EOPropertyListEncoding.h>
@class NSArray; @class NSArray;
@ -180,6 +185,6 @@
@end @end
extern NSString *EOEntityLoadedNotification; GDL2ACCESS_EXPORT NSString *EOEntityLoadedNotification;
#endif /* __EOModel_h__ */ #endif /* __EOModel_h__ */

View file

@ -36,33 +36,37 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSBundle.h>
#include <Foundation/NSValue.h>
#include <Foundation/NSUtilities.h>
#include <Foundation/NSObjCRuntime.h>
#include <Foundation/NSException.h>
#include <Foundation/NSFileManager.h>
#include <Foundation/NSValue.h>
#include <Foundation/NSNotification.h>
#include <Foundation/NSPathUtilities.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <gnustep/base/GSObjCRuntime.h> #include <gnustep/base/GSObjCRuntime.h>
#import <Foundation/NSBundle.h> #include <EOControl/EOGenericRecord.h>
#import <Foundation/NSValue.h> #include <EOControl/EOFault.h>
#import <Foundation/NSUtilities.h> #include <EOControl/EOKeyGlobalID.h>
#import <Foundation/NSObjCRuntime.h> #include <EOControl/EOClassDescription.h>
#import <Foundation/NSException.h> #include <EOControl/EOObserver.h>
#import <Foundation/NSFileManager.h> #include <EOControl/EONSAddOns.h>
#import <Foundation/NSValue.h> #include <EOControl/EODebug.h>
#import <Foundation/NSNotification.h>
#import <Foundation/NSPathUtilities.h>
#import <Foundation/NSDebug.h>
#import <EOAccess/EOModel.h> #include <EOAccess/EOModel.h>
#import <EOAccess/EOEntity.h> #include <EOAccess/EOEntity.h>
#import <EOAccess/EOEntityPriv.h> #include <EOAccess/EOEntityPriv.h>
#import <EOAccess/EOStoredProcedure.h> #include <EOAccess/EOStoredProcedure.h>
#import <EOAccess/EOModelGroup.h> #include <EOAccess/EOModelGroup.h>
#import <EOAccess/EOAccessFault.h> #include <EOAccess/EOAccessFault.h>
#import <EOControl/EOGenericRecord.h>
#import <EOControl/EOFault.h>
#import <EOControl/EOKeyGlobalID.h>
#import <EOControl/EOClassDescription.h>
#import <EOControl/EOObserver.h>
#import <EOControl/EONSAddOns.h>
#import <EOControl/EODebug.h>
NSString *EOEntityLoadedNotification = @"EOEntityLoadedNotification"; NSString *EOEntityLoadedNotification = @"EOEntityLoadedNotification";
@ -347,7 +351,8 @@ NSString *EOEntityLoadedNotification = @"EOEntityLoadedNotification";
- (NSArray*) entityNames - (NSArray*) entityNames
{ {
return [_entitiesByName allKeys]; return [[_entitiesByName allKeys]
sortedArrayUsingSelector: @selector(compare:)];
} }
- (NSArray*) storedProcedureNames - (NSArray*) storedProcedureNames

View file

@ -27,10 +27,9 @@
#ifndef __EOModelGroup_h__ #ifndef __EOModelGroup_h__
#define __EOModelGroup_h__ #define __EOModelGroup_h__
#import <Foundation/NSObject.h> #include <gnustep/base/GCObject.h>
#import <gnustep/base/GCObject.h>
#import <EOControl/EOObjectStoreCoordinator.h> #include <EOControl/EOObjectStoreCoordinator.h>
@class NSArray; @class NSArray;

View file

@ -35,18 +35,22 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSBundle.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSNotification.h> #include <Foundation/NSBundle.h>
#import <Foundation/NSEnumerator.h> #include <Foundation/NSNotification.h>
#import <Foundation/NSPathUtilities.h> #include <Foundation/NSEnumerator.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSPathUtilities.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOModelGroup.h> #include <EOAccess/EOModelGroup.h>
#import <EOAccess/EOModel.h> #include <EOAccess/EOModel.h>
#import <EOAccess/EOEntity.h> #include <EOAccess/EOEntity.h>
#import <EOAccess/EOStoredProcedure.h> #include <EOAccess/EOStoredProcedure.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
@implementation EOModelGroup @implementation EOModelGroup

View file

@ -28,7 +28,11 @@
#define __EOPropertyListEncoding_h__ #define __EOPropertyListEncoding_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSObject.h>
#else
#include <Foundation/Foundation.h>
#endif
@class NSDictionary; @class NSDictionary;

View file

@ -27,15 +27,15 @@
#ifndef __EORelationship_h__ #ifndef __EORelationship_h__
#define __EORelationship_h__ #define __EORelationship_h__
#import <Foundation/NSString.h> #include <gnustep/base/GCObject.h>
#import <gnustep/base/GCObject.h>
#import <EOAccess/EOJoin.h> #include <EOControl/EOClassDescription.h>
#import <EOAccess/EOPropertyListEncoding.h>
#import <EOControl/EOClassDescription.h> #include <EOAccess/EOJoin.h>
#include <EOAccess/EOPropertyListEncoding.h>
@class NSString;
@class NSArray; @class NSArray;
@class NSMutableArray; @class NSMutableArray;
@class NSDictionary; @class NSDictionary;
@ -151,6 +151,8 @@ typedef enum {
- (BOOL)ownsDestination; - (BOOL)ownsDestination;
- (EOQualifier *)qualifierWithSourceRow: (NSDictionary *)sourceRow; - (EOQualifier *)qualifierWithSourceRow: (NSDictionary *)sourceRow;
/** Accessing documentation comments **/
- (NSString*)docComment;
@end @end

View file

@ -38,25 +38,29 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSArray.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSUtilities.h> #include <Foundation/NSArray.h>
#import <Foundation/NSException.h> #include <Foundation/NSUtilities.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOModel.h> #include <EOControl/EOObserver.h>
#import <EOAccess/EOAttribute.h> #include <EOControl/EOMutableKnownKeyDictionary.h>
#import <EOAccess/EOAttributePriv.h> #include <EOControl/EONSAddOns.h>
#import <EOAccess/EOEntity.h> #include <EOControl/EODebug.h>
#import <EOAccess/EOEntityPriv.h>
#import <EOAccess/EOStoredProcedure.h>
#import <EOAccess/EORelationship.h>
#import <EOAccess/EOJoin.h>
#import <EOAccess/EOExpressionArray.h>
#import <EOControl/EOObserver.h> #include <EOAccess/EOModel.h>
#import <EOControl/EOMutableKnownKeyDictionary.h> #include <EOAccess/EOAttribute.h>
#import <EOControl/EONSAddOns.h> #include <EOAccess/EOAttributePriv.h>
#import <EOControl/EODebug.h> #include <EOAccess/EOEntity.h>
#include <EOAccess/EOEntityPriv.h>
#include <EOAccess/EOStoredProcedure.h>
#include <EOAccess/EORelationship.h>
#include <EOAccess/EOJoin.h>
#include <EOAccess/EOExpressionArray.h>
@implementation EORelationship @implementation EORelationship

View file

@ -27,12 +27,17 @@
#ifndef __EOSQLExpression_h__ #ifndef __EOSQLExpression_h__
#define __EOSQLExpression_h__ #define __EOSQLExpression_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSString.h> #include <Foundation/NSObject.h>
#import <Foundation/NSValue.h> #include <Foundation/NSString.h>
#include <Foundation/NSValue.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOJoin.h> #include <EOAccess/EOJoin.h>
#import <EOAccess/EORelationship.h> #include <EOAccess/EORelationship.h>
#include <EOAccess/EODefines.h>
@class NSArray; @class NSArray;
@ -49,11 +54,11 @@
@class EOFetchSpecification; @class EOFetchSpecification;
extern NSString *EOBindVariableNameKey; GDL2ACCESS_EXPORT NSString *EOBindVariableNameKey;
extern NSString *EOBindVariableAttributeKey; GDL2ACCESS_EXPORT NSString *EOBindVariableAttributeKey;
extern NSString *EOBindVariableValueKey; GDL2ACCESS_EXPORT NSString *EOBindVariableValueKey;
extern NSString *EOBindVariablePlaceHolderKey; GDL2ACCESS_EXPORT NSString *EOBindVariablePlaceHolderKey;
extern NSString *EOBindVariableColumnKey; GDL2ACCESS_EXPORT NSString *EOBindVariableColumnKey;
@interface EOSQLExpression : NSObject @interface EOSQLExpression : NSObject

View file

@ -40,32 +40,39 @@ RCS_ID("$Id$")
#include <string.h> #include <string.h>
#import <Foundation/NSString.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSSet.h> #include <Foundation/NSString.h>
#import <Foundation/NSUtilities.h> #include <Foundation/NSSet.h>
#import <Foundation/NSException.h> #include <Foundation/NSUtilities.h>
#import <Foundation/NSUserDefaults.h> #include <Foundation/NSException.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSUserDefaults.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOEntity.h> #include <gnustep/base/GSCategories.h>
#import <EOAccess/EOAttribute.h>
#import <EOAccess/EOAttributePriv.h> #include <EOControl/EOFetchSpecification.h>
#import <EOAccess/EORelationship.h> #include <EOControl/EOQualifier.h>
#import <EOAccess/EOAdaptor.h> #include <EOControl/EOSortOrdering.h>
#import <EOAccess/EOAdaptorContext.h> #include <EOControl/EODebug.h>
#import <EOAccess/EOAdaptorChannel.h> #include <EOControl/EONull.h>
#import <EOAccess/EOJoin.h>
#import <EOAccess/EOSQLExpression.h> #include <EOAccess/EOEntity.h>
#import <EOAccess/EOSQLExpressionPriv.h> #include <EOAccess/EOAttribute.h>
#import <EOAccess/EOSQLQualifier.h> #include <EOAccess/EOAttributePriv.h>
#import <EOAccess/EOExpressionArray.h> #include <EOAccess/EORelationship.h>
#import <EOAccess/EOSchemaGeneration.h> #include <EOAccess/EOAdaptor.h>
#include <EOAccess/EOAdaptorContext.h>
#include <EOAccess/EOAdaptorChannel.h>
#include <EOAccess/EOJoin.h>
#include <EOAccess/EOSQLExpression.h>
#include <EOAccess/EOSQLExpressionPriv.h>
#include <EOAccess/EOSQLQualifier.h>
#include <EOAccess/EOExpressionArray.h>
#include <EOAccess/EOSchemaGeneration.h>
#import <EOControl/EOFetchSpecification.h>
#import <EOControl/EOQualifier.h>
#import <EOControl/EOSortOrdering.h>
#import <EOControl/EODebug.h>
#import <EOControl/EONull.h>
NSString *EOBindVariableNameKey = @"EOBindVariableNameKey"; NSString *EOBindVariableNameKey = @"EOBindVariableNameKey";
@ -1305,7 +1312,7 @@ NSString *EOBindVariableColumnKey = @"EOBindVariableColumnKey";
tmpSqlString=[self sqlStringForNegatedQualifier:qualifier]; tmpSqlString=[self sqlStringForNegatedQualifier:qualifier];
else if ([qualifier isKindOfClass:[EOKeyComparisonQualifier class]]) else if ([qualifier isKindOfClass:[EOKeyComparisonQualifier class]])
tmpSqlString=[self sqlStringForKeyComparisonQualifier:qualifier]; tmpSqlString=[self sqlStringForKeyComparisonQualifier:(id)qualifier];
else else
[NSException raise: NSInternalInconsistencyException [NSException raise: NSInternalInconsistencyException
@ -2400,7 +2407,7 @@ NSString *EOCreateTablesKey = @"EOCreateTablesKey";
NSString *EODropTablesKey = @"EODropTablesKey"; NSString *EODropTablesKey = @"EODropTablesKey";
NSString *EOCreatePrimaryKeySupportKey = @"EOCreatePrimaryKeySupportKey"; NSString *EOCreatePrimaryKeySupportKey = @"EOCreatePrimaryKeySupportKey";
NSString *EODropPrimaryKeySupportKey = @"EODropPrimaryKeySupportKey"; NSString *EODropPrimaryKeySupportKey = @"EODropPrimaryKeySupportKey";
NSString *EOPrimaryKeyContraintsKey = @"EOPrimaryKeyContraintsKey"; NSString *EOPrimaryKeyConstraintsKey = @"EOPrimaryKeyConstraintsKey";
NSString *EOForeignKeyConstraintsKey = @"EOForeignKeyConstraintsKey"; NSString *EOForeignKeyConstraintsKey = @"EOForeignKeyConstraintsKey";
NSString *EOCreateDatabaseKey = @"EOCreateDatabaseKey"; NSString *EOCreateDatabaseKey = @"EOCreateDatabaseKey";
NSString *EODropDatabaseKey = @"EODropDatabaseKey"; NSString *EODropDatabaseKey = @"EODropDatabaseKey";
@ -2813,7 +2820,7 @@ struct _schema
@selector(createTableStatementsForEntityGroups:)}, @selector(createTableStatementsForEntityGroups:)},
{EOCreatePrimaryKeySupportKey, @"YES", {EOCreatePrimaryKeySupportKey, @"YES",
@selector(primaryKeySupportStatementsForEntityGroups:)}, @selector(primaryKeySupportStatementsForEntityGroups:)},
{EOPrimaryKeyContraintsKey , @"YES", {EOPrimaryKeyConstraintsKey , @"YES",
@selector(primaryKeyConstraintStatementsForEntityGroups:)}, @selector(primaryKeyConstraintStatementsForEntityGroups:)},
{EOForeignKeyConstraintsKey , @"NO", {EOForeignKeyConstraintsKey , @"NO",
@selector(foreignKeyConstraintStatementsForEntityGroups:)}, @selector(foreignKeyConstraintStatementsForEntityGroups:)},

View file

@ -27,7 +27,8 @@
#ifndef __EOSQLExpressionPriv_h__ #ifndef __EOSQLExpressionPriv_h__
#define __EOSQLExpressionPriv_h__ #define __EOSQLExpressionPriv_h__
#import <EOAccess/EOJoin.h> #include <EOAccess/EOSQLExpression.h>
#include <EOAccess/EORelationship.h>
@class NSString; @class NSString;
@class EOEntity; @class EOEntity;

View file

@ -31,10 +31,13 @@
#define __EOSQLQualifier_h__ #define __EOSQLQualifier_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSString.h> #include <Foundation/NSString.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOQualifier.h> #include <EOControl/EOQualifier.h>
@class EOSQLExpression; @class EOSQLExpression;

View file

@ -38,24 +38,28 @@ RCS_ID("$Id$")
#include <stdio.h> #include <stdio.h>
#include <string.h> #include <string.h>
#import <Foundation/NSDictionary.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSSet.h> #include <Foundation/NSDictionary.h>
#import <Foundation/NSUtilities.h> #include <Foundation/NSSet.h>
#import <Foundation/NSException.h> #include <Foundation/NSUtilities.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOSQLQualifier.h> #include <EOAccess/EOSQLQualifier.h>
#import <EOAccess/EOAttribute.h> #include <EOAccess/EOAttribute.h>
#import <EOAccess/EORelationship.h> #include <EOAccess/EORelationship.h>
#import <EOAccess/EOJoin.h> #include <EOAccess/EOJoin.h>
#import <EOAccess/EOEntity.h> #include <EOAccess/EOEntity.h>
#import <EOAccess/EOSQLExpression.h> #include <EOAccess/EOSQLExpression.h>
#import <EOControl/EOQualifier.h> #include <EOControl/EOQualifier.h>
#import <EOControl/EOEditingContext.h> #include <EOControl/EOEditingContext.h>
#import <EOControl/EOObjectStoreCoordinator.h> #include <EOControl/EOObjectStoreCoordinator.h>
#import <EOControl/EONull.h> #include <EOControl/EONull.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
@implementation EOSQLQualifier @implementation EOSQLQualifier

View file

@ -27,10 +27,9 @@
#ifndef __EOStoredProcedure_h__ #ifndef __EOStoredProcedure_h__
#define __EOStoredProcedure_h__ #define __EOStoredProcedure_h__
#import <Foundation/NSObject.h> #include <gnustep/base/GCObject.h>
#import <gnustep/base/GCObject.h>
#import <EOAccess/EOPropertyListEncoding.h> #include <EOAccess/EOPropertyListEncoding.h>
@class NSDictionary; @class NSDictionary;

View file

@ -35,17 +35,21 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSException.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSEnumerator.h> #include <Foundation/NSException.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSEnumerator.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <gnustep/base/GCObject.h> #include <gnustep/base/GCObject.h>
#import <EOAccess/EOStoredProcedure.h> #include <EOControl/EODebug.h>
#import <EOAccess/EOAttribute.h>
#import <EOAccess/EOModel.h>
#import <EOControl/EODebug.h> #include <EOAccess/EOStoredProcedure.h>
#include <EOAccess/EOAttribute.h>
#include <EOAccess/EOModel.h>
@implementation EOStoredProcedure @implementation EOStoredProcedure

View file

@ -28,9 +28,11 @@
#define __EOUtilities_h__ #define __EOUtilities_h__
#import <EOControl/EOEditingContext.h> #include <EOControl/EOEditingContext.h>
#import <EOControl/EOFetchSpecification.h> #include <EOControl/EOFetchSpecification.h>
#import <EOControl/EOObjectStoreCoordinator.h> #include <EOControl/EOObjectStoreCoordinator.h>
#include <EOAccess/EODefines.h>
@class NSArray; @class NSArray;
@ -42,7 +44,7 @@
@class EOEntity; @class EOEntity;
extern NSString *EOMoreThanOneException; GDL2ACCESS_EXPORT NSString *EOMoreThanOneException;
@interface EOEditingContext (EOUtilities) @interface EOEditingContext (EOUtilities)

View file

@ -35,16 +35,38 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/Foundation.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSString.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSEnumerator.h>
#include <Foundation/NSException.h>
#include <Foundation/NSObjCRuntime.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOEditingContext.h> #include <EOControl/EOKeyGlobalID.h>
#import <EOControl/EOQualifier.h> #include <EOControl/EOQualifier.h>
#import <EOControl/EOFetchSpecification.h> #include <EOControl/EONull.h>
#import <EOControl/EONull.h> #include <EOControl/EOGenericRecord.h>
#import <EOControl/EOGenericRecord.h> #include <EOControl/EODebug.h>
#import <EOControl/EODebug.h>
#import <EOAccess/EOAccess.h> #include <EOAccess/EOAttribute.h>
#include <EOAccess/EORelationship.h>
#include <EOAccess/EOJoin.h>
#include <EOAccess/EOEntity.h>
#include <EOAccess/EOModel.h>
#include <EOAccess/EOModelGroup.h>
#include <EOAccess/EODatabase.h>
#include <EOAccess/EODatabaseContext.h>
#include <EOAccess/EODatabaseChannel.h>
#include <EOAccess/EOSQLExpression.h>
#include <EOAccess/EOAdaptorChannel.h>
#include <EOAccess/EOStoredProcedure.h>
#include <EOAccess/EOUtilities.h>
static NSString *EOMoreThanOneException = @"EOMoreThanOneException"; static NSString *EOMoreThanOneException = @"EOMoreThanOneException";
@ -1104,7 +1126,7 @@ connectionDictionaryOverrides: (NSDictionary *)overrides
forKey: @"EOModelGroup"]; forKey: @"EOModelGroup"];
else else
{ {
userInfo = [NSMutableDictionary dictionary]; userInfo = (id)[NSMutableDictionary dictionary];
[userInfo setObject: modelGroup [userInfo setObject: modelGroup
forKey: @"EOModelGroup"]; forKey: @"EOModelGroup"];

View file

@ -88,7 +88,10 @@ EOPropertyListEncoding.h \
EODatabaseDataSource.h \ EODatabaseDataSource.h \
EOSchemaGeneration.h \ EOSchemaGeneration.h \
EOUtilities.h \ EOUtilities.h \
EOAccess.h EODefines.h \
EODepricated.h \
EOAccess.h \
gdl2_AUTOGSDOC_HEADERS = $(libgnustep-db2_HEADER_FILES) gdl2_AUTOGSDOC_HEADERS = $(libgnustep-db2_HEADER_FILES)
gdl2_AUTOGSDOC_SOURCE = $(libgnustep-db2_OBJC_FILES) gdl2_AUTOGSDOC_SOURCE = $(libgnustep-db2_OBJC_FILES)

View file

@ -30,7 +30,7 @@
#ifndef __Postgres95Adaptor_h__ #ifndef __Postgres95Adaptor_h__
#define __Postgres95Adaptor_h__ #define __Postgres95Adaptor_h__
#import <EOAccess/EOAdaptor.h> #include <EOAccess/EOAdaptor.h>
/* Include Postgres 95 Headers */ /* Include Postgres 95 Headers */

View file

@ -41,30 +41,34 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSArray.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSDictionary.h> #include <Foundation/NSArray.h>
#import <Foundation/NSSet.h> #include <Foundation/NSDictionary.h>
#import <Foundation/NSValue.h> #include <Foundation/NSSet.h>
#import <Foundation/NSString.h> #include <Foundation/NSValue.h>
#import <Foundation/NSUtilities.h> #include <Foundation/NSString.h>
#import <Foundation/NSDate.h> #include <Foundation/NSUtilities.h>
#import <Foundation/NSAutoreleasePool.h> #include <Foundation/NSDate.h>
#import <Foundation/NSException.h> #include <Foundation/NSAutoreleasePool.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOAccess.h> #include <EOControl/EODebug.h>
#import <EOAccess/EOAttribute.h>
#import <EOAccess/EOExpressionArray.h>
#import <EOAccess/EOEntity.h>
#import <EOAccess/EOModel.h>
#import <EOControl/EODebug.h> #include <EOAccess/EOAccess.h>
#include <EOAccess/EOAttribute.h>
#include <EOAccess/EOExpressionArray.h>
#include <EOAccess/EOEntity.h>
#include <EOAccess/EOModel.h>
#import <Postgres95EOAdaptor/Postgres95Adaptor.h> #include <Postgres95EOAdaptor/Postgres95Adaptor.h>
#import <Postgres95EOAdaptor/Postgres95Context.h> #include <Postgres95EOAdaptor/Postgres95Context.h>
#import <Postgres95EOAdaptor/Postgres95Channel.h> #include <Postgres95EOAdaptor/Postgres95Channel.h>
#import <Postgres95EOAdaptor/Postgres95SQLExpression.h> #include <Postgres95EOAdaptor/Postgres95SQLExpression.h>
#import <Postgres95EOAdaptor/Postgres95Values.h> #include <Postgres95EOAdaptor/Postgres95Values.h>
NSString *Postgres95Exception = @"Postgres95Exception"; NSString *Postgres95Exception = @"Postgres95Exception";

View file

@ -30,10 +30,11 @@
#ifndef __Postgres95Channel_h__ #ifndef __Postgres95Channel_h__
#define __Postgres95Channel_h__ #define __Postgres95Channel_h__
#import <EOAccess/EOAdaptorChannel.h> #include <EOAccess/EOAdaptorChannel.h>
#import <Postgres95EOAdaptor/Postgres95Context.h> #include <Postgres95EOAdaptor/Postgres95Context.h>
@class NSString;
@class NSMutableDictionary; @class NSMutableDictionary;
@class NSMutableArray; @class NSMutableArray;
@class EOAttribute; @class EOAttribute;

View file

@ -41,24 +41,32 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSArray.h>
#import <Foundation/NSDictionary.h>
#import <Foundation/NSString.h>
#import <Foundation/NSObjCRuntime.h>
#import <Foundation/NSUtilities.h>
#import <Foundation/NSException.h>
#import <Foundation/NSDebug.h>
#import <EOAccess/EOAccess.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSArray.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSString.h>
#include <Foundation/NSObjCRuntime.h>
#include <Foundation/NSUtilities.h>
#include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EONull.h> #include <EOControl/EONull.h>
#import <EOControl/EOQualifier.h> #include <EOControl/EOQualifier.h>
#import <EOControl/EOFetchSpecification.h> #include <EOControl/EOFetchSpecification.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
#import <Postgres95EOAdaptor/Postgres95Channel.h> #include <EOAccess/EOAttribute.h>
#import <Postgres95EOAdaptor/Postgres95Context.h> #include <EOAccess/EOEntity.h>
#import <Postgres95EOAdaptor/Postgres95Values.h> #include <EOAccess/EOModel.h>
#include <EOAccess/EOSQLExpression.h>
#include <Postgres95EOAdaptor/Postgres95Channel.h>
#include <Postgres95EOAdaptor/Postgres95Context.h>
#include <Postgres95EOAdaptor/Postgres95Values.h>
static void __dummy_function_used_for_linking(void) static void __dummy_function_used_for_linking(void)

View file

@ -30,8 +30,8 @@
#ifndef __Postgres95Context_h__ #ifndef __Postgres95Context_h__
#define __Postgres95Context_h__ #define __Postgres95Context_h__
#import <EOAccess/EOAdaptorContext.h> #include <EOAccess/EOAdaptorContext.h>
#import <Postgres95EOAdaptor/Postgres95Adaptor.h> #include <Postgres95EOAdaptor/Postgres95Adaptor.h>
@interface Postgres95Context : EOAdaptorContext @interface Postgres95Context : EOAdaptorContext

View file

@ -41,20 +41,22 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSString.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSArray.h> #include <Foundation/NSString.h>
#import <Foundation/NSValue.h> #include <Foundation/NSArray.h>
#import <Foundation/NSException.h> #include <Foundation/NSValue.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOAccess.h> #include <EOControl/EODebug.h>
#import <EOControl/EODebug.h> #include <Postgres95EOAdaptor/Postgres95Adaptor.h>
#include <Postgres95EOAdaptor/Postgres95Context.h>
#import <Postgres95EOAdaptor/Postgres95Adaptor.h> #include <Postgres95EOAdaptor/Postgres95Channel.h>
#import <Postgres95EOAdaptor/Postgres95Context.h> #include <Postgres95EOAdaptor/Postgres95SQLExpression.h>
#import <Postgres95EOAdaptor/Postgres95Channel.h>
#import <Postgres95EOAdaptor/Postgres95SQLExpression.h>
@implementation Postgres95Context @implementation Postgres95Context

View file

@ -27,7 +27,7 @@
#ifndef __Postgres95SQLExpression_h__ #ifndef __Postgres95SQLExpression_h__
#define __Postgres95SQLExpression_h__ #define __Postgres95SQLExpression_h__
#import <EOAccess/EOSQLExpression.h> #include <EOAccess/EOSQLExpression.h>
@class NSString; @class NSString;

View file

@ -36,18 +36,22 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/Foundation.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSUtilities.h> #include <Foundation/NSUtilities.h>
#import <Foundation/NSException.h> #include <Foundation/NSException.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOAccess/EOAttribute.h> #include <EOControl/EONull.h>
#import <EOAccess/EOEntity.h> #include <EOControl/EODebug.h>
#import <EOAccess/EOSchemaGeneration.h>
#import <EOControl/EODebug.h> #include <EOAccess/EOAttribute.h>
#include <EOAccess/EOEntity.h>
#include <EOAccess/EOSchemaGeneration.h>
#import <Postgres95EOAdaptor/Postgres95SQLExpression.h> #include <Postgres95EOAdaptor/Postgres95SQLExpression.h>
#import <Postgres95EOAdaptor/Postgres95Values.h> #include <Postgres95EOAdaptor/Postgres95Values.h>
@implementation Postgres95SQLExpression @implementation Postgres95SQLExpression

View file

@ -27,14 +27,15 @@
#ifndef __Postgres95Values_h__ #ifndef __Postgres95Values_h__
#define __Postgres95Values_h__ #define __Postgres95Values_h__
#import <Foundation/NSString.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSValue.h> #include <Foundation/NSString.h>
#import <Foundation/NSData.h> #include <Foundation/NSValue.h>
#import <Foundation/NSDate.h> #include <Foundation/NSData.h>
#import <Foundation/NSCalendarDate.h> #include <Foundation/NSDate.h>
#include <Foundation/NSCalendarDate.h>
#import <EOControl/EONull.h> #else
#include <Foundation/Foundation.h>
#endif
@class EOAttribute; @class EOAttribute;
@class Postgres95Channel; @class Postgres95Channel;

View file

@ -35,20 +35,25 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSData.h>
#import <Foundation/NSDate.h>
#import <Foundation/NSString.h>
#import <Foundation/NSValue.h>
#import <Foundation/NSDecimalNumber.h>
#import <Foundation/NSException.h>
#import <Foundation/NSDebug.h>
#import <EOAccess/EOAccess.h> #ifndef NeXT_Foundation_LIBRARY
#import <EOAccess/EOAttribute.h> #include <Foundation/NSData.h>
#include <Foundation/NSDate.h>
#include <Foundation/NSString.h>
#include <Foundation/NSValue.h>
#include <Foundation/NSDecimalNumber.h>
#include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <Postgres95EOAdaptor/Postgres95Adaptor.h>
#import <Postgres95EOAdaptor/Postgres95Channel.h> #include <EOAccess/EOAttribute.h>
#import <Postgres95EOAdaptor/Postgres95Values.h>
#include <Postgres95EOAdaptor/Postgres95Adaptor.h>
#include <Postgres95EOAdaptor/Postgres95Channel.h>
#include <Postgres95EOAdaptor/Postgres95Values.h>
void __postgres95_values_linking_function (void) void __postgres95_values_linking_function (void)

View file

@ -38,13 +38,17 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSDictionary.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSSet.h> #include <Foundation/NSDictionary.h>
#import <Foundation/NSUtilities.h> #include <Foundation/NSSet.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSUtilities.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOQualifier.h> #include <EOControl/EOQualifier.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
@implementation EOAndQualifier @implementation EOAndQualifier

View file

@ -0,0 +1,52 @@
/**
EOArrayDataSource.h
Copyright (C) 2003 Free Software Foundation, Inc.
Author: Stephane Corthesy <stephane@sente.ch>
Date: March 2003
This file is part of the GNUstep Database Library.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; see the file COPYING.LIB.
If not, write to the Free Software Foundation,
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#ifndef __EOArrayDataSource_h__
#define __EOArrayDataSource_h__
#include <EOControl/EODataSource.h>
@class NSMutableArray;
@class NSArray;
@class EOEditingContext;
@class EOClassDescription;
@interface EOArrayDataSource : EODataSource <NSCoding>
{
NSMutableArray *_objects;
EOEditingContext *_context;
EOClassDescription *_classDescription;
}
- (id) initWithClassDescription: (EOClassDescription *)classDescription
editingContext: (EOEditingContext *)context;
- (void) setArray: (NSArray *)array;
@end
#endif

View file

@ -0,0 +1,146 @@
/**
EOArrayDataSource.m
Copyright (C) 2003 Free Software Foundation, Inc.
Author: Stephane Corthesy <stephane@sente.ch>
Date: March 2003
This file is part of the GNUstep Database Library.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; see the file COPYING.LIB.
If not, write to the Free Software Foundation,
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSString.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSCoder.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <EOControl/EOArrayDataSource.h>
#include <EOControl/EOClassDescription.h>
#include <EOControl/EOEditingContext.h>
#include <EOControl/EODetailDataSource.h>
@implementation EOArrayDataSource
- (id) initWithClassDescription: (EOClassDescription *)classDescription
editingContext: (EOEditingContext *)context
{
// Either argument may be nil
if ((self = [self init]))
{
_classDescription = RETAIN(classDescription);
_context = RETAIN(context);
_objects = [[NSMutableArray allocWithZone: [self zone]] init];
}
return self;
}
- (void) dealloc
{
DESTROY(_objects);
DESTROY(_context);
DESTROY(_classDescription);
[super dealloc];
}
- (void) encodeWithCoder: (NSCoder *)encoder
{
/*
[encoder encodeObject: _objects];
[encoder encodeObject: _context];
[encoder encodeObject: _classDescription];
*/
}
- (id) initWithCoder:(NSCoder *)decoder
{
/*
_objects = RETAIN([decoder decodeObject]);
_context = RETAIN([decoder decodeObject]);
_classDescription = RETAIN([decoder decodeObject]);
*/
return self;
}
- (void) insertObject:(id)object
{
[_objects addObject: object];
}
- (void) deleteObject:(id)object
{
[[self editingContext] deleteObject: object];
[_objects removeObject: object];
}
- (NSArray *) fetchObjects
{
return [NSArray arrayWithArray: _objects];
}
- (EOEditingContext *) editingContext
{
return _context;
}
- (void) qualifyWithRelationshipKey: (NSString *)key ofObject: (id)sourceObject
{
// Do nothing
}
- (EODataSource *) dataSourceQualifiedByKey: (NSString *)key
{
return [EODetailDataSource detailDataSourceWithMasterDataSource: self
detailKey: key];
}
- (EOClassDescription *) classDescriptionForObjects
{
return _classDescription;
}
- (NSArray *) qualifierBindingKeys
{
// Don't know what to do
return nil;
}
- (void) setQualifierBindings: (NSDictionary *)bindings
{
// Don't know what to do
}
- (NSDictionary *) qualifierBindings
{
// Don't know what to do
return nil;
}
- (void) setArray:(NSArray *)array
{
[_objects setArray: array];
}
@end

View file

@ -27,8 +27,13 @@
#ifndef __EOCheapArray_h__ #ifndef __EOCheapArray_h__
#define __EOCheapArray_h__ #define __EOCheapArray_h__
#import <Foundation/NSArray.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSZone.h> #include <Foundation/NSArray.h>
#include <Foundation/NSZone.h>
#else
#include <Foundation/Foundation.h>
#endif
@interface EOCheapCopyArray : NSArray @interface EOCheapCopyArray : NSArray

View file

@ -35,10 +35,18 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/Foundation.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSArray.h>
#include <Foundation/NSString.h>
#include <Foundation/NSZone.h>
#include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOCheapArray.h> #include <EOControl/EOCheapArray.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
@implementation EOCheapCopyArray : NSArray @implementation EOCheapCopyArray : NSArray

View file

@ -27,10 +27,13 @@
#ifndef __EOClassDescription_h__ #ifndef __EOClassDescription_h__
#define __EOClassDescription_h__ #define __EOClassDescription_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSArray.h> #include <Foundation/NSArray.h>
#import <Foundation/NSException.h> #include <Foundation/NSException.h>
#import <Foundation/NSZone.h> #include <Foundation/NSZone.h>
#else
#include <Foundation/Foundation.h>
#endif
@class NSDictionary; @class NSDictionary;

View file

@ -38,23 +38,37 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/Foundation.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSString.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSEnumerator.h>
#include <Foundation/NSNotification.h>
#include <Foundation/NSFormatter.h>
#include <Foundation/NSException.h>
#include <Foundation/NSMapTable.h>
#include <Foundation/NSZone.h>
#include <Foundation/NSObjCRuntime.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOClassDescription.h> #include <EOControl/EOClassDescription.h>
#import <EOControl/EOKeyValueCoding.h> #include <EOControl/EOKeyValueCoding.h>
#import <EOControl/EONull.h> #include <EOControl/EONull.h>
#import <EOControl/EOEditingContext.h> #include <EOControl/EOEditingContext.h>
#import <EOControl/EOCheapArray.h> #include <EOControl/EOCheapArray.h>
#import <EOControl/EODebug.h> #include <EOControl/EONSAddOns.h>
#include <EOControl/EODebug.h>
#include <gnustep/base/objc-gnu2next.h>
//?? #define NOT_FOUND_CLASS_DESCRIPTION ([NSObject class]) //we use NSObject class as a "not found" value*******
// NOTE: (stephane@sente.ch) Should we subclass NSClassDescription? // NOTE: (stephane@sente.ch) Should we subclass NSClassDescription?
@implementation EOClassDescription @interface NSObject (SupressCompilerWarnings)
+(id)defaultGroup;
@end
@implementation EOClassDescription
NSString *EOClassDescriptionNeededNotification = @"EOClassDescriptionNeededNotification"; NSString *EOClassDescriptionNeededNotification = @"EOClassDescriptionNeededNotification";
NSString *EOClassDescriptionNeededForClassNotification = @"EOClassDescriptionNeededForClassNotification"; NSString *EOClassDescriptionNeededForClassNotification = @"EOClassDescriptionNeededForClassNotification";
@ -75,20 +89,20 @@ static id classDelegate = nil;
+ (void)initialize + (void)initialize
{ {
classDescriptionForClass = NSCreateMapTable(NSObjectMapKeyCallBacks,
NSObjectMapValueCallBacks,
32);
classDescriptionForEntity = NSCreateMapTable(NSObjectMapKeyCallBacks,
NSObjectMapValueCallBacks,
32);
if (self == [EOClassDescription class]) if (self == [EOClassDescription class])
{ {
Class cls = NSClassFromString(@"EOModelGroup"); Class cls = NSClassFromString(@"EOModelGroup");
if (cls != Nil) if (cls != Nil)
[cls defaultGroup]; // Insure correct initialization. [cls defaultGroup]; // Insure correct initialization.
classDescriptionForClass = NSCreateMapTable(NSObjectMapKeyCallBacks,
NSObjectMapValueCallBacks,
32);
classDescriptionForEntity = NSCreateMapTable(NSObjectMapKeyCallBacks,
NSObjectMapValueCallBacks,
32);
} }
} }
@ -110,14 +124,11 @@ static id classDelegate = nil;
NSDebugMLLog(@"gsdb", @"aClass=%@", aClass); NSDebugMLLog(@"gsdb", @"aClass=%@", aClass);
NSAssert(aClass, @"No class"); NSAssert(aClass, @"No class");
NSDebugMLLog(@"gsdb", @"class name=%s", object_get_class_name(aClass)); NSDebugMLLog(@"gsdb", @"class name=%s", GSObjCName(aClass));
classDescription = NSMapGet(classDescriptionForClass, aClass); classDescription = NSMapGet(classDescriptionForClass, aClass);
NSDebugMLLog(@"gsdb", @"classDescription=%@", classDescription); NSDebugMLLog(@"gsdb", @"classDescription=%@", classDescription);
/* ?? if (classDescription==NOT_FOUND_CLASS_DESCRIPTION)
classDescription=nil;
else*/
if (!classDescription) if (!classDescription)
{ {
[[NSNotificationCenter defaultCenter] [[NSNotificationCenter defaultCenter]
@ -129,7 +140,8 @@ static id classDelegate = nil;
if (!classDescription) if (!classDescription)
{ {
NSLog(@"Warning: No class description for class named: %s", object_get_class_name(aClass)); NSLog(@"Warning: No class description for class named: %s",
GSObjCName(aClass));
} }
} }
@ -149,9 +161,6 @@ static id classDelegate = nil;
classDescription = NSMapGet(classDescriptionForEntity, entityName); classDescription = NSMapGet(classDescriptionForEntity, entityName);
NSDebugMLLog(@"gsdb", @"classDescription=%@", classDescription); NSDebugMLLog(@"gsdb", @"classDescription=%@", classDescription);
/*?? if (classDescription==NOT_FOUND_CLASS_DESCRIPTION)
classDescription=nil;
else*/
if (!classDescription) if (!classDescription)
{ {
[[NSNotificationCenter defaultCenter] [[NSNotificationCenter defaultCenter]

View file

@ -28,26 +28,24 @@
#define __EOControl_h__ #define __EOControl_h__
#import <EOControl/EOSortOrdering.h> #include <EOControl/EOSortOrdering.h>
#import <EOControl/EOFetchSpecification.h> #include <EOControl/EOFetchSpecification.h>
#import <EOControl/EOGenericRecord.h> #include <EOControl/EOGenericRecord.h>
#import <EOControl/EOClassDescription.h> #include <EOControl/EOClassDescription.h>
#import <EOControl/EOKeyValueCoding.h> #include <EOControl/EOKeyValueCoding.h>
#import <EOControl/EOQualifier.h> #include <EOControl/EOQualifier.h>
#import <EOControl/EONull.h> #include <EOControl/EONull.h>
#import <EOControl/EOKeyValueArchiver.h> #include <EOControl/EOKeyValueArchiver.h>
#import <EOControl/EOGlobalID.h> #include <EOControl/EOGlobalID.h>
#import <EOControl/EOKeyGlobalID.h> #include <EOControl/EOKeyGlobalID.h>
#import <EOControl/EOUndoManager.h> #include <EOControl/EOObjectStore.h>
#import <EOControl/EOObjectStore.h> #include <EOControl/EOObjectStoreCoordinator.h>
#import <EOControl/EOObjectStoreCoordinator.h> #include <EOControl/EOFault.h>
#import <EOControl/EOFault.h> #include <EOControl/EOEditingContext.h>
#import <EOControl/EOEditingContext.h> #include <EOControl/EODataSource.h>
#import <EOControl/EODataSource.h> #include <EOControl/EODetailDataSource.h>
#import <EOControl/EODetailDataSource.h> #include <EOControl/EOObserver.h>
#import <EOControl/EOObserver.h> #include <EOControl/EODebug.h>
#import <EOControl/EODebug.h>
#import <gnustep/base/GCObject.h>
#endif /* __EOControl_h__ */ #endif /* __EOControl_h__ */

View file

@ -27,7 +27,11 @@
#ifndef __EODataSource_h__ #ifndef __EODataSource_h__
#define __EODataSource_h__ #define __EODataSource_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSObject.h>
#else
#include <Foundation/Foundation.h>
#endif
@class NSArray; @class NSArray;
@class NSDictionary; @class NSDictionary;

View file

@ -35,10 +35,10 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <EOControl/EODataSource.h> #include <EOControl/EODataSource.h>
#import <EOControl/EOClassDescription.h> #include <EOControl/EOClassDescription.h>
#import <EOControl/EOEditingContext.h> #include <EOControl/EOEditingContext.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
#include <string.h> #include <string.h>

View file

@ -1,8 +1,8 @@
/* debug.h - debug /* debug.h - debug
Copyright (C) 1999 Free Software Foundation, Inc. Copyright (C) 1999, 2002, 2003 Free Software Foundation, Inc.
Written by: Manuel Guesdon <mguesdon@sbuilders.com> Written by: Manuel Guesdon <mguesdon@sbuilders.com>
Date: Jan 1999 Date: Jan 1999
This file is part of the GNUstep Web Library. This file is part of the GNUstep Web Library.
@ -30,19 +30,27 @@
#ifdef DEBUG #ifdef DEBUG
#import <Foundation/NSDebug.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSAutoreleasePool.h> #include <Foundation/NSDebug.h>
#include <Foundation/NSAutoreleasePool.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <EOControl/EODefines.h>
extern void EOFLogC_(const char* file,int line,const char* string); GDL2CONTROL_EXPORT void EOFLogC_(const char* file,int line,const char* string);
extern void EOFLogDumpObject_(const char* file,int line,id object,int deep); GDL2CONTROL_EXPORT void EOFLogDumpObject_(const char* file,int line,
extern void EOFLogAssertGood_(const char* file,int line,NSObject* object); id object,int deep);
GDL2CONTROL_EXPORT void EOFLogAssertGood_(const char* file,int line,
NSObject* object);
#define EOFLogC(cString); EOFLogC_(__FILE__,__LINE__,cString); #define EOFLogC(cString); EOFLogC_(__FILE__,__LINE__,cString);
#define EOFLogDumpObject(object,deep); EOFLogDumpObject_(__FILE__,__LINE__,object,deep); #define EOFLogDumpObject(object,deep); EOFLogDumpObject_(__FILE__,__LINE__,object,deep);
#define EOFLogAssertGood(object); EOFLogAssertGood_(__FILE__,__LINE__,object); #define EOFLogAssertGood(object); EOFLogAssertGood_(__FILE__,__LINE__,object);
#else // no DEBUG #else // no DEBUG
#define EOFLogC(cString); #define EOFLogC(cString);
#define EOFLogDumpObject(object,deep); #define EOFLogDumpObject(object,deep);
#define EOFLogAssertGood(object); #define EOFLogAssertGood(object);
#endif // DEBUG #endif // DEBUG
@ -261,7 +269,7 @@ extern void EOFLogAssertGood_(const char* file,int line,NSObject* object);
#endif #endif
#ifndef NSEmitTODO #ifndef NSEmitTODO
#define NSEmitTODO(); NSLog(@"DVLP WARNING %s (%d): TODO",(char*)__FILE__,(int)__LINE__); #define NSEmitTODO(); NSLog(@"DVLP WARNING %s (%d): TODO",(char*)__FILE__,(int)__LINE__);
#endif #endif
#endif // _EODebug_h__ #endif // _EODebug_h__

View file

@ -33,12 +33,19 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSThread.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSAutoreleasePool.h> #include <Foundation/NSThread.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSAutoreleasePool.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <unistd.h> #include <unistd.h>
#include <EOControl/EODebug.h>
#define USTART NSAutoreleasePool* arp=[NSAutoreleasePool new]; #define USTART NSAutoreleasePool* arp=[NSAutoreleasePool new];
#define USTOP DESTROY(arp); #define USTOP DESTROY(arp);

49
EOControl/EODefines.h Normal file
View file

@ -0,0 +1,49 @@
/*
EODefines.h
Copyright (C) 2003 Free Software Foundation, Inc.
Author: Stephane Corthesy <stephane@sente.ch>
Date: March 2003
This file is part of the GNUstep Database Library.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; see the file COPYING.LIB.
If not, write to the Free Software Foundation,
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#ifndef __EOControl_EODefines_h__
#define __EOControl_EODefines_h__
#ifdef GNUSTEP_WITH_DLL
#if BUILD_libgnustep_db2control_DLL
# define GDL2CONTROL_EXPORT __declspec(dllexport)
# define GDL2CONTROL_DECLARE __declspec(dllexport)
#else
# define GDL2CONTROL_EXPORT extern __declspec(dllimport)
# define GDL2CONTROL_DECLARE __declspec(dllimport)
#endif
#else /* GNUSTEP_WITH[OUT]_DLL */
# define GDL2CONTROL_EXPORT extern
# define GDL2CONTROL_DECLARE
#endif
#endif /* __EOControl_EODefines_h__ */

72
EOControl/EODepricated.h Normal file
View file

@ -0,0 +1,72 @@
/**
EODeprecated.h
Copyright (C) 2003 Free Software Foundation, Inc.
Author: Stephane Corthesy <stephane@sente.ch>
Date: March 2003
This file is part of the GNUstep Database Library.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; see the file COPYING.LIB.
If not, write to the Free Software Foundation,
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#ifndef __EOControl_EODeprecated_h__
#define __EOControl_EODeprecated_h__
#ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSUndoManager.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <EOControl/EODefines.h>
#include <EOControl/EOClassDescription.h>
#include <EOControl/EOFetchSpecification.h>
@interface NSObject (EODeprecated)
/** Depricated. GDL2 doesn't cache key bindungs.*/
+ (void) flushClassKeyBindings;
@end
@interface EOClassDescription (EODeprecated)
/** Depricated. Use +setClassDelegate. */
+ (void) setDelegate:(id)delegate;
/** Depricated. Use +classDelegate. */
+ (id) delegate;
@end
/** Depricated. Use NSUndoManager. */
@interface EOUndoManager : NSUndoManager
/** Depricated. Use -removeAllActionsWithTarget:. */
- (void) forgetAllWithTarget: (id)param0;
/** Depricated. Use -removeAllActionsWithTarget:. */
- (void) forgetAll;
/** Depricated. Use -registerUndoWithTarget:selector:object:. */
- (void) registerUndoWithTarget: (id)param0
selector: (SEL)param1
arg: (id)param2;
/** Depricated. Use -enableUndoRegistration. */
- (void) reenableUndoRegistration;
@end
#endif

View file

@ -27,7 +27,7 @@
#ifndef __EODetailDataSource_h__ #ifndef __EODetailDataSource_h__
#define __EODetailDataSource_h__ #define __EODetailDataSource_h__
#import <EOControl/EODataSource.h> #include <EOControl/EODataSource.h>
@class EOKeyValueUnarchiver; @class EOKeyValueUnarchiver;

View file

@ -35,17 +35,21 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSString.h> #include <Foundation/NSObject.h>
#import <Foundation/NSException.h> #include <Foundation/NSString.h>
#import <Foundation/NSCoder.h> #include <Foundation/NSException.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSCoder.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EODetailDataSource.h> #include <EOControl/EODetailDataSource.h>
#import <EOControl/EOKeyValueCoding.h> #include <EOControl/EOKeyValueCoding.h>
#import <EOControl/EOKeyValueArchiver.h> #include <EOControl/EOKeyValueArchiver.h>
#import <EOControl/EOClassDescription.h> #include <EOControl/EOClassDescription.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
@implementation EODetailDataSource @implementation EODetailDataSource

View file

@ -26,12 +26,16 @@
#ifndef __EOEditingContext_h__ #ifndef __EOEditingContext_h__
#define __EOEditingContext_h__ #define __EOEditingContext_h__
#import <Foundation/NSHashTable.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSMapTable.h> #include <Foundation/NSHashTable.h>
#import <Foundation/NSLock.h> #include <Foundation/NSMapTable.h>
#include <Foundation/NSLock.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOObjectStore.h> #include <EOControl/EOObjectStore.h>
#import <EOControl/EOObserver.h> #include <EOControl/EOObserver.h>
@class NSArray; @class NSArray;

View file

@ -35,18 +35,17 @@
RCS_ID("$Id$") RCS_ID("$Id$")
//TODO EOMultiReaderLocks //TODO EOMultiReaderLocks
#import <Foundation/Foundation.h> #include <Foundation/Foundation.h>
#import <EOControl/EOEditingContext.h> #include <EOControl/EOEditingContext.h>
#import <EOControl/EOObjectStoreCoordinator.h> #include <EOControl/EOObjectStoreCoordinator.h>
#import <EOControl/EOGlobalID.h> #include <EOControl/EOGlobalID.h>
#import <EOControl/EOClassDescription.h> #include <EOControl/EOClassDescription.h>
#import <EOControl/EOKeyValueCoding.h> #include <EOControl/EOKeyValueCoding.h>
#import <EOControl/EOFault.h> #include <EOControl/EOFault.h>
#import <EOControl/EONull.h> #include <EOControl/EONull.h>
#import <EOControl/EOUndoManager.h> #include <EOControl/EONSAddOns.h>
#import <EOControl/EONSAddOns.h> #include <EOControl/EODebug.h>
#import <EOControl/EODebug.h>
@class EOEntityClassDescription; @class EOEntityClassDescription;
@ -64,8 +63,10 @@ NSString *EOEditingContextDidSaveChangesNotification = @"EOEditingContextDidSave
+ (void)initialize + (void)initialize
{ {
if (self == [EOEditingContext class] && !defaultParentStore) if (self == [EOEditingContext class] && defaultParentStore == nil)
defaultParentStore = [EOObjectStoreCoordinator defaultCoordinator]; {
defaultParentStore = [EOObjectStoreCoordinator defaultCoordinator];
}
} }
+ (void)setInstancesRetainRegisteredObjects: (BOOL)flag + (void)setInstancesRetainRegisteredObjects: (BOOL)flag
@ -113,7 +114,7 @@ NSString *EOEditingContextDidSaveChangesNotification = @"EOEditingContextDidSave
_lock = [NSRecursiveLock new]; _lock = [NSRecursiveLock new];
//TODO-NOW _undoManager = [EOUndoManager new]; //TODO-NOW _undoManager = [NSUndoManager new];
[_undoManager beginUndoGrouping]; //?? [_undoManager beginUndoGrouping]; //??
[self _observeUndoManagerNotifications]; [self _observeUndoManagerNotifications];
@ -1748,12 +1749,12 @@ validateTable:(NSHashTable*)table
&& !NSHashGet(_deletedObjects, object)) && !NSHashGet(_deletedObjects, object))
{ {
NSMethodSignature *undoMethodSignature = nil; NSMethodSignature *undoMethodSignature = nil;
EOUndoManager *undoManager; NSUndoManager *undoManager;
//EOGlobalID *gid = [self globalIDForObject: object]; //EOGlobalID *gid = [self globalIDForObject: object];
[self _registerClearStateWithUndoManager]; [self _registerClearStateWithUndoManager];
undoManager = (EOUndoManager*)[self undoManager]; undoManager = (NSUndoManager*)[self undoManager];
[undoManager prepareWithInvocationTarget: self]; [undoManager prepareWithInvocationTarget: self];
undoMethodSignature = [undoManager methodSignatureForSelector: undoMethodSignature = [undoManager methodSignatureForSelector:

View file

@ -30,10 +30,14 @@
#ifndef __EOFault_h__ #ifndef __EOFault_h__
#define __EOFault_h__ #define __EOFault_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSZone.h> #include <Foundation/NSObject.h>
#include <Foundation/NSZone.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <gnustep/base/GCObject.h> #include <gnustep/base/GCObject.h>
@class NSInvocation; @class NSInvocation;

View file

@ -38,36 +38,28 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#include <objc/Object.h> #ifndef NeXT_Foundation_LIBRARY
#include <objc/Protocol.h> #include <Foundation/NSObject.h>
#include <Foundation/NSUtilities.h>
#include <Foundation/NSAutoreleasePool.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSString.h>
#include <Foundation/NSObjCRuntime.h>
#include <Foundation/NSInvocation.h>
#include <Foundation/NSLock.h>
#include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <Foundation/NSObject.h> #include <gnustep/base/GSObjCRuntime.h>
#import <Foundation/NSUtilities.h>
#import <Foundation/NSAutoreleasePool.h>
#import <Foundation/NSArray.h>
#import <Foundation/NSDictionary.h>
#import <Foundation/NSString.h>
#import <Foundation/NSObjCRuntime.h>
#import <Foundation/NSInvocation.h>
#import <Foundation/NSLock.h>
#import <Foundation/NSException.h>
#import <Foundation/NSDebug.h>
#include <objc/objc-api.h>
#import <EOControl/EOFault.h>
#import <EOControl/EOKeyGlobalID.h>
#import <EOControl/EOEditingContext.h>
#import <EOControl/EODebug.h>
typedef struct {
Class isa;
} *my_objc_object;
#define object_is_instance(object) \
((object != nil) && CLS_ISCLASS(((my_objc_object)object)->isa))
#include <EOControl/EOFault.h>
#include <EOControl/EOKeyGlobalID.h>
#include <EOControl/EOEditingContext.h>
#include <EOControl/EODebug.h>
/* /*
* EOFault class * EOFault class
@ -75,15 +67,21 @@ typedef struct {
@implementation EOFault @implementation EOFault
static Class EOFaultClass = NULL;
+ (void)initialize + (void)initialize
{ {
// Must be here as initialize is called for each root class // Must be here as initialize is called for each root class
// without asking if it responds to it ! // without asking if it responds to it !
if (EOFaultClass == NULL)
{
EOFaultClass = [EOFaultClass class];
}
} }
+ (Class)superclass + (Class)superclass
{ {
return class_get_super_class(self); return GSObjCSuper(self);
} }
+ (Class)class + (Class)class
@ -118,7 +116,7 @@ typedef struct {
+ (BOOL)isKindOfClass: (Class)aClass + (BOOL)isKindOfClass: (Class)aClass
{ {
if (aClass == [EOFault class]) if (aClass == EOFaultClass)
return YES; return YES;
return NO; return NO;
@ -184,7 +182,7 @@ typedef struct {
NSDebugFLLog(@"gsdb", @"START fault=%p", fault); NSDebugFLLog(@"gsdb", @"START fault=%p", fault);
if ([EOFault isFault:fault] == NO) if ([EOFaultClass isFault:fault] == NO)
{ {
//REVOIR!!! //REVOIR!!!
/* /*
@ -237,9 +235,10 @@ typedef struct {
+ (EOFaultHandler *)handlerForFault:(id)fault + (EOFaultHandler *)handlerForFault:(id)fault
{ {
BOOL isFault = [EOFault isFault: fault]; BOOL isFault = [EOFaultClass isFault: fault];
NSDebugFLLog(@"gsdb", @"object %p is%s a fault", fault, (isFault ? "" : " not")); NSDebugFLLog(@"gsdb", @"object %p is%s a fault", fault,
(isFault ? "" : " not"));
if (isFault) if (isFault)
return ((EOFault *)fault)->_handler; return ((EOFault *)fault)->_handler;
@ -249,7 +248,7 @@ typedef struct {
+ (Class)targetClassForFault: (id)fault + (Class)targetClassForFault: (id)fault
{ {
if ([EOFault isFault:fault]) if ([EOFaultClass isFault:fault])
return [((EOFault *)fault)->_handler targetClass]; return [((EOFault *)fault)->_handler targetClass];
else else
return nil; return nil;
@ -275,7 +274,7 @@ typedef struct {
class = [_handler targetClass]; class = [_handler targetClass];
for (; !koc && class != Nil; class = class_get_super_class(class)) for (; !koc && class != Nil; class = GSObjCSuper(class))
if (class == aclass) if (class == aclass)
koc = YES; koc = YES;
@ -318,10 +317,10 @@ typedef struct {
NSDebugFLLog(@"gsdb", @"START self=%p", self); NSDebugFLLog(@"gsdb", @"START self=%p", self);
class = [_handler targetClass]; class = [_handler targetClass];
NSDebugFLLog(@"gsdb", @"class=%@ aSelector=%s", class, sel_get_name(aSelector)); NSDebugFLLog(@"gsdb", @"class=%@ aSelector=%@", class,
NSStringFromSelector(aSelector));
respondsToSelector = ((IMP)class_get_instance_method(class, aSelector) respondsToSelector = (GSObjCGetInstanceMethod(class, aSelector) != (IMP)0);
!= (IMP)0);
NSDebugFLLog(@"gsdb", @"STOP self=%p", self); NSDebugFLLog(@"gsdb", @"STOP self=%p", self);
return respondsToSelector; return respondsToSelector;
@ -428,9 +427,9 @@ typedef struct {
NSDebugFLog(@"Dealloc EOFault %p. ThreadID=%p", NSDebugFLog(@"Dealloc EOFault %p. ThreadID=%p",
(void*)self,(void*)objc_thread_id()); (void*)self,(void*)objc_thread_id());
#endif #endif
[EOFault clearFault: self]; [EOFaultClass clearFault: self];
NSDebugMLog(@"EOFault dealloc self=%p",self); NSDebugMLog(@"EOFault dealloc self=%p",self);
if (![EOFault isFault:self]) // otherwise, this loop. if (![EOFaultClass isFault:self]) // otherwise, this loop.
[self dealloc]; [self dealloc];
#ifdef DEBUG #ifdef DEBUG
NSDebugFLog(@"Stop Dealloc EOFault %p. ThreadID=%p", NSDebugFLog(@"Stop Dealloc EOFault %p. ThreadID=%p",

View file

@ -35,19 +35,23 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSUtilities.h> #include <Foundation/NSObject.h>
#import <Foundation/NSArray.h> #include <Foundation/NSUtilities.h>
#import <Foundation/NSDictionary.h> #include <Foundation/NSArray.h>
#import <Foundation/NSString.h> #include <Foundation/NSDictionary.h>
#import <Foundation/NSObjCRuntime.h> #include <Foundation/NSString.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSObjCRuntime.h>
#import <Foundation/NSException.h> #include <Foundation/NSDebug.h>
#include <Foundation/NSException.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <gnustep/base/GCObject.h> #include <gnustep/base/GCObject.h>
#import <EOControl/EOFault.h> #include <EOControl/EOFault.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
#ifndef GNU_RUNTIME #ifndef GNU_RUNTIME
#include <objc/objc-class.h> #include <objc/objc-class.h>

View file

@ -27,7 +27,11 @@
#ifndef __EOFetchSpecification_h__ #ifndef __EOFetchSpecification_h__
#define __EOFetchSpecification_h__ #define __EOFetchSpecification_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSObject.h>
#else
#include <Foundation/Foundation.h>
#endif
@class NSArray; @class NSArray;

View file

@ -35,17 +35,21 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSCoder.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSDictionary.h> #include <Foundation/NSCoder.h>
#import <Foundation/NSValue.h> #include <Foundation/NSDictionary.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSValue.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOFetchSpecification.h> #include <EOControl/EOFetchSpecification.h>
#import <EOControl/EOKeyValueArchiver.h> #include <EOControl/EOKeyValueArchiver.h>
#import <EOControl/EOObserver.h> #include <EOControl/EOObserver.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
#import <EOControl/EONSAddOns.h> #include <EOControl/EONSAddOns.h>
#import <EOControl/EOQualifier.h> #include <EOControl/EOQualifier.h>
@implementation EOFetchSpecification @implementation EOFetchSpecification

View file

@ -27,7 +27,11 @@
#ifndef __EOGenericRecord_h__ #ifndef __EOGenericRecord_h__
#define __EOGenericRecord_h__ #define __EOGenericRecord_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSObject.h>
#else
#include <Foundation/Foundation.h>
#endif
@class NSString; @class NSString;

View file

@ -38,25 +38,29 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSArray.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSAutoreleasePool.h> #include <Foundation/NSArray.h>
#import <Foundation/NSDictionary.h> #include <Foundation/NSAutoreleasePool.h>
#import <Foundation/NSObjCRuntime.h> #include <Foundation/NSDictionary.h>
#import <Foundation/NSLock.h> #include <Foundation/NSObjCRuntime.h>
#import <Foundation/NSValue.h> #include <Foundation/NSLock.h>
#import <Foundation/NSHashTable.h> #include <Foundation/NSValue.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSHashTable.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <gnustep/base/GSObjCRuntime.h> #include <gnustep/base/GSObjCRuntime.h>
#import <EOControl/EOClassDescription.h> #include <EOControl/EOClassDescription.h>
#import <EOControl/EOGenericRecord.h> #include <EOControl/EOGenericRecord.h>
#import <EOControl/EONull.h> #include <EOControl/EONull.h>
#import <EOControl/EOObserver.h> #include <EOControl/EOObserver.h>
#import <EOControl/EOFault.h> #include <EOControl/EOFault.h>
#import <EOControl/EOMutableKnownKeyDictionary.h> #include <EOControl/EOMutableKnownKeyDictionary.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
#import <EOControl/EOKeyValueCoding.h> #include <EOControl/EOKeyValueCoding.h>
#ifndef GNU_RUNTIME #ifndef GNU_RUNTIME
#include <objc/objc-class.h> #include <objc/objc-class.h>
@ -99,8 +103,6 @@ static NSRecursiveLock *allGenericRecordsLock = nil;
+ (void) initialize + (void) initialize
{ {
[[super superclass] initialize];
if (self == [EOGenericRecord class] && !allGenericRecords) if (self == [EOGenericRecord class] && !allGenericRecords)
{ {
allGenericRecords = NSCreateHashTable(NSNonOwnedPointerHashCallBacks, allGenericRecords = NSCreateHashTable(NSNonOwnedPointerHashCallBacks,
@ -201,7 +203,7 @@ static NSRecursiveLock *allGenericRecordsLock = nil;
//MG #if !FOUNDATION_HAS_KVC //MG #if !FOUNDATION_HAS_KVC
static const char _c_id[2] = { _C_ID, NULL }; static const char _c_id[2] = { _C_ID, 0 };
//used to allow derived object implementation //used to allow derived object implementation
- (BOOL)_infoForInstanceVariableNamed: (NSString*)name - (BOOL)_infoForInstanceVariableNamed: (NSString*)name

View file

@ -27,11 +27,15 @@
#ifndef __EOGlobalID_h__ #ifndef __EOGlobalID_h__
#define __EOGlobalID_h__ #define __EOGlobalID_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSObject.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <EOControl/EODefines.h>
extern NSString *EOGlobalIDChangedNotification; GDL2CONTROL_EXPORT NSString *EOGlobalIDChangedNotification;
@interface EOGlobalID : NSObject <NSCopying> @interface EOGlobalID : NSObject <NSCopying>
- (BOOL)isEqual:other; - (BOOL)isEqual:other;

View file

@ -35,11 +35,15 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSCoder.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSString.h> #include <Foundation/NSCoder.h>
#include <Foundation/NSString.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOGlobalID.h> #include <EOControl/EOGlobalID.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
#include <stdio.h> #include <stdio.h>
#include <string.h> #include <string.h>

View file

@ -35,14 +35,18 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSDictionary.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSSet.h> #include <Foundation/NSDictionary.h>
#import <Foundation/NSUtilities.h> #include <Foundation/NSSet.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSUtilities.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOQualifier.h> #include <EOControl/EOQualifier.h>
#import <EOControl/EOKeyValueCoding.h> #include <EOControl/EOKeyValueCoding.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
@implementation EOKeyComparisonQualifier @implementation EOKeyComparisonQualifier
@ -132,16 +136,16 @@ RCS_ID("$Id$")
* the right value as the parameter.<br/> * the right value as the parameter.<br/>
* If the left object doesn't implement the receivers selector, but the * If the left object doesn't implement the receivers selector, but the
* selector of the reciever is one of:<br/> * selector of the reciever is one of:<br/>
+ <list> * <list>
* EOQualifierOperatorEqual * <item>EOQualifierOperatorEqual</item>
* EOQualifierOperatorNotEqual * <item>EOQualifierOperatorNotEqual</item>
* EOQualifierOperatorLessThan * <item>EOQualifierOperatorLessThan</item>
* EOQualifierOperatorGreaterThan * <item>EOQualifierOperatorGreaterThan</item>
* EOQualifierOperatorLessThanOrEqual * <item>EOQualifierOperatorLessThanOrEqual</item>
* EOQualifierOperatorGreaterThanOrEqual * <item>EOQualifierOperatorGreaterThanOrEqual</item>
* EOQualifierOperatorContains * <item>EOQualifierOperatorContains</item>
* EOQualifierOperatorLike * <item>EOQualifierOperatorLike</item>
* EOQualifierOperatorCaseInsensitiveLike * <item>EOQualifierOperatorCaseInsensitiveLike</item>
* </list> * </list>
* then GDL2 tries to evaluate the qualifier by invoking * then GDL2 tries to evaluate the qualifier by invoking
* isEqual:, compare:, rangeOfString: respectively and interpreting the * isEqual:, compare:, rangeOfString: respectively and interpreting the

View file

@ -27,7 +27,7 @@
#ifndef __EOKeyGlobalID_h__ #ifndef __EOKeyGlobalID_h__
#define __EOKeyGlobalID_h__ #define __EOKeyGlobalID_h__
#import <EOControl/EOGlobalID.h> #include <EOControl/EOGlobalID.h>
@interface EOKeyGlobalID : EOGlobalID <NSCoding> @interface EOKeyGlobalID : EOGlobalID <NSCoding>

View file

@ -35,14 +35,18 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSString.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSCoder.h> #include <Foundation/NSString.h>
#import <Foundation/NSArray.h> #include <Foundation/NSCoder.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSArray.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOKeyGlobalID.h> #include <EOControl/EOKeyGlobalID.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
#import <EOControl/EONull.h> #include <EOControl/EONull.h>
@implementation EOKeyGlobalID @implementation EOKeyGlobalID

View file

@ -28,8 +28,12 @@
#define __EOKeyValueArchiving_h__ #define __EOKeyValueArchiving_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSHashTable.h> #include <Foundation/NSObject.h>
#include <Foundation/NSHashTable.h>
#else
#include <Foundation/Foundation.h>
#endif
@class NSArray; @class NSArray;

View file

@ -35,10 +35,19 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/Foundation.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSString.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOKeyValueArchiver.h>
#import <EOControl/EODebug.h> #include <EOControl/EOKeyValueArchiver.h>
#include <EOControl/EODebug.h>
@interface EOKeyValueArchivingContainer : NSObject @interface EOKeyValueArchivingContainer : NSObject

View file

@ -27,10 +27,16 @@
#ifndef __EOKeyValueCoding_h__ #ifndef __EOKeyValueCoding_h__
#define __EOKeyValueCoding_h__ #define __EOKeyValueCoding_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSArray.h> #include <Foundation/NSObject.h>
#import <Foundation/NSKeyValueCoding.h> #include <Foundation/NSArray.h>
#import <Foundation/NSDictionary.h> #include <Foundation/NSKeyValueCoding.h>
#include <Foundation/NSDictionary.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <EOControl/EODefines.h>
@interface NSObject (EOKVCPAdditions2) @interface NSObject (EOKVCPAdditions2)
@ -79,8 +85,8 @@
@end @end
#endif #endif
extern NSString *EOUnknownKeyException; GDL2CONTROL_EXPORT NSString *EOUnknownKeyException;
extern NSString *EOTargetObjectUserInfoKey; GDL2CONTROL_EXPORT NSString *EOTargetObjectUserInfoKey;
extern NSString *EOUnknownUserInfoKey; GDL2CONTROL_EXPORT NSString *EOUnknownUserInfoKey;
#endif /* __EOKeyValueCoding_h__ */ #endif /* __EOKeyValueCoding_h__ */

View file

@ -41,26 +41,31 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSArray.h> #include <Foundation/NSObject.h>
#import <Foundation/NSDictionary.h> #include <Foundation/NSArray.h>
#import <Foundation/NSString.h> #include <Foundation/NSDictionary.h>
#import <Foundation/NSValue.h> #include <Foundation/NSString.h>
#import <Foundation/NSHashTable.h> #include <Foundation/NSValue.h>
#import <Foundation/NSException.h> #include <Foundation/NSHashTable.h>
#import <Foundation/NSObjCRuntime.h> #include <Foundation/NSException.h>
#import <Foundation/NSMapTable.h> #include <Foundation/NSObjCRuntime.h>
#import <Foundation/NSUtilities.h> #include <Foundation/NSMapTable.h>
#import <Foundation/NSDecimalNumber.h> #include <Foundation/NSUtilities.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSDecimalNumber.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <gnustep/base/GSCategories.h>
#include <objc/objc-api.h>
#include <ctype.h> #include <ctype.h>
#import <EOControl/EOKeyValueCoding.h> #include <EOControl/EOKeyValueCoding.h>
#import <EOControl/EONSAddOns.h> #include <EOControl/EONSAddOns.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
#import <EOControl/EONull.h> #include <EOControl/EONull.h>
#include <ctype.h> #include <ctype.h>
@ -71,6 +76,10 @@ RCS_ID("$Id$")
@implementation NSObject (EOKVCPAdditions2) @implementation NSObject (EOKVCPAdditions2)
+ (void) flushClassKeyBindings
{
}
/** if key is a bidirectional rel, use addObject:toBothSidesOfRelationship otherwise call takeValue:forKey: **/ /** if key is a bidirectional rel, use addObject:toBothSidesOfRelationship otherwise call takeValue:forKey: **/
- (void)smartTakeValue: (id)anObject - (void)smartTakeValue: (id)anObject
forKey: (NSString *)aKey forKey: (NSString *)aKey
@ -152,16 +161,19 @@ RCS_ID("$Id$")
NSEnumerator *keyEnum; NSEnumerator *keyEnum;
id key; id key;
id val; id val;
EONull *null;
EOFLOGObjectFnStartCond(@"EOKVC"); EOFLOGObjectFnStartCond(@"EOKVC");
keyEnum = [dictionary keyEnumerator]; keyEnum = [dictionary keyEnumerator];
null = (EONull *)[EONull null];
while ((key = [keyEnum nextObject])) while ((key = [keyEnum nextObject]))
{ {
val = [dictionary objectForKey: key]; val = [dictionary objectForKey: key];
if ([val isKindOfClass: [[EONull null] class]]) if (val == null)
val = nil; val = nil;
[self takeStoredValue: val forKey: key]; [self takeStoredValue: val forKey: key];

View file

@ -38,14 +38,20 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/Foundation.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSString.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSObjCRuntime.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOQualifier.h> #include <EOControl/EOQualifier.h>
#import <EOControl/EOKeyValueCoding.h> #include <EOControl/EOKeyValueCoding.h>
#import <EOControl/EOObjectStore.h> #include <EOControl/EOObjectStore.h>
#import <EOControl/EOObjectStoreCoordinator.h> #include <EOControl/EOObjectStoreCoordinator.h>
#import <EOControl/EOEditingContext.h> #include <EOControl/EOEditingContext.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
@implementation EOKeyValueQualifier @implementation EOKeyValueQualifier
@ -135,16 +141,16 @@ RCS_ID("$Id$")
* method with the receivers value as the parameter.<br/> * method with the receivers value as the parameter.<br/>
* If the value object doesn't implement the receivers selector, but the * If the value object doesn't implement the receivers selector, but the
* selector of the reciever is one of:<br/> * selector of the reciever is one of:<br/>
+ <list> * <list>
* EOQualifierOperatorEqual * <item>EOQualifierOperatorEqual</item>
* EOQualifierOperatorNotEqual * <item>EOQualifierOperatorNotEqual</item>
* EOQualifierOperatorLessThan * <item>EOQualifierOperatorLessThan</item>
* EOQualifierOperatorGreaterThan * <item>EOQualifierOperatorGreaterThan</item>
* EOQualifierOperatorLessThanOrEqual * <item>EOQualifierOperatorLessThanOrEqual</item>
* EOQualifierOperatorGreaterThanOrEqual * <item>EOQualifierOperatorGreaterThanOrEqual</item>
* EOQualifierOperatorContains * <item>EOQualifierOperatorContains</item>
* EOQualifierOperatorLike * <item>EOQualifierOperatorLike</item>
* EOQualifierOperatorCaseInsensitiveLike * <item>EOQualifierOperatorCaseInsensitiveLike</item>
* </list> * </list>
* then GDL2 tries to evaluate the qualifier by invoking * then GDL2 tries to evaluate the qualifier by invoking
* isEqual:, compare:, rangeOfString: respectively and interpreting the * isEqual:, compare:, rangeOfString: respectively and interpreting the

View file

@ -27,11 +27,15 @@
#ifndef __EOMultipleKnownKeyDictionary_h__ #ifndef __EOMultipleKnownKeyDictionary_h__
#define __EOMultipleKnownKeyDictionary_h__ #define __EOMultipleKnownKeyDictionary_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSEnumerator.h> #include <Foundation/NSObject.h>
#import <Foundation/NSZone.h> #include <Foundation/NSEnumerator.h>
#include <Foundation/NSZone.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <gnustep/base/GCObject.h> #include <gnustep/base/GCObject.h>
@class NSArray; @class NSArray;

View file

@ -35,11 +35,21 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/Foundation.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSArray.h>
#include <Foundation/NSString.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSEnumerator.h>
#include <Foundation/NSException.h>
#include <Foundation/NSZone.h>
#include <Foundation/NSMapTable.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOMutableKnownKeyDictionary.h> #include <EOControl/EOMutableKnownKeyDictionary.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
#import <EOControl/EONull.h> #include <EOControl/EONull.h>
@implementation EOMKKDInitializer @implementation EOMKKDInitializer
@ -473,6 +483,7 @@ RCS_ID("$Id$")
subsetMapping: (EOMKKDSubsetMapping *)subsetMapping subsetMapping: (EOMKKDSubsetMapping *)subsetMapping
{ {
#warning (stephane@sente.ch) Method is really not implemented! #warning (stephane@sente.ch) Method is really not implemented!
#warning (Ayers 28-03-2003) Either remove this method from array or use EOMutableKnownKeyDictionary instead of self
return [[self newDictionaryFromDictionary: dict return [[self newDictionaryFromDictionary: dict
subsetMapping: subsetMapping subsetMapping: subsetMapping
zone: NULL] autorelease]; zone: NULL] autorelease];

View file

@ -27,12 +27,27 @@
#ifndef __EONSAddOns_h__ #ifndef __EONSAddOns_h__
#define __EONSAddOns_h__ #define __EONSAddOns_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSString.h> #include <Foundation/NSObject.h>
#include <Foundation/NSString.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <EOControl/EODefines.h>
@class NSArray; @class NSArray;
@class NSLock;
@class NSRecursiveLock;
GDL2CONTROL_EXPORT BOOL
GSUseStrictWO451Compatibility(NSString *key);
GDL2CONTROL_EXPORT NSLock *
GDL2GlobalLock();
GDL2CONTROL_EXPORT NSRecursiveLock *
GDL2GlobalRecursiveLock();
@interface NSObject (NSObjectPerformingSelector) @interface NSObject (NSObjectPerformingSelector)
- (NSArray*)resultsOfPerformingSelector: (SEL)sel - (NSArray*)resultsOfPerformingSelector: (SEL)sel
@ -75,5 +90,4 @@
- (BOOL)isYorYES; - (BOOL)isYorYES;
@end @end
#endif /* __EONSAddOns_h__ */ #endif /* __EONSAddOns_h__ */

View file

@ -35,10 +35,79 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/Foundation.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSString.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSLock.h>
#include <Foundation/NSUserDefaults.h>
#include <Foundation/NSNotification.h>
#include <Foundation/NSThread.h>
#include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EONSAddOns.h> #include <EOControl/EONSAddOns.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
static BOOL GSStrictWO451Flag = NO;
BOOL
GSUseStrictWO451Compatibility (NSString *key)
{
static BOOL read = NO;
if (read == NO)
{
NSLock *lock = GDL2GlobalLock();
if (lock!=nil)
{
[lock lock];
}
NS_DURING
if (read == NO)
{
NSUserDefaults *defaults;
defaults = [NSUserDefaults standardUserDefaults];
GSStrictWO451Flag
= [defaults boolForKey: @"GSUseStrictWO451Compatibility"];
read = YES;
}
NS_HANDLER
if (lock != nil)
{
[lock unlock];
}
[localException raise];
NS_ENDHANDLER
if (lock != nil)
{
[lock unlock];
}
}
return GSStrictWO451Flag;
}
/* We use this helper class because the runtime
guarantees to call +initialize under a mutex,
allowing for clean setup of the global locks.*/
@interface GDL2GlobalLockVendor : NSObject
+ (NSLock *) globalLock;
+ (NSRecursiveLock *) globalRecursiveLock;
@end
NSLock *
GDL2GlobalLock()
{
return [GDL2GlobalLockVendor globalLock];
}
NSRecursiveLock *
GDL2GlobalRecursiveLock()
{
return [GDL2GlobalLockVendor globalRecursiveLock];
}
@implementation NSObject (NSObjectPerformingSelector) @implementation NSObject (NSObjectPerformingSelector)
@ -60,7 +129,7 @@ RCS_ID("$Id$")
if (array) if (array)
{ {
int i, count = [array count]; int i, count = [array count];
id object = nil; volatile id object = nil;
results = [NSMutableArray array]; results = [NSMutableArray array];
@ -122,7 +191,7 @@ RCS_ID("$Id$")
{ {
NSMutableArray *results=[NSMutableArray array]; NSMutableArray *results=[NSMutableArray array];
int i, count = [self count]; int i, count = [self count];
id object = nil; volatile id object = nil;
NSDebugMLLog(@"gsdb", @"self:%p (%@) results:%p (%@)", NSDebugMLLog(@"gsdb", @"self:%p (%@) results:%p (%@)",
self, [self class], results, [results class]); self, [self class], results, [results class]);
@ -182,7 +251,7 @@ RCS_ID("$Id$")
{ {
NSMutableArray *results = [NSMutableArray array]; NSMutableArray *results = [NSMutableArray array];
int i, count = [self count]; int i, count = [self count];
id object = nil; volatile id object = nil;
//OPTIMIZE //OPTIMIZE
NS_DURING NS_DURING
@ -240,7 +309,7 @@ RCS_ID("$Id$")
{ {
NSMutableArray *results = [NSMutableArray array]; NSMutableArray *results = [NSMutableArray array];
int i, count = [self count]; int i, count = [self count];
id object = nil; volatile id object = nil;
//OPTIMIZE //OPTIMIZE
NS_DURING NS_DURING
@ -418,11 +487,14 @@ RCS_ID("$Id$")
@end @end
@interface NSObject (EOCOmpareOnNameSupport)
- (NSString *)name;
@end
@implementation NSObject (EOCompareOnName) @implementation NSObject (EOCompareOnName)
- (NSComparisonResult)eoCompareOnName: (id)object - (NSComparisonResult)eoCompareOnName: (id)object
{ {
return [(NSString *)[(id)self name] compare: [object name]]; return [[self name] compare: [(NSObject *)object name]];
} }
@end @end
@ -435,3 +507,80 @@ RCS_ID("$Id$")
} }
@end @end
@interface GDL2GlobalLockVendor (private)
+ (void) _setupLocks: (NSNotification *)notif;
@end
@implementation GDL2GlobalLockVendor
static NSLock *lock = nil;
static NSRecursiveLock *rlock = nil;
/*
* Depending on whether we are multithreaded or not, we
* setup for the becomeMultithreadedNotification to
* invoke _setupLocks: or invoke it directly. This method
* is invoked once by the runtime under a lock and
* therefor allows thread safe access to global variables.
*/
+ (void) initialize
{
if (self == [GDL2GlobalLockVendor class])
{
if ([NSThread isMultiThreaded] == YES)
{
[self _setupLocks: nil];
}
else
{
NSNotificationCenter *nc;
nc = [NSNotificationCenter defaultCenter];
[nc addObserver: self
selector:@selector(_setupLocks:)
name: NSWillBecomeMultiThreadedNotification
object: nil];
}
}
}
/*
* Setup globalLock and globalRecursiveLock. This method should
* only be called from a thread safe context (i.e. from +initialze
* or during NSWillBecomeMultiThreadedNotification).
*/
+ (void) _setupLocks: (NSNotification *)notif
{
if (lock == nil && rlock == nil)
{
lock = [NSLock new];
rlock = [NSRecursiveLock new];
}
else
{
NSLog(@"%@ - +%@ called multiple times!",
NSStringFromClass([self class]),
NSStringFromSelector(_cmd));
}
}
/**
* Returns a global NSLock, if the process is multithreaded.
* Otherwise returns nil.
*/
+ (NSLock *) globalLock
{
return lock;
}
/**
* Returns a global NSRecursiveLock, if the process is multithreaded.
* Otherwise returns nil.
*/
+ (NSRecursiveLock *) globalRecursiveLock
{
return rlock;
}
@end

View file

@ -35,11 +35,15 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSDictionary.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSSet.h> #include <Foundation/NSDictionary.h>
#import <Foundation/NSUtilities.h> #include <Foundation/NSSet.h>
#include <Foundation/NSUtilities.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EOQualifier.h> #include <EOControl/EOQualifier.h>
@implementation EONotQualifier @implementation EONotQualifier

View file

@ -1,7 +1,7 @@
/* /*
EONull.h EONull.h
Copyright (C) 1996-2002 Free Software Foundation, Inc. Copyright (C) 1996-2002, 2003 Free Software Foundation, Inc.
Author: Mircea Oancea <mircea@jupiter.elcom.pub.ro> Author: Mircea Oancea <mircea@jupiter.elcom.pub.ro>
Date: 1996 Date: 1996
@ -27,20 +27,25 @@
#ifndef __EONull_h__ #ifndef __EONull_h__
#define __EONull_h__ #define __EONull_h__
#import <Foundation/NSObject.h> #ifndef NeXT_Foundation_LIBRARY
#include <Foundation/NSObject.h>
#else
#include <Foundation/Foundation.h>
#endif
#include <EOControl/EODefines.h>
@interface EONull : NSObject <NSCopying> @interface EONull : NSObject <NSCopying>
/* Type is ommited to avoid compiler warnings
triggerd by NSNull. */
+ null; + null;
@end /* EONull */ @end /* EONull */
@interface NSObject (EONull) @interface NSObject (EONull)
- (BOOL)isEONull; - (BOOL)isEONull;
- (BOOL)isNotEONull; - (BOOL)isNotEONull;
@end @end
extern BOOL isNilOrEONull(id v); GDL2CONTROL_EXPORT BOOL isNilOrEONull(id v);
#endif /* __EONull_h__ */ #endif /* __EONull_h__ */

View file

@ -38,68 +38,24 @@
RCS_ID("$Id$") RCS_ID("$Id$")
#import <Foundation/NSNull.h> #ifndef NeXT_Foundation_LIBRARY
#import <Foundation/NSString.h> #include <Foundation/NSNull.h>
#import <Foundation/NSDebug.h> #include <Foundation/NSString.h>
#include <Foundation/NSException.h>
#include <Foundation/NSDebug.h>
#else
#include <Foundation/Foundation.h>
#endif
#import <EOControl/EONull.h> #include <EOControl/EONull.h>
#import <EOControl/EODebug.h> #include <EOControl/EODebug.h>
@implementation EONull @implementation EONull
static EONull *sharedEONull = nil; static EONull *sharedEONull = nil;
#ifndef FOUNDATION_HAS_KVC + (void) initialize
+ (void)initialize
{
// THREAD - do this operation under a lock
sharedEONull = (EONull *)NSAllocateObject(self, 0, NSDefaultMallocZone());
}
+ null
{
return sharedEONull;
}
+ allocWithZone
{
return sharedEONull;
}
- copy
{
return self;
}
- copyWithZone: (NSZone *)zone
{
return self;
}
// One cannot destroy the shared null object
- (id)retain
{
return self;
}
- (id)autorelease
{
return self;
}
- (void)release
{
}
- (void)dealloc
{
}
#else
+ (void)initialize
{ {
sharedEONull = (EONull *)[NSNull null]; sharedEONull = (EONull *)[NSNull null];
} }
@ -109,57 +65,59 @@ static EONull *sharedEONull = nil;
return sharedEONull; return sharedEONull;
} }
+ allocWithZone + (id) allocWithZone:(NSZone *)zone
{ {
return sharedEONull; return sharedEONull;
} }
- copy - (id) copy
{ {
NSAssert1(NO,@"EONull instance received:%@",NSStringFromSelector(_cmd));
return sharedEONull; return sharedEONull;
} }
- copyWithZone: (NSZone *)zone - (id) copyWithZone: (NSZone *)zone
{ {
NSAssert1(NO,@"EONull instance received:%@",NSStringFromSelector(_cmd));
return sharedEONull; return sharedEONull;
} }
- (id)retain - (id) retain
{ {
NSAssert1(NO,@"EONull instance received:%@",NSStringFromSelector(_cmd));
return sharedEONull; return sharedEONull;
} }
- (id)autorelease - (id) autorelease
{ {
NSAssert1(NO,@"EONull instance received:%@",NSStringFromSelector(_cmd));
return sharedEONull; return sharedEONull;
} }
- (void)release - (void) release
{ {
NSAssert1(NO,@"EONull instance received:%@",NSStringFromSelector(_cmd));
} }
- (void)dealloc - (void) dealloc
{ {
NSAssert1(NO,@"EONull instance received:%@",NSStringFromSelector(_cmd));
} }
// OK
- (id)valueForKey: (NSString *)key - (id)valueForKey: (NSString *)key
{ {
return self; NSAssert1(NO,@"EONull instance received:%@",NSStringFromSelector(_cmd));
return nil;
} }
#endif - (NSString *) sqlString
- (NSString *)sqlString
{ {
EOFLOGObjectFnStart(); NSAssert1(NO,@"EONull instance received:%@",NSStringFromSelector(_cmd));
EOFLOGObjectFnStop(); return nil;
return @"NULL";
} }
@end /* EONull */ @end /* EONull */
#ifdef FOUNDATION_HAS_KVC
@implementation NSNull (EOSQLFormatting) @implementation NSNull (EOSQLFormatting)
- (NSString *)sqlString - (NSString *)sqlString
@ -170,13 +128,13 @@ static EONull *sharedEONull = nil;
return @"NULL"; return @"NULL";
} }
//OK
- (id)valueForKey:(NSString *)key - (id)valueForKey:(NSString *)key
{ {
return self; return self;
}; }
@end @end
#endif
@implementation NSObject (EONull) @implementation NSObject (EONull)

Some files were not shown because too many files have changed in this diff Show more