Commit graph

18 commits

Author SHA1 Message Date
Matt Rice
f7ceba56ed * EOAccess/EOEntityPriv.h: Remove GDL2DestinationEntitiesAddRelationship, and
GDL2DestinationEntitiesRemoveRelationship.
* EOAccess/EOEntity.m (+initialize, -dealloc): Remove usage and
implementations of the above functions.
* EOAccess/EORelationship.m (-initWithPropertyList:owner:):
(-setDefinition:): Ditto.



git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@27908 72102866-910b-0410-8b05-ffd578937521
2009-02-18 05:05:21 +00:00
Matt Rice
40f55c0218 * EOAccess/EOEntityPriv.h: Declare new private method
_hasAttributeNamed:.
        * EOAccess/EOEntity.m (-_hasAttributeNamed:): New private method.
        (-anyAttributeNamed:): Add a comment.
        * EOAccess/EOAttribute.m (-validateName:): Use -_hasAttributeNamed:
        instead of -anyAttributeNamed:
        * EOAccess/EORelationship.m (-validateName:): Ditto.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@26480 72102866-910b-0410-8b05-ffd578937521
2008-05-01 10:42:08 +00:00
Matt Rice
379b5306f8 rearrange attribute and relationship name cache invalidation and creation.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@26259 72102866-910b-0410-8b05-ffd578937521
2008-03-10 11:53:12 +00:00
Matt Rice
e35a70da43 * DBModeler/Modeler.m,
* EOAccess/EOEntityPriv.h,
        * EOAccess/EOModel.h/m,
        * EOAccess/EOEntity.h/m,
        * EOAccess/EORelationship.h/m: Remove setCreateMutableObjects: and
        createsMutableObjects.



git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@26227 72102866-910b-0410-8b05-ffd578937521
2008-03-06 16:28:22 +00:00
David Ayers
9720ac993d * COPYING.LIB: Update to LGPL 3.
* DB2Modeler/COPYING:  Update to GPL 3.
	* *.*: Update copyright notices.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@25326 72102866-910b-0410-8b05-ffd578937521
2007-07-12 06:39:22 +00:00
Matt Rice
9e08693c96 * EOAccess/EOModel.m (-dealloc): Set entities model to nil.
* EOAccess/EOEntityPriv.h: Add functions for maintining list of
        relationships and their destination entities.
        * EOAccess/EOEntity.m: Implement new functions.
        (-dealloc:): Set attributes entities, and relationships source 
	and destinations entities to nil.
        (+initialize:): Initialize static map table.
        * EOAccess/EORelationship.m: Call functions to maintain 
	destination entities.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@23954 72102866-910b-0410-8b05-ffd578937521
2006-10-23 15:29:27 +00:00
Matt Rice
a7f90ca359 * EOAccess/EOEntityPriv.h: Rename setParentEntity: to
_setParentEntity:.
        * EOAccess/EOEntity.m (-addSubEntity:): Ditto.
        (-removeSubEntity:): Ditto, and check that self is the parent before
        setting to nil.



git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@23707 72102866-910b-0410-8b05-ffd578937521
2006-10-02 07:29:29 +00:00
David Ayers
7331d77528 * EOAdaptors/Postgres95/GNUmakefile.in:
Install into GNUSTEP_SYSTEM_ROOT by default.

	* * Update email addresses for Mirko Viviani and David Ayers.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@23510 72102866-910b-0410-8b05-ffd578937521
