112
|
1 |
"{ Package: 'stx:goodies/monticello' }"
|
|
2 |
|
|
3 |
MCRepository subclass:#MCGOODSRepository
|
|
4 |
instanceVariableNames:'hostname port connection'
|
|
5 |
classVariableNames:''
|
|
6 |
poolDictionaries:''
|
|
7 |
category:'Monticello-Repositories'
|
|
8 |
!
|
|
9 |
|
|
10 |
|
|
11 |
!MCGOODSRepository class methodsFor:'as yet unclassified'!
|
|
12 |
|
|
13 |
creationTemplate
|
|
14 |
^
|
|
15 |
'MCGOODSRepository
|
|
16 |
host: ''localhost''
|
|
17 |
port: 6100'
|
|
18 |
!
|
|
19 |
|
|
20 |
description
|
|
21 |
^ 'GOODS'
|
|
22 |
!
|
|
23 |
|
|
24 |
fillInTheBlankRequest
|
|
25 |
^ 'GOODS Repository:'
|
|
26 |
!
|
|
27 |
|
|
28 |
host: hostname port: portNumber
|
|
29 |
^ self new
|
|
30 |
host: hostname;
|
|
31 |
port: portNumber
|
|
32 |
!
|
|
33 |
|
|
34 |
morphicConfigure
|
|
35 |
^ self fillInTheBlankConfigure
|
|
36 |
! !
|
|
37 |
|
|
38 |
!MCGOODSRepository methodsFor:'as yet unclassified'!
|
|
39 |
|
|
40 |
basicStoreVersion: aVersion
|
|
41 |
self root at: aVersion info put: aVersion.
|
|
42 |
self db commit.
|
|
43 |
!
|
|
44 |
|
|
45 |
db
|
|
46 |
(connection isNil or: [connection isConnected not]) ifTrue: [connection _ KKDatabase onHost:hostname port: port].
|
|
47 |
|
|
48 |
^ connection
|
|
49 |
!
|
|
50 |
|
|
51 |
description
|
|
52 |
^ 'goods://', hostname asString, ':', port asString
|
|
53 |
!
|
|
54 |
|
|
55 |
host: aString
|
|
56 |
hostname _ aString
|
|
57 |
!
|
|
58 |
|
|
59 |
morphicOpen: aWorkingCopy
|
|
60 |
(MCRepositoryInspector repository: self workingCopy: aWorkingCopy) show
|
|
61 |
!
|
|
62 |
|
|
63 |
packages
|
|
64 |
^ (self root collect: [:ea | ea package]) asSet asSortedCollection
|
|
65 |
!
|
|
66 |
|
|
67 |
port: aNumber
|
|
68 |
port _ aNumber
|
|
69 |
!
|
|
70 |
|
|
71 |
root
|
|
72 |
self db root ifNil: [self db root: Dictionary new].
|
|
73 |
^ self db root
|
|
74 |
!
|
|
75 |
|
|
76 |
versionWithInfo: aVersionInfo ifAbsent: errorBlock
|
|
77 |
^ self root at: aVersionInfo ifAbsent: errorBlock
|
|
78 |
!
|
|
79 |
|
|
80 |
versionsAvailableForPackage: aPackage
|
|
81 |
^ self root asArray select: [:ea | ea package = aPackage] thenCollect: [:ea | ea info]
|
|
82 |
! !
|
|
83 |
|
|
84 |
!MCGOODSRepository class methodsFor:'documentation'!
|
|
85 |
|
|
86 |
version
|
|
87 |
^ '$Header: /cvs/stx/stx/goodies/monticello/MCGOODSRepository.st,v 1.1 2006-11-22 13:22:33 cg Exp $'
|
|
88 |
! !
|