links to this page:    
View this PageEdit this PageUploads to this PageHistory of this PageTop of the SwikiRecent ChangesSearch the SwikiHelp Guide
Last updated at 3:06 pm UTC on 30 March 2017
Check needed.


The Squeak image is a file which is an exact copy of the Squeak memory content with all class definitions and objects.

(Is this definiton correct? Almost. Objects that depend on operating system resources may tweak their image saving/loading. For example, a network socket definitely won't exist when you reload an image, so mumble mumble happens.)

This image of objects runs on top of a Virtual Machine. The image is a platform-independent file. In other words, the exact same image file can run on a Windows/Mac/Unix/etc platform, as long as the appropriate virtual machine for the platform is used.

The image does not contain the source code for the system, however. The source code is stored in the .sources file and the .changes file.

Where in the code is the image saved and loaded?

When the user selects 'save' or 'save and quit' from the World menu, then
 Smalltalk snapshot: true andQuit: false
 Smalltalk snapshot: true andQuit: true
is called. This saves the image file.

Actually the method #snapshot:andQuit:embedded: is called and there the primitive #snapshotPrimitive or snapshotEmbeddedPrimitive do the actual work of writing the image. When quiting the program execution stops in this method and when starting it resumes right at the point where it stopped, so actually the second part of #snapshot:andQuit:embedded: is the startup procedure for Squeak.

Also see The Squeak Image