2006-09-14 16:06:21 +00:00
David Ayers
ad43813eb0 * EOAccess/EOSQLExpression.h (deleteStatementWithQualifier:entity:)
* EOAccess/EOSQLExpressionPriv.h (_aliasForRelationshipPath:)
	(_flattenRelPath:entity:, _aliasForRelatedAttribute:relationshipPath:)
	* EOAccess/EOSQLExpression.m (insertStatementForRow:entity:)
	(updateStatementForRow:qualifier:entity:)
	(deleteStatementWithQualifier:entity:)
	(selectStatementForAttributes🔒fetchSpecification:entity:)
	(_aliasForRelationshipPath:)
	* EOAccess/EORelationship.h (intermediateEntity)
	(_foreignKeyForSourceRow:)
	* EOAccess/EORelationship.m (_foreignKeyForSourceRow:, _leftSideKeyMap)
	* EOAccess/EODatabaseContext.h (databaseOperationForObject:)
	(databaseOperationForGlobalID:, recordDatabaseOperation:)
	(_openChannelWithLoginPanel:)
	* EOAccess/EODatabaseContextPriv.h (primaryKeyForObject:)
	(_currentCommittedSnapshotForObject:)
	* EOAccess/EOEntityPriv.h (_keyMapForRelationshipPath:)
	(_keyMapForIdenticalKeyRelationshipPath:, _mapAttribute:)
	(_relationshipPathIsToMany: valueForSQLExpression:)
	(_parsePropertyName:, classPropertyAttributeNames)
	(classPropertyToManyRelationshipNames)
	(classPropertyToOneRelationshipNames, dbSnapshotKeys)
	* EOAccess/EOUtilities.m (rawRowsForEntityNamed:qualifierFormat:)
	(rawRowsMatchingValue:forKey:entityNamed:)
	(rawRowsMatchingValues:entityNamed:, rawRowsWithSQL:modelNamed:)
	(rawRowsWithStoredProcedureNamed:arguments:)
	(executeStoredProcedureNamed:arguments:, databaseContextForModelNamed:)
	(primaryKeyForObject:)
	(destinationKeyForSourceObject:relationshipNamed:)
	* EOAccess/EOEntity.m
	(_mapAttribute:toDestinationAttributeInLastComponentOfRelationshipPath:)
	* EOAccess/EOAdaptor.h (adaptorWithModel:,adaptorWithName:)
	* EOAccess/EOModel.h (_classDescriptionNeeded:,_entityForClass:)
	(_addEntityWithPropertyList:)
	* EOAdaptors/Postgres95/Postgres95Channel.h
	(_evaluateExpression:withAttributes:)
	* EOControl/EOMutableKnownKeyDictionary.h/m (arrayMappingForKeys:)
	(subsetMappingForSourceDictionaryInitializer:sourceKeys:destinationKeys:)
	(subsetMappingForSourceDictionaryInitializer:)
	(setObject:forKey:, removeObjectForKey:, indexForKey:, objectForKey:)
	* EOControl/EOEditingContext.m (handleErrors:,setSharedEditingContext:)
	(faultForRawRow:entityNamed:)
	* GDL2Palette/KeyWrapper.h (setKey:, _key):
	* EOModeler/EOModelerEditor.h (selectionWithinViewedObject)
	* EOModeler/EOModelerEditor.m (initWithDocument:)
	(initWithParentEditor:)
	Correct method signatures.  Add necessary forward @class declations.

	* EOInterface/EOMasterDetailAssociation.m (establishConnection):
	* DBModeler/ModelerTableEmbedibleEditor.m
	(addDefaultTableColumnsForTableView:displayGroup:)
	* DBModeler/DefaultColumnProvider.m (setupTitleForColumn:named:)
	Cast types to avoid compiler warnings.

	* EOControl/EOCheapArray.m (dealloc): Supress compiler warning.
	* EOAdaptors/Postgres95/LoginPanel/Postgres95LoginPanel.m (dealloc)
	* EOModeler/EOModelerEditor.m (dealloc):
	* DBModeler/ModelerAttributeEditor.m (dealloc): Add missing call
	to super.
	* DBModeler/Preferences.m (sharedPreferences): Fix implementation for
	new compiler semantics.
	* EOControl/EOMultiReaderLock.m (init): Correct NSConditionLock
	initialization.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@23472 72102866-910b-0410-8b05-ffd578937521
2006-09-12 19:36:24 +00:00
David Ayers
9647f11503 * COPYING.LIB: Update to LGPL 2.1.
* configure: Regenerate.
	* Update FSF Address and Copyright years.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@21645 72102866-910b-0410-8b05-ffd578937521
