• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: [ANN] ModuleLoader 2.2.1
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ANN] ModuleLoader 2.2.1


  • Subject: Re: [ANN] ModuleLoader 2.2.1
  • From: Tetsuro KURITA <email@hidden>
  • Date: Sat, 21 Aug 2010 11:39:38 +0900

It is possible to force a running stay-open applet to reload modules.

Implement a handler to reload modules like this :

== Stay open-applet

property ModuleA : module -- place where ModuleA is loaded in.
property loader : missing value

on run
 set loader to boot (module loader) for me -- load modules at first-run
end

on idle
 -- do something
end

on reload_modules() -- handler to relaod modules
  boot loader for me
end


And call reload_modules() from external applescript like this :

tell application "RunningApplet"
  reload_modules()
end

Is this an answer you wanted ?
If above solution meets your requirements, I will add this into the manual.

=======================================================
 Tetsuro KURITA
  E-mail: email@hidden
  http://homepage.mac.com/tkurita/scriptfactory/en/
=======================================================


On 2010/08/20, at 19:06, Richard Lake wrote:

> I couldn't find my answer in the FAQs so perhaps someone can answer it here.
>
> I have a Stay Open application that at first-run loads various scripts.
>
> I doubt you can do this without checking periodically within the script, but is it possible somehow to force a running script to re-load any script (a dependancy) that it relies on the instant that is it altered?
>
> Is that sort of operability possible in the applescript environment?  I suspect not.
>
> On 19 Aug 2010, at 16:41, Tetsuro KURITA wrote:
>
>> ModuleLoader is a system for loading and managing AppleScript libraries(modules).
>>
>> http://homepage.mac.com/tkurita/scriptfactory/en/XModules/index.html#ModuleLoader
>> AppleScript's "load script" command requires a full path to a library file, which can be difficult to manage and makes distribution, installation and use of AppleScript libraries problematic.
>>
>> ModuleLoader introduces a modern module system for AppleScript. You can
>> load and manage modules with minimum efforts like other scripting language
>> (e.g. Perl, Ruby).
>>
>> Some examples :
>>
>> == A top level script
>>
>> property Module1 : module
>> property loader : boot (module loader) for me
>>
>> == A module which depends on other modules.
>>
>> property Module2 : module
>>
>> -------------------------------------------------
>>
>> The "module" command in the property definition mark the property as a place
>> where a module is loaded into. "boot (module loader) for me" statement cause
>> actual loading modules and set the modules to the specified properties.
>>
>> I believe ModuleLoader could be the best solution for a module loading system
>> of AppleScript. Please check details of ModuleLoader with the manual.
>>
>> Changes in version 2.2.1 :
>>
>> * Fixed an error of a local loader on Mac OS X 10.6 (Thanks to hiRaoka-san).
>> * Improved English manual (Thanks to Ed Stockly).
>>
>> I welcome any comments, suggestions and questions, even if it's negative.
>>
>> =======================================================
>> Tetsuro KURITA
>> E-mail: email@hidden
>> http://homepage.mac.com/tkurita/scriptfactory/en/
>> =======================================================
>>
>> _______________________________________________
>> Do not post admin requests to the list. They will be ignored.
>> AppleScript-Users mailing list      (email@hidden)
>> Help/Unsubscribe/Update your Subscription:
>> Archives: http://lists.apple.com/archives/applescript-users
>>
>> This email sent to email@hidden
>> _______________________________________________
>> Do not post admin requests to the list. They will be ignored.
>> AppleScript-Users mailing list      (email@hidden)
>> Help/Unsubscribe/Update your Subscription:
>> Archives: http://lists.apple.com/archives/applescript-users
>>
>> This email sent to email@hidden
>
> Thanks
>
> Richard Lake
> Marketing Manager
>
> Tel: 0800 158 3898 | Email: email@hidden
>

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

References: 
 >[ANN] ModuleLoader 2.2.1 (From: Tetsuro KURITA <email@hidden>)
 >Re: [ANN] ModuleLoader 2.2.1 (From: Richard Lake <email@hidden>)

  • Prev by Date: Re: Daylight Savings Time
  • Next by Date: Re: Remember Finder windows left open at shutdown
  • Previous by thread: Re: [ANN] ModuleLoader 2.2.1
  • Next by thread: InDesign transformation
  • Index(es):
    • Date
    • Thread