[squeak-dev] Copying a file from Squeak on Linux
Bert Freudenberg
bert at freudenbergs.de
Mon Mar 3 11:19:44 UTC 2008
On Mar 3, 2008, at 3:37 , David T. Lewis wrote:
> On Sun, Mar 02, 2008 at 05:49:54PM -0500, Bill Schwab wrote:
>>
>> The copy plugin appears not to be in my VM. To be safe though, how
>> would I test that? So far, all I have found is to call a function in
>> the plugin, which could fail for various reasons besides the code not
>> being present.
>
> Bill,
>
> If you call the file copy primitive, it will try to load the plugin.
> The #listLoadedModules method will show you the loaded plugins, hence:
>
> FileList new primitiveCopyFileNamed: 'foo' to: 'bar'.
> SmalltalkImage current listLoadedModules
> detect: [:plugin | 'FileCopyPlugin*' match: plugin]
> ifNone: ['the FileCopyPlugin is not installed']
>
Also, #listBuiltinModules will list the plugins compiled into the VM.
There is no similar call for external plugins, but these you can see
in the files system yourself.
- Bert -
More information about the Squeak-dev
mailing list
|