2005-08-17 08:07:57 +00:00
David Ayers
6a28dfbc6e * EOAccess/EOEntity.m (initWithPropertyList:owner:):
Reformatting for GNU coding standards.
        (-attributes): Fix memory leak.  Use global class cache.
        Handle partially converted attributes array.
        (-_attributeNameChangedFrom:to:): New privat method.
        * EOAccess/EOEntityPriv.h (-_attributeNameChangedFrom:to:):
        Declare new private method.
        * EOAccess/EOAttribute.m (setName:): Call
        -[EOEntity _attributeNameChangedFrom:to:] if attribute is in
        an EOEntity.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@20835 72102866-910b-0410-8b05-ffd578937521
2005-03-03 12:17:57 +00:00
Manuel Guesdon
bd72217067 COmmit Part 2
* EOAccess/EOAdaptor.m:
  o optimization in 'for' loops
* EOAccess/EODatabase.m:
  o include <EOCOntrol/EOPriv.h>
  o replaced isNilOrEONull() by _isNilOrEONull()
* EOAccess/EODatabaseContext.h:
  o added _snapshotForGlobalIDIMP
* EOAccess/EODatabaseContext.m:
  o commented  NSEmitTODO in
  -objectsForSourceGlobalID:relationshipName:editingContext:
  o added beter exception format in
  qualifierForLockingAttributes:primaryKeyAttributes:entity:snapshot:
  o fix compiler warning in -relayPrimaryKey:object:entity:
  o logs
  o optimizations in -objectsWithFetchSpecification:editingContext:
  o replaced isNilOrEONull() by _isNilOrEONull()
  o replace [EOFault isFault:] by _isFault()
  o use _snapshotForGlobalIDIMP
  o IMP usage optimization
* EOAccess/EOAttribute.[hm]:
  o added EOAdaptorUnknownType
  o added _adaptorValueType and avoid recomputing it each time
  o added _valueTypeChar to avoid string comparaisons
  o use EOPriv classes declarations
  o Temporary reverted David changes in
  -adaptorValueByConvertingAttributeValue
* EOAccess/EOAttributePriv.h:
  o added _valueTypeChar to avoid string comparaisons
* EOAccess/EOEntityPriv.h:
  o moved -attributeForPath: and -relationshipForPath: to
  EOEntityGDL2Additions category
* EOAccess/EOEntity.h:
  o moved private -attributeForPath: and -relationshipForPath: to
  EOEntityGDL2Additions category
* EOAccess/EOEntity.m:
  o better exception in classProperties
  o fix compiler warning in -setClassProperties:,
  -setPrimaryKeyAttributes:,
	-setAttributesUsedForLocking:
	o moved -attributeForPath: and -relationshipForPath: to
	EOEntityGDL2Additions category
	o include <EOCOntrol/EOPriv.h>
	o replaced [EONull null] by GDL2EONull
* EOAccess/EOSQLExpression.m:
  o optimization in -tableListWithRootEntity:
  o optimization in -formatSQLString:format:
  o optimization in +sqlPatternFromShellPattern:
  o optimization in +sqlPatternFromShellPattern:withEscapeCharacter:
  o fix in -sqlStringForKeyValueQualifier:
  o added log in -sqlStringForKeyValueQualifier: for not handled
  readFormat
  o added log -addInsertListAttribute:value: for not handled
  writeFormat
  o added log -addUpdateListAttribute:value: for not handled
  writeFormat
  o changed  EOFLOGObjectFnStart to EOFLOGObjectFnStartCond
  o changed  EOFLOGObjectFnStop to EOFLOGObjectFnStopCond
  o include <EOCOntrol/EOPriv.h>
  o replaced [EONull null] by GDL2EONull
* EOAccess/EOSQLQualifier.m:
  o implemented EOKeyComparisonQualifier
  -schemaBasedQualifierWithRootEntity
* EOAccess/EOUtilities.m:
  o include <EOCOntrol/EOPriv.h>
  o replaced [EONull null] by GDL2EONull
* EOControl/EOPriv.[hm]:
  o added. Contains various classes/selectors/IMPs
