-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
157 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
Extension { #name : #ToCheckableGroup } | ||
|
||
{ #category : #'*Toplo-Serialization' } | ||
ToCheckableGroup >> fromSton: stonReader [ | ||
|
||
stonReader parseMapDo: [ :key :value | | ||
key = #checkingStrategy ifTrue: [ self checkingStrategy: value ] ] | ||
] | ||
|
||
{ #category : #'*Toplo-Serialization' } | ||
ToCheckableGroup >> stonOn: stonWriter [ | ||
|
||
stonWriter writeObject: self streamMap: [ :dictionary | | ||
dictionary | ||
at: #checkingStrategy put: self checkingStrategy ] | ||
] | ||
|
||
{ #category : #'*Toplo-Serialization' } | ||
ToCheckableGroup >> stonProcessSubObjects: block [ | ||
|
||
self | ||
instVarNamed: #checkingStrategy | ||
put: (block value: (self instVarNamed: #checkingStrategy)). | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
Extension { #name : #ToCheckbox } | ||
|
||
{ #category : #'*Toplo-Serialization' } | ||
ToCheckbox >> stonPostReferenceResolution [ | ||
|
||
super stonPostReferenceResolution. | ||
self userData at: #stonChecked ifPresent: [ :aCheckValue | | ||
self checked: aCheckValue. | ||
self userData removeKey: #stonChecked ]. | ||
self userData at: #stonGroup ifPresent: [ :aGroup | | ||
aGroup add: self. | ||
self userData removeKey: #stonGroup ] | ||
] | ||
|
||
{ #category : #'*Toplo-Serialization' } | ||
ToCheckbox >> stonUserDataOn: aIdentityDictionary [ | ||
|
||
super stonUserDataOn: aIdentityDictionary. | ||
aIdentityDictionary at: #stonChecked put: self checked. | ||
self group ifNotNil: [ aIdentityDictionary at: #stonGroup put: self group. ] | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters