A new version of DeltaStreams-Tirade was added to project DeltaStreams: http://www.squeaksource.com/DeltaStreams/DeltaStreams-Tirade-gk.2.mcz
==================== Summary ====================
Name: DeltaStreams-Tirade-gk.2 Author: gk Time: 4 September 2009, 9:21:15 am UUID: 7c6dee17-ef32-461b-8ddc-ec98ad8b0293 Ancestors: DeltaStreams-Tirade-gk.1
Tirade hooked fully into the domain model etc. Now Deltas can be stored and loaded in Tirade format.
=============== Diff against DeltaStreams-Tirade-gk.1 ===============
Item was added: + ----- Method: DSClassChange>>tiradeClassInstVarNames: (in category '*deltastreams-tirade') ----- + tiradeClassInstVarNames: value + self classInstVarNames: value!
Item was added: + ----- Method: DSClassSuperclassChange>>tiradeSuperclassName: (in category '*deltastreams-tirade') ----- + tiradeSuperclassName: assoc + self oldSuperclassName: assoc key. + self superclassName: assoc value!
Item was changed: TiradeReader subclass: #DSTiradeReader + instanceVariableNames: 'deltas composites' - instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'DeltaStreams-Tirade'!
Item was added: + ----- Method: DSMethodProtocolChange>>tiradeCategory (in category '*deltastreams-tirade') ----- + tiradeCategory + ^oldProtocol -> protocol!
Item was added: + ----- Method: DSClassTypeChange>>tiradeType (in category '*deltastreams-tirade') ----- + tiradeType + ^oldType -> type!
Item was added: + ----- Method: DSMethodSourceChange>>tiradeSource: (in category '*deltastreams-tirade') ----- + tiradeSource: assoc + self oldSource: assoc key; + source: assoc value!
Item was added: + ----- Method: DSMethodChange>>tiradeCategory: (in category '*deltastreams-tirade') ----- + tiradeCategory: value + protocol := value!
Item was added: + ----- Method: DSTiradeReader>>endComposite (in category 'tirade') ----- + endComposite + "Remove from stack." + + composites removeLast!
Item was added: + ----- Method: DSTiradeReader>>result (in category 'reading') ----- + result + ^deltas!
Item was added: + ----- Method: DSClassCategoryChange>>tiradeCategory: (in category '*deltastreams-tirade') ----- + tiradeCategory: assoc + self oldCategory: assoc key. + self category: assoc value!
Item was added: + ----- Method: DSMethodChange>>tiradeSelector: (in category '*deltastreams-tirade') ----- + tiradeSelector: value + self selector: value!
Item was added: + ----- Method: DSClassChange>>tiradeInstVarNames: (in category '*deltastreams-tirade') ----- + tiradeInstVarNames: value + self instVarNames: value!
Item was added: + ----- Method: DSClassCommentChange>>tiradeStamp: (in category '*deltastreams-tirade') ----- + tiradeStamp: assoc + self oldStamp: assoc key; + stamp: assoc value!
Item was added: + ----- Method: DSClassChange>>tiradeInstVarNames (in category '*deltastreams-tirade') ----- + tiradeInstVarNames + ^self instVarNames!
Item was added: + ----- Method: DSMethodProtocolChange>>tiradeCategory: (in category '*deltastreams-tirade') ----- + tiradeCategory: assoc + self oldProtocol: assoc key; + protocol: assoc value!
Item was added: + ----- Method: DSTiradeReader>>initialize (in category 'initialize-release') ----- + initialize + + super initialize. + composites := OrderedCollection new. + deltas := OrderedCollection new. + result := self. "making sure first message is sent to me, see #performMessage" + self controlMessages: #(beginComposite. endComposite. beginChanges. endChanges. endDelta)!
Item was added: + ----- Method: DSClassChange>>tiradePoolDictionaryNames: (in category '*deltastreams-tirade') ----- + tiradePoolDictionaryNames: value + self poolDictionaryNames: value!
Item was added: + ----- Method: DSSharedPoolVarsChange>>tiradePoolDictionaryNames (in category '*deltastreams-tirade') ----- + tiradePoolDictionaryNames + ^oldVars -> poolDictionaryNames!
Item was added: + ----- Method: DSClassChange>>tiradeSuperclassName: (in category '*deltastreams-tirade') ----- + tiradeSuperclassName: value + self superclassName: value!
Item was added: + ----- Method: DSClassTypeChange>>tiradeType: (in category '*deltastreams-tirade') ----- + tiradeType: assoc + self oldType: assoc key. + self type: assoc value!
Item was added: + ----- Method: DSClassInstVarsChange>>tiradeClassInstVarNames: (in category '*deltastreams-tirade') ----- + tiradeClassInstVarNames: assoc + self oldVars: assoc key. + self classInstVarNames: assoc value!
Item was added: + ----- Method: DSSharedPoolVarsChange>>tiradePoolDictionaryNames: (in category '*deltastreams-tirade') ----- + tiradePoolDictionaryNames: assoc + self oldVars: assoc key. + self poolDictionaryNames: assoc value!
Item was added: + ----- Method: DSMethodSourceChange>>tiradeSource (in category '*deltastreams-tirade') ----- + tiradeSource + ^oldSource -> source!
Item was added: + ----- Method: DSClassChange>>tiradeComment (in category '*deltastreams-tirade') ----- + tiradeComment + ^self comment!
Item was added: + ----- Method: DSMethodSourceChange>>tiradeStamp (in category '*deltastreams-tirade') ----- + tiradeStamp + ^oldStamp -> stamp!
Item was added: + ----- Method: DSClassChange>>tiradeOn: (in category '*deltastreams-tirade') ----- + tiradeOn: recorder + + recorder + class: self tiradeClassName + change: self class name + superclassName: self tiradeSuperclassName + instVarNames: self tiradeInstVarNames + classVarNames: self tiradeClassVarNames + poolDictionaryNames: self tiradePoolDictionaryNames + category: self tiradeCategory + type: self tiradeType + classInstVarNames: self tiradeClassInstVarNames + comment: self tiradeComment + stamp: self tiradeStamp + properties: properties!
Item was added: + ----- Method: DSTiradeReader>>beginComposite (in category 'tirade') ----- + beginComposite + "Upcoming messages will create changes that we need to put into + the previous composite change." + + composites add: lastResult!
Item was added: + ----- Method: DSClassChange>>tiradeClassVarNames: (in category '*deltastreams-tirade') ----- + tiradeClassVarNames: value + self classVarNames: value!
Item was added: + ----- Method: DSClassChange>>tiradeType (in category '*deltastreams-tirade') ----- + tiradeType + ^self type!
Item was added: + ----- Method: DSMethodChange>>tiradeOn: (in category '*deltastreams-tirade') ----- + tiradeOn: recorder + recorder + method: self fullClassName -> selector + change: self class name + category: self tiradeCategory + source: self tiradeSource + stamp: self tiradeStamp + properties: properties!
Item was added: + ----- Method: DSTiradeReader>>primitivePerformMessage (in category 'processing') ----- + primitivePerformMessage + + ^receiver perform: selector asSymbol withArguments: arguments asArray!
Item was added: + ----- Method: DSInstVarsChange>>tiradeInstVarNames: (in category '*deltastreams-tirade') ----- + tiradeInstVarNames: assoc + self oldVars: assoc key. + self instVarNames: assoc value!
Item was added: + ----- Method: DSInstVarsChange>>tiradeInstVarNames (in category '*deltastreams-tirade') ----- + tiradeInstVarNames + ^oldVars -> instVarNames!
Item was added: + ----- Method: DSClassCommentChange>>tiradeComment: (in category '*deltastreams-tirade') ----- + tiradeComment: assoc + self oldComment: assoc key. + self comment: assoc value!
Item was added: + ----- Method: DSTiradeReader>>delta:properties: (in category 'tirade') ----- + delta: uuidString36 properties: properties + "Create a new DSDelta from given meta data through Tirade. + We put the Delta on the stack for further Tirade messages." + + result := DSDelta new. + result uuid: (UUID fromString36: uuidString36); properties: (self arrayOfAssocationsToDictionary: properties). + stack add: result. + ^result!
Item was added: + ----- Method: DSClassChange>>tiradeClassName (in category '*deltastreams-tirade') ----- + tiradeClassName + ^self className!
Item was added: + ----- Method: DSClassVarsChange>>tiradeClassVarNames: (in category '*deltastreams-tirade') ----- + tiradeClassVarNames: assoc + self oldVars: assoc key. + self classVarNames: assoc value!
Item was changed: ----- Method: DSDelta>>tiradeOn: (in category '*deltastreams-tirade') ----- tiradeOn: recorder + "Record this delta using Tirade messages."
+ "First the 'header' holding all meta data of the delta." + recorder delta: uuid asString36 properties: properties associations asArray. + + "Then we record all changes recursively. The markers #beginChanges and #endChanges + are always there, even if the delta is empty and has no changes." - recorder delta: uuid asString36 stamp: timeStamp printString properties: properties. recorder beginChanges. self changes do: [:each | each tiradeOn: recorder]. + recorder endChanges. + recorder endDelta! - recorder endChanges!
Item was added: + ----- Method: DSTiradeReader>>upToEnd (in category 'reading') ----- + upToEnd + + self parse. + ^self result!
Item was added: + ----- Method: DSClassCommentChange>>tiradeStamp (in category '*deltastreams-tirade') ----- + tiradeStamp + ^oldStamp -> stamp!
Item was added: + ----- Method: DSTiradeReader>>sendMessage (in category 'processing') ----- + sendMessage + "Add to composite if we have one." + + lastResult := super sendMessageTo: stack last. + composites ifNotEmpty: [composites last add: lastResult]!
Item was added: + ----- Method: DSClassChange>>tiradeType: (in category '*deltastreams-tirade') ----- + tiradeType: value + self type: value!
Item was added: + ----- Method: DSClassNameChange>>tiradeClassName: (in category '*deltastreams-tirade') ----- + tiradeClassName: assoc + self oldName: assoc key. + self className: assoc value!
Item was added: + ----- Method: DSClassChange>>tiradeStamp: (in category '*deltastreams-tirade') ----- + tiradeStamp: value + self stamp: value!
Item was added: + ----- Method: DSTiradeReader>>endChanges (in category 'tirade') ----- + endChanges + "Remove from stack." + + composites removeLast!
Item was added: + ----- Method: DSClassChange>>tiradeClassInstVarNames (in category '*deltastreams-tirade') ----- + tiradeClassInstVarNames + ^self classInstVarNames!
Item was added: + ----- Method: DSMethodChange>>tiradeStamp: (in category '*deltastreams-tirade') ----- + tiradeStamp: value + stamp := value!
Item was added: + ----- Method: DSCompositeClassDeletedChange>>tiradeOn: (in category '*deltastreams-tirade') ----- + tiradeOn: recorder + + self compositeDeleteProperties: properties. + recorder beginComposite. + self changes do: [:each | + each tiradeOn: recorder]. + recorder endComposite!
Item was added: + ----- Method: DSDelta>>method:change:category:source:stamp:properties: (in category '*deltastreams-tirade') ----- + method: classNameAndSelector + change: changeClassName + category: category + source: source + stamp: stamp + properties: aDictionary + "Create and return a method change. + It is not added to this Delta." + + ^((self getClass: changeClassName) + tiradeClassName: classNameAndSelector key + selector: classNameAndSelector value + category: category + source: source + stamp: stamp) + properties: aDictionary!
Item was added: + ----- Method: DSClassNameChange>>tiradeClassName (in category '*deltastreams-tirade') ----- + tiradeClassName + ^self oldName -> self className !
Item was added: + ----- Method: DSMethodChange>>tiradeSource: (in category '*deltastreams-tirade') ----- + tiradeSource: value + source := value!
Item was added: + ----- Method: DSClassChange>>tiradeClassName: (in category '*deltastreams-tirade') ----- + tiradeClassName: value + self className: value!
Item was added: + ----- Method: DSClassSuperclassChange>>tiradeSuperclassName (in category '*deltastreams-tirade') ----- + tiradeSuperclassName + ^oldSuperclassName -> superclassName!
Item was added: + ----- Method: DSClassChange>>tiradeCategory: (in category '*deltastreams-tirade') ----- + tiradeCategory: value + self category: value!
Item was added: + ----- Method: DSCompositeClassChange>>endChanges (in category '*deltastreams-tirade') ----- + endChanges + "Return nil causing this object to be removed + from the Tirade receiver stack." + + ^nil!
Item was added: + ----- Method: DSCompositeClassAddedChange>>tiradeOn: (in category '*deltastreams-tirade') ----- + tiradeOn: recorder + + recorder compositeAddProperties: properties. + recorder beginComposite. + self changes do: [:each | + each tiradeOn: recorder]. + recorder endComposite.!
Item was added: + ----- Method: DSClassChange>>tiradeClassVarNames (in category '*deltastreams-tirade') ----- + tiradeClassVarNames + ^self classVarNames!
Item was added: + ----- Method: DSMethodSelectorChange>>tiradeSelector: (in category '*deltastreams-tirade') ----- + tiradeSelector: assoc + self oldSelector: assoc key; + selector: assoc value!
Item was added: + ----- Method: DSClassChange>>tiradeComment: (in category '*deltastreams-tirade') ----- + tiradeComment: value + self comment: value!
Item was added: + ----- Method: DSDelta>>compositeDeleteProperties: (in category '*deltastreams-tirade') ----- + compositeDeleteProperties: aDictionary + "Create and add change in this Delta." + + ^self add: ( + DSCompositeClassDeletedChange new + properties: aDictionary)!
Item was added: + ----- Method: DSClassInstVarsChange>>tiradeClassInstVarNames (in category '*deltastreams-tirade') ----- + tiradeClassInstVarNames + ^oldVars -> classInstVarNames!
Item was added: + ----- Method: DSMethodSelectorChange>>tiradeSelector (in category '*deltastreams-tirade') ----- + tiradeSelector + ^oldSelector -> selector!
Item was added: + ----- Method: DSClassChange>>tiradePoolDictionaryNames (in category '*deltastreams-tirade') ----- + tiradePoolDictionaryNames + ^self poolDictionaryNames!
Item was added: + ----- Method: DSMethodChange>>tiradeSelector (in category '*deltastreams-tirade') ----- + tiradeSelector + ^selector!
Item was added: + ----- Method: DSTiradeReader>>endDelta (in category 'tirade') ----- + endDelta + "Delta is done. Collect it if we have a collection set up." + + deltas ifNotNil: [deltas add: result]!
Item was added: + ----- Method: DSDelta>>class:change:superclassName:instVarNames:classVarNames:poolDictionaryNames:category:type:classInstVarNames:comment:stamp:properties: (in category '*deltastreams-tirade') ----- + class: className + change: changeName + superclassName: superclassName + instVarNames: instVarNames + classVarNames: classVarNames + poolDictionaryNames: poolDictionaryNames + category: category + type: typeOfClass + classInstVarNames: classInstVarNames + comment: comment + stamp: stamp + properties: aDictionary + "Create and add change in this Delta. + It is not added to this Delta." + + ^((self getClass: changeName) + tiradeClassName: className + superclassName: superclassName + instVarNames: instVarNames + classVarNames: classVarNames + poolDictionaryNames: poolDictionaryNames + category: category + type: typeOfClass + classInstVarNames: classInstVarNames + comment: comment + stamp: stamp) + properties: aDictionary!
Item was added: + ----- Method: DSClassChange>>tiradeStamp (in category '*deltastreams-tirade') ----- + tiradeStamp + ^self stamp!
Item was added: + ----- Method: DSClassVarsChange>>tiradeClassVarNames (in category '*deltastreams-tirade') ----- + tiradeClassVarNames + ^oldVars -> classVarNames!
Item was added: + ----- Method: DSMethodChange>>tiradeSource (in category '*deltastreams-tirade') ----- + tiradeSource + ^source!
Item was added: + ----- Method: DSTiradeReader>>beginChanges (in category 'tirade') ----- + beginChanges + "Upcoming messages will create changes that we need to put into + the previous composite change." + + composites add: lastResult!
Item was added: + ----- Method: DSClassChange>>tiradeSuperclassName (in category '*deltastreams-tirade') ----- + tiradeSuperclassName + ^self superclassName!
Item was added: + ----- Method: DSClassCommentChange>>tiradeComment (in category '*deltastreams-tirade') ----- + tiradeComment + ^oldComment -> comment!
Item was added: + ----- Method: DSMethodChange>>tiradeStamp (in category '*deltastreams-tirade') ----- + tiradeStamp + ^stamp!
Item was added: + ----- Method: DSClassChange>>tiradeCategory (in category '*deltastreams-tirade') ----- + tiradeCategory + ^self category!
Item was changed: ----- Method: DSChange>>tiradeOn: (in category '*deltastreams-tirade') ----- + tiradeOn: recorder + self subclassResponsibility ! - tiradeOn: recorder!
Item was added: + ----- Method: DSDelta>>compositeAddProperties: (in category '*deltastreams-tirade') ----- + compositeAddProperties: aDictionary + "Create and add change in this Delta." + + ^self add: ( + DSCompositeClassAddedChange new + properties: aDictionary)!
Item was added: + ----- Method: DSMethodChange>>tiradeCategory (in category '*deltastreams-tirade') ----- + tiradeCategory + ^protocol!
Item was added: + ----- Method: DSTiradeReader>>next (in category 'reading') ----- + next + "Consume Tirade messages until we have a single delta." + + [deltas size > 0] whileFalse: [super next]. + ^deltas first!
Item was added: + ----- Method: DSMethodSourceChange>>tiradeStamp: (in category '*deltastreams-tirade') ----- + tiradeStamp: assoc + self oldStamp: assoc key; + stamp: assoc value!
Item was added: + ----- Method: DSClassCategoryChange>>tiradeCategory (in category '*deltastreams-tirade') ----- + tiradeCategory + ^oldCategory -> category!
Item was removed: - ----- Method: DSTiradeReader>>delta:stamp:properties: (in category 'tirade') ----- - delta: uuidString36 stamp: timeStampString properties: properties - - result := DSDelta new. - result uuid: (UUID fromString36: uuidString36); properties: properties; timeStamp: (TimeStamp fromString: timeStampString)!
Item was removed: - ----- Method: DSTiradeReader>>addSelector:class:meta:source:protocol:stamp:at:properties: (in category 'reading') ----- - addSelector: aSelector - class: className - meta: meta - source: source - protocol: protocol - stamp: stamp - at: timeStamp - properties: properties - - result !
Item was removed: - ----- Method: DSMethodAddedChange>>tiradeOn: (in category '*deltastreams-tirade') ----- - tiradeOn: recorder - recorder - addSelector: selector - class: className - meta: meta - source: source - protocol: protocol - stamp: stamp - at: timeStamp printString - properties: properties!
packages@lists.squeakfoundation.org