* EOControl/EOClassDescription.m:
  o handle EONull case in -propagateDeleteForObject:editingContext:,
    -addObject:toPropertyWithKey:, -snapshot,
    -removeObject:fromPropertyWithKey:,
	_setObject:forBothSidesOfRelationshipWithKey:,
	addObject:toBothSidesOfRelationshipWithKey:,
		-removeObject:fromBothSidesOfRelationshipWithKey:
		o fix compiler warning in
		-dictionaryForInstanceProperties, -shallowCopy,
		-updateFromSnapshot:, -snapshot
		o include <EOCOntrol/EOPriv.h>
		o replaced [EONull null] by GDL2EONull
		o replaced isNilOrEONull() by _isNilOrEONull()
		o fix in -validateForSave
		o rewritten -validateValue:forKey: selector build
* EOControl/EOEditingContext.h:
  o added -hasUnprocessedChanges
* EOControl/EOEditingContext.m:
  o added -hasUnprocessedChanges
  o added NS_DURING,... to catch exceptions
  o replace [EOFault isFault:] by _isFault()
  o IMP usage optimization
* EOControl/EOKeyGlobalID.m:
  o replaced isNilOrEONull() by _isNilOrEONull()
  o include <EOCOntrol/EOPriv.h>
* EOControl/EOGenericRecord.m:
  o partially rewritten -description
  o include <EOCOntrol/EOPriv.h>
  o replaced isNilOrEONull() by _isNilOrEONull()
  o replace [EOFault isFault:] by _isFault()
  o changed variable name type of
  _infoForInstanceVariableNamed:retType:retSize:retOffset:
  o rewritten valueForKey:,... to use cString NSKeyValueCoding
* EOControl/EOKeyValueCoding.m:
  o changed NSAssert in NSArray -valueForKey:
  o optimization in NSDictionary -takeValue:forKeyPath:isSmart:
  o optimization in NSDictionary -takeStoredValue:forKeyPath:
  o include <EOCOntrol/EOPriv.h>
  o replaced [EONull null] by GDL2EONull
  o include <EOCOntrol/EOPriv.h>
* EOControl/EOKeyValueQualifier.m:
  o fixes for EONull/nil in -evaluateWithObject:
  o replaced [EONull null] by GDL2EONull
  o include <EOCOntrol/EOPriv.h>
* EOControl/EOSortOrdering.m:
  o include <EOCOntrol/EOPriv.h>
  o replaced [EONull null] by GDL2EONull
* EOAdaptors/Postgres95SQLExpression.m:
  o float formatting in +formatValue:forAttribute:
  o added -externalNameQuoteCharacter
  o added +sqlPatternFromShellPattern:
  o added +sqlPatternFromShellPattern:withEscapeCharacter:
  o replaced isNilOrEONull() by _isNilOrEONull()
* EOAdaptors/Postgres95Channel.m:
  o logs
* EOAdaptors/Postgres95Values.m:
  o logs
  o fix in +setPostgres95Format:
  o fix calendard format to handle timezone (%z)
  o optimizations
* EOControl/EOMutableKnownKeyDictionary.m
  o removed EOMKKDArrayMapping
  +dictionaryFromDictionary:subsetMapping:
  o include <EOCOntrol/EOPriv.h>
  o replaced isNilOrEONull() by _isNilOrEONull()
* EOControl/EONSAddOns.[hm]:
  o added NSString(ShellPattern)


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@20688 72102866-910b-0410-8b05-ffd578937521
2005-02-11 17:37:23 +00:00
David Ayers
4590ef7618 * EOAccess/EOAttribute.m (-[copyWithZone:]): Override
implementation of GCObject as it isn't safe to copy
        EOAttributes.
        * EOAccess/EOEntity.m (-[addAttribute:]); Use NSAsserts to check
        integrity of parameters.  Insure that attribute is not used by
        other entity or stored procedure.
        (-[_setModel:]): Rename from -setModel:.  Assert that entity
        is not used by another model.
        * EOAccess/EOEntityPriv.h (-[_setModel:]): Rename from
        -setModel:.
        * EOAccess/EOModel.m (-[_addEntity:]): Use -_setModel: instead
        of -setModel:.
        (-[removeEntity:]): Ditto.
        (-[addEntity:)): Use NSAssert to insure that entity name is
        unique and that the entity is not being used by other mode.  Use
        -_setModel: instead of -setModel:.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@20032 72102866-910b-0410-8b05-ffd578937521
