swarm-support
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Dropping or cleaning a schedule


From: Paul Johnson
Subject: Re: Dropping or cleaning a schedule
Date: Sat, 28 Jun 1997 11:03:03 -0500 ()

I was studying the code that Roger attached below and it occurred to me
I still don't understand the fundamental structure of SWARM.  I've been
studying the objective-C book and various snippits I find in the internet,
but I need a little help.  Here it is:

Does anyone have (or is there available, possibly in the mailing list
archive where I can't find it) a glossary of SWARM objects, which library
they are housed in, and how they are used, and what for?  I've found the
swarmdocs, of course, and I've studied a bit about defobj and the others. 
But I feel like a heat bug, poking at random directions in the dark,
without a MAP or SCHEDULE.  I understand I can screw around with
Hello.world and the tutorial, and I have, but I still have this unhappy
feeling of wandering in n-space.

I imagine you have all been through this before?  Just tell me the month
and I'll check the archive.

If there is no such thing, well, pooh!  There's no reason every new user
should have to inductively develop a personal model of the framework. And once
I do understnad it, you better watch out for an "idiot's guide to swarm" from
me!  I'll be famous:)

Paul E. Johnson                           address@hidden
Dept. of Political Science                Office: (913) 864-9086
University of Kansas                      FAX: (913) 864-5700
Lawrence, Kansas 66045                    Home: (913) 842-9916                  
   

On Fri, 27 Jun 1997, Roger M. Burkhart wrote:

> Rob Kewley writes:
> 
> > I am still having some trouble with a dynamic schedule in my model.

> Roger Burkhart
> --
> // code fragments to test reactivation of a dynamic schedule
> 
> static void reactivateFunction( id swarm, id dynamicSchedule );
> static void terminateFunction( void );
> 
> void testDynamicSchedule(void)
> {
>   id  aZone, controlSchedule, dynamicSchedule;
>   id  swarm, swarmActivity;
> 
>   aZone = [Zone create: globalZone];
>   swarm = [SwarmProcess create: aZone];
>   _activity_zone = [Zone create: globalZone];
> 
>   dynamicSchedule = [Schedule createBegin: swarm];
>   [dynamicSchedule setAutoDrop: 1];
>   dynamicSchedule = [dynamicSchedule createEnd];
> 
>   controlSchedule = [Schedule create: swarm];
>   [controlSchedule at: 2 createActionCall: (func_t)reactivateFunction
>                    : swarm : dynamicSchedule];
>   [controlSchedule at: 4 createActionCall: terminateFunction];
> 
>   swarmActivity = [swarm activate];
>   [swarm activate: controlSchedule];
>   [swarm activate: dynamicSchedule];
> 
>   [dynamicSchedule at: 1 createActionCall: (func_t)printf :
>     (id)"first scheduled action performed\n"];
> 
>   [swarmActivity run];
> }
> 
> static void reactivateFunction( id swarm, id dynamicSchedule )
> {
>   [dynamicSchedule at: 3 createActionCall: (func_t)printf :
>     (id)"second scheduled action performed\n"];
>   [dynamicSchedule activateIn: swarm];
> }
> 
> static void terminateFunction( void )
> {
>   [getTopLevelActivity() terminate];
> }
> 
> 
>                   ==================================
>    Swarm-Support is for discussion of the technical details of the day
>    to day usage of Swarm.  For list administration needs (esp.
>    [un]subscribing), please send a message to <address@hidden>
>    with "help" in the body of the message.
>                   ==================================
> 


                  ==================================
   Swarm-Support is for discussion of the technical details of the day
   to day usage of Swarm.  For list administration needs (esp.
   [un]subscribing), please send a message to <address@hidden>
   with "help" in the body of the message.
                  ==================================


reply via email to

[Prev in Thread] Current Thread [Next in Thread]