MinneStore Version 2.03 for Visual Works 3.0 NC
MinneStore Version 2.03 Copyright © 1997, 1998 by Jonathan Carlson
-------------------------------------------------------------------
MinneStore Version 2.03 for Visual Works 3.0 NC
Porting Version 1.2
Copyright © 1999 by Giovanni Giorgi
***Note: This porting is *freeware*, but Giovanni Giorgi owns the copyright.
See License.txt for more details.
If you modify it (and I hope you let me know about bugs) you should keep track
of your changes and send back the code to me for a new release!!
Document created 5 January 1999
Last Update:13 March 1999
Introduction
This document has been created and updated by Giovanni Giorgi (gg482344@silab.dsi.unimi.it
or giorgi_g@geocities.com) and will provide information on the porting
for VW 3.0
The Porting is done thinking of Unix/Mac/Os2 Users too, so MinneStore
will use the right directory delimiter under every OS. I tried the code
under Linux and it is very very fast compared to the Windows95 Virtual
Machine of Visualworks 3.0
The original code is CR-LF delimited, but this isn't a problem for use.
Look at www.objectshare.com
for downloading a free non-commercial
version of VisualWorks 3.0
You should read this at least until you hit the "Additional information
for the porting" part.
I hope that all will work, but if problems occurs, feel free to e-mail
to me.
Index
-
Installing on VW 3.0 NC
-
Installing on VW 2.5.x
-
How To Update MinneStore
-
Additional information
-
Debugging the propertyAt:..
methods
-
Next Relase?
Installing on VW 3.0 NC
Copy the two files MinneStore.pcl & MinneStore.pst in visualworks_home\image
or in
visualworks_home\parcels.
Simply load the parce!
To do this launch VW and select the menu Tools/Load Parcel Named...
inserting MinneStore at the prompt.
Installing on VW 2.5.x
Note: I do not even have the VW 2.5, so I *cannot test* this procedure,
but it should work.
Maybe the Exception-porting can NOT work, so someone may want to modify it
and send it back to me?
First of ALL evaluate:
Smalltalk at:#MinneStorePropertyDB put: (WeakDictionary new: 100).
This will add a small class to the system. File-in the code in the vw2.5porting.st
file using the menu item Tools/File list.
Try the database:
MSExample ExampleCode
VW 2.5.x Warning:
This code modify deeply your image, so install
it in a fresh image or integrate (file-in) in a parcel. The VW 3.0 Parcel
engine fix some problems the VW 2.5.x system has
Uninstalling on VW 3.0 NC
Don't worry if the first time you try to unload the parcel an error
occur. Click Terminate on the error box, and re-do the unload action. All
will work. This problem isn't so easy to fix for the moment!!
Report of TestSuite:
TestSuite runCompatibilityTest. "Ok 99%"
Only one line failed, but is ok for most uses. I changed that method
in CompatibilityTesting>>testFileProtocol
Look at FlavorCompatibility class>>createLockFile: aString ifExists:
aBlock
TestSuite runDiskObjectServiceTest. "OK"
TestSuite runMinneStoreTest1 "OK"
TestSuite runMinneStoreTest2. "OK"
TestSuite runMinneStoreTest3. "OK"
TestSuite runMinneStoreTest4. "OK"
No important errors remains and it works at 95-100%
How To Update MinneStore
Example:
Suppose you downloaded the file MinneStore.st of version 3.0 of MinneStore
and you want to update it. It is very easy:
-
Copy the MinneStore.st in the visualworks_home\image directory
-
Launch VW, then open parcel browse, select MinneStone parcel and click
with the right mouse button on it.
-
Select build/addFileIn and file in the MinneStore.st file.
-
Save the MinneStore parcel.
-
Plan a small journey to Milan (Italy), my city :)
Additional information for the porting.
(if you are tired you can stop reading :)
All code modified by me has a comment with a "GG" string in it. In some
cases I left original code fragments as comments. Maybe some (very
little) comments are in Italian, but I promise to translate it in the next
release (yip don't you like this language?...:).
Most (but not all) of the code modified is in the "MinneStore-GG-Patch"
category. I must supply a new class called File. This isn't so elegant,
because this class name is too common and it isn't part of standard VW
library.
I try to modify less possible the MinneStore
Code, for avoiding putting some bugs in it!!
Worst Problems fixed:
-
The propertyAt: & so on methods aren't implemented in VW so I must
create a workaround. The problem is this: I cannot add a instance variable
to Object (it prints out "cannot make a byte subclass....") so I build
Global Variable with the information needed. The variable name is
MinneStorePropertyDB and I take care of right initialisation/release using
the Parcel pre-load action & post-unload action. This is quite elegant
in VW 3.0, but cannot be done in VW 2.0 :(
Note: The infos in MinneStorePropertyDB AREN'T SAVED in the objects
itself when serialaized to files (=database do not record it?). This is
NOT a problem for MinneStore, but if some memory is retained in the MinneStorePropertyDB
you can do, ONLY when DB ARE NOT OPENED!!, this action: FlavorCompatibility
clearMemory. to clear the Propery Dictionary and save a bit of space! Because
all tests succesfully passed, the semantics is saved.
-
A lot of problems TOO derive from file model, but have been fixed in a
good way. The MSExample will work fine and the Exception engine is working
in the right way.
Minor Changes (in order of importance)
-
The Exception porting seems work, but I'd like a bit of testing about it.
E-mail me if some problems occurs! I don't know if my porting is compliance
with new exception model of VW (this would be a problem for the VW 2.5.x
relase but we must be compliant because the next version of VW will not
support the old model).
-
In MSNilValue I added the method "lessFromInteger:" and it seems work right.
I do the porting in 4 days, and I review my changes in about 10 days. The
original code has been taken from the VisualSmalltalk porting (I think
it should be the best thing to do).
Improvements
-
The speed is a major problem. I will try to speed-up the code in the next
relase, reducing the message needed for having a object property or for
creating a lock file.
-
One thing is very strange: the code in FlavorCompatibility>>clone:
anObject message can be replaced with a simple line like anObject
copy ? I don't think is possibile but what is the reason? This would
improve performance a little.
-
Most classes have comments as a Comment method in the class. I'd like to
build a small program for copying this comments but I have no time... Does someone
want to help me?.....
Debugging the propertyAt:..
methods
Only for debugging purpose you can use:
Object debugPropertyEngine
For destroying the PropertyDB WHEN DB ARE
CLOSED use:
FlavorCompatibility clearMemory.
Next Relase?
The next relase of this porting is planned in middle 1999 for having compatibility
with the VW-5.0 if I can get a beta copy of it. ENJOY!!
// Giovanni Giorgi e-mail: daitangio@tin.it --- gg482344@silab.dsi.unimi.it
// (ex)Tutor at Depart. of Information Technology of Milan, Italy
// http://www.geocities.com/CapeCanaveral/Hall/7276/
// http://www.silab.dsi.unimi.it/~gg482344/tutor/tutor.htm