2004-09-08 13:05:25 +00:00
David Ayers
fd7890a4cf * EOAccess/EOModel.m: Include EOKeyValueCoding.h.
(-[_addEntity:]): Set model via public API.
	* EOAccess/EOEntityPriv.h (-[_setModel:]): Remove.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@20027 72102866-910b-0410-8b05-ffd578937521
2004-09-07 17:20:29 +00:00
David Ayers
dae87e4bec * EOAccess/EOAccessFault.m: Include privat headers locally.
* EOAccess/EOAdaptor.m: Ditto.
	* EOAccess/EOAdaptorChannel.m: Ditto.
	* EOAccess/EOAdaptorContext.m: Ditto.
	* EOAccess/EOAttribute.m: Ditto.
	* EOAccess/EODatabaseChannel.m: Ditto.
	* EOAccess/EODatabaseContext.m: Ditto.
	* EOAccess/EODatabaseOperation.m: Ditto.
	* EOAccess/EOModel.m: Ditto.
	* EOAccess/EORelationship.m: Ditto.
	* EOAccess/EOSQLExpression.m: Ditto.
	* EOAccess/EOSQLQualifier.m: Ditto.

	* EOAccess/EOEntity.h: Remove declarations of privat methods.
	Reorder declaraions.
	(+[entity], +[entityWithPropertyList:owner:]): Deprecate.
	(-[sharedObjectFetchSpecificationNames]): New method.
	(-[setSharedObjectFetchSpecificationsByName:]: Ditto.
	(-[addSharedObjectFetchSpecificationByName:]: Ditto.
	(-[removeSharedObjectFetchSpecificationByName:]: Ditto.
	* EOAccess/EOEntityPriv.h: Add declarations of privat methods.
	Reorder declarations.
	* EOAccess/EOEntity.m: Reorder implementations according to
	headers.  Include privat headers locally.
	(+[entity], +[entityWithPropertyList:owner:]): Deprecate.
	(-[sharedObjectFetchSpecificationNames]): New method.
	(-[setSharedObjectFetchSpecificationsByName:]: Ditto.
	(-[addSharedObjectFetchSpecificationByName:]: Ditto.
	(-[removeSharedObjectFetchSpecificationByName:]: Ditto.

	* EOAccess/EOEntity.m: Adapt usage of deprecated -[entity...]
	and privat methods.
	* EOAccess/EOModel.m: Ditto.
	* EOAdaptors/Postgres95/Postgres95SQLExpression.m: Ditto.

	* TODO: Add comment.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@19772 72102866-910b-0410-8b05-ffd578937521
2004-07-23 18:33:29 +00:00
David Ayers
6ae713bf89 * */*.h: Format declarations consistently. Add -*-objc-*
shabang line.  Replace remaining extern declarations with
	GDL2*_EXPORT.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@19134 72102866-910b-0410-8b05-ffd578937521
2004-04-17 11:30:47 +00:00
Mirko Viviani
b738a6145b * EOAdaptors/Postgres95/Postgres95Channel.m ([Postgres95Channel
-describeTableNames]): implemented.

* EOAccess/EOSQLExpression.h: added missing declaration.
* EOAccess/EORelationship.m ([EORelationship -removeJoin:]): added cast.
* EOAccess/EOModel.m ([EOModel -dealloc]): removes observer correctly.
* EOAccess/EODatabaseContext.h: added missing declaration.
* EOControl/EOFetchSpecification.m ([EOFetchSpecification
-copyWithZone:]): fixed cast.
([EOFetchSpecification -hints]): added cast.
* EOControl/EOClassDescription.m  ([NSException
+validationExceptionWithFormat:]), ([NSException
+aggregateExceptionWithExceptions:]),
([NSException -exceptionAddingEntriesToUserInfo:]): renamed local
variables.
* rearranged header inclusion in all sources.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@15409 72102866-910b-0410-8b05-ffd578937521
2002-12-30 22:10:43 +00:00
Mirko Viviani
bf5ba60b07 *** empty log message ***
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gdl2/trunk@14993 72102866-910b-0410-8b05-ffd578937521
2002-11-15 22:57:05 +00:00