MCLazyVersionInfo.st
author HG Automerge
Thu, 24 Nov 2016 21:56:31 +0000
branchjv
changeset 1015 7b6393ea3d52
parent 1003 0ebeea1cdeeb
child 1095 87f223484bc3
permissions -rw-r--r--
Merge
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
268
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     1
"{ Package: 'stx:goodies/monticello' }"
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     2
999
679cac09d882 Fix in MCLazyVersionInfo: set ancestor instvar to nil when initializing
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 635
diff changeset
     3
"{ NameSpace: Smalltalk }"
679cac09d882 Fix in MCLazyVersionInfo: set ancestor instvar to nil when initializing
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 635
diff changeset
     4
268
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     5
MCVersionInfo subclass:#MCLazyVersionInfo
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     6
	instanceVariableNames:'ancestorsProps stepChildrenProps'
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     7
	classVariableNames:''
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     8
	poolDictionaries:''
635
85074a06c86b category change
Claus Gittinger <cg@exept.de>
parents: 341
diff changeset
     9
	category:'SCM-Monticello-St/X support'
268
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    10
!
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    11
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    12
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    13
!MCLazyVersionInfo class methodsFor:'instance creation'!
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    14
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    15
withProperties: properties
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    16
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    17
    ^self new initializeWithProperties: properties
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    18
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    19
    "Created: / 28-10-2010 / 15:34:14 / Jan Vrany <jan.vrany@fit.cvut.cz>"
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    20
! !
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    21
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    22
!MCLazyVersionInfo methodsFor:'accessing'!
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    23
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    24
ancestors
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    25
1003
0ebeea1cdeeb Added MCWorkingAncestry>>ancestors:
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 999
diff changeset
    26
    ancestors isNil ifTrue:
0ebeea1cdeeb Added MCWorkingAncestry>>ancestors:
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 999
diff changeset
    27
        [ancestorsProps notNil ifTrue:
268
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    28
            [ancestors := ancestorsProps collect:[:p|MCLazyVersionInfo withProperties:p].
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    29
            ancestorsProps := nil]].
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    30
    ^super ancestors
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    31
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    32
    "Created: / 28-10-2010 / 17:51:41 / Jan Vrany <jan.vrany@fit.cvut.cz>"
1003
0ebeea1cdeeb Added MCWorkingAncestry>>ancestors:
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 999
diff changeset
    33
    "Modified: / 07-09-2015 / 15:45:27 / Jan Vrany <jan.vrany@fit.cvut.cz>"
268
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    34
!
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    35
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    36
stepChildren
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    37
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    38
    stepChildren ifNil:
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    39
        [stepChildrenProps ifNotNil:
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    40
            [stepChildren := stepChildrenProps collect:[:p|MCLazyVersionInfo withProperties:p].
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    41
            stepChildrenProps := nil]].
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    42
    ^super stepChildren
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    43
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    44
    "Created: / 28-10-2010 / 17:52:06 / Jan Vrany <jan.vrany@fit.cvut.cz>"
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    45
! !
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    46
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    47
!MCLazyVersionInfo methodsFor:'initialization'!
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    48
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    49
initializeWithProperties: dict
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    50
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    51
    name:= (dict at: #name ifAbsent: ['']).
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    52
    id:= (UUID fromString: (dict at: #id)).
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    53
    message:= (dict at: #message ifAbsent: ['']).
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    54
    date:= ([Date fromString: (dict at: #date) ] on: Error do: [ :ex | ex return: nil ]).
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    55
    time:= ([ Time fromString:(dict at: #time)] on: Error do: [ :ex | ex return: nil ]).
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    56
    author:= (dict at: #author ifAbsent: ['']).
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    57
999
679cac09d882 Fix in MCLazyVersionInfo: set ancestor instvar to nil when initializing
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 635
diff changeset
    58
    (dict includesKey: #ancestors) ifTrue:[ 
679cac09d882 Fix in MCLazyVersionInfo: set ancestor instvar to nil when initializing
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 635
diff changeset
    59
        ancestorsProps:= dict at: #ancestors.
679cac09d882 Fix in MCLazyVersionInfo: set ancestor instvar to nil when initializing
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 635
diff changeset
    60
        ancestors := nil.
679cac09d882 Fix in MCLazyVersionInfo: set ancestor instvar to nil when initializing
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 635
diff changeset
    61
    ].
268
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    62
    stepChildrenProps:= dict at: #stepChildren ifAbsent: [#()].
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    63
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    64
    "Created: / 28-10-2010 / 15:36:09 / Jan Vrany <jan.vrany@fit.cvut.cz>"
999
679cac09d882 Fix in MCLazyVersionInfo: set ancestor instvar to nil when initializing
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 635
diff changeset
    65
    "Modified: / 12-05-2015 / 01:05:38 / Jan Vrany <jan.vrany@fit.cvut.cz>"
268
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    66
! !
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    67
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    68
!MCLazyVersionInfo class methodsFor:'documentation'!
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    69
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    70
version
635
85074a06c86b category change
Claus Gittinger <cg@exept.de>
parents: 341
diff changeset
    71
    ^ '$Header: /cvs/stx/stx/goodies/monticello/MCLazyVersionInfo.st,v 1.3 2012-09-11 21:22:41 cg Exp $'
268
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    72
!
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    73
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    74
version_CVS
635
85074a06c86b category change
Claus Gittinger <cg@exept.de>
parents: 341
diff changeset
    75
    ^ '$Header: /cvs/stx/stx/goodies/monticello/MCLazyVersionInfo.st,v 1.3 2012-09-11 21:22:41 cg Exp $'
268
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    76
!
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    77
999
679cac09d882 Fix in MCLazyVersionInfo: set ancestor instvar to nil when initializing
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 635
diff changeset
    78
version_HG
679cac09d882 Fix in MCLazyVersionInfo: set ancestor instvar to nil when initializing
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 635
diff changeset
    79
679cac09d882 Fix in MCLazyVersionInfo: set ancestor instvar to nil when initializing
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 635
diff changeset
    80
    ^ '$Changeset: <not expanded> $'
679cac09d882 Fix in MCLazyVersionInfo: set ancestor instvar to nil when initializing
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 635
diff changeset
    81
!
679cac09d882 Fix in MCLazyVersionInfo: set ancestor instvar to nil when initializing
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 635
diff changeset
    82
268
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    83
version_SVN
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    84
    ^ '§Id: MCLazyVersionInfo.st 23 2010-10-29 14:41:24Z vranyj1 §'
5778c85179ee initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    85
! !
999
679cac09d882 Fix in MCLazyVersionInfo: set ancestor instvar to nil when initializing
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 635
diff changeset
    86