No, I wasn't referring to actors written in Java. I was referring to composite actors that are themselves class definitions. It appears that Kepler does not expose this capability in the GUI (the commands aren't there to convert a composite actor to a class nor to instantiate classes). So what you have in your example is a _copy_ of the composite actor. Hence, updates to the original have no effect on the copy.
The mechanism I'm referring to is that a composite actor may define a _class_, and you can then have multiple instances of the class. You can also have subclasses that override certain aspects. If someone is interested in making this capability available in Kepler, it would be great. I think it's mostly a matter of adding it to the menu commands. There is a paper on this mechanism here: http://ptolemy.eecs.berkeley.edu/publications/papers/07/classesandInheritance/index.htm There are demos in the Ptolemy tree here: $PTII/ptolemy/configs/doc/ClassesIllustrated.xml $PTII/ptolemy/domains/sdf/demo/NoisySinewave/NoisySinewave.xml $PTII/ptolemy/domains/sdf/demo/RijndaelEncryption/RijndaelEncryption.xml Edward On 12/10/12 3:56 PM, Alvin Sebastian wrote:
I am also interested to know the details behind this problem. What Edward referred as base classes and sub classes apply only to Java codes, where you have to write and compile an actor in Java. I believe the type of “base” actor that you described is called a composite actor/workflow. Is it possible to share the same instance of a composite actor among multiple workflows? I know that besides dragging an existing kar from the panel as described by Ian, you can also use an actor called CompositeActor. Are there any other methods to use a composite actor? Alvin *From:*[email protected] [mailto:[email protected]] *On Behalf Of *Ian Szarka *Sent:* Tuesday, 11 December 2012 9:25 AM *To:* '[email protected]' *Subject:* Re: [kepler-users] Kepler-users Digest, Vol 91, Issue 3 Hi Edward , thank you for the reply. Where can I find the "Open Instance" option? Only "Open Actor" appears in context or any other menu, see picture, if it is not scrubbed. Example attached, details also written below. I have tried a new scenario from scratch which results in the same problem, Ie changes not propagating. It appears that actors are just getting plain copied into workflows that use them. Thank you for your attention, Ian. Steps to create problem: -I made a simple work flow “A”, return a string -Saved the .kar for A in the MyWorkflows directory, and closed Kepler -Relaunched Kepler, -Made a second work flow “B” dragging actor A from the components panel -Ran B, verified expected result -Saved B to desktop and closed Kepler. -Relaunched Kepler -Opened actor A and modified string -Saved A, and closed Kepler -Relaunched Kepler, opened B -Ran B, received previous result – the first string and not the updated string -Opened the A actor located on the canvas of B – it had the previous string -Opened the file A in the MyWorkflows directory – it had the update string. -----Original Message----- From: [email protected] <mailto:[email protected]> [mailto:[email protected]] On Behalf Of [email protected] <mailto:[email protected]> Sent: Friday, 7 December 2012 7:00 AM To: [email protected] <mailto:[email protected]> Subject: Kepler-users Digest, Vol 91, Issue 3 Send Kepler-users mailing list submissions to [email protected] <mailto:[email protected]> To subscribe or unsubscribe via the World Wide Web, visit http://lists.nceas.ucsb.edu/kepler/mailman/listinfo/kepler-users or, via email, send a message with subject or body 'help' to [email protected] <mailto:[email protected]> You can reach the person managing the list at [email protected] <mailto:[email protected]> When replying, please edit your Subject line so it is more specific than "Re: Contents of Kepler-users digest..." Today's Topics: 1. Re: I need help making modular actors please. (Edward A. Lee) ---------------------------------------------------------------------- Message: 1 Date: Wed, 05 Dec 2012 18:13:15 -0800 From: "Edward A. Lee" <[email protected] <mailto:[email protected]>> To: Ian Szarka <[email protected] <mailto:[email protected]>> Cc: "'[email protected]'" <[email protected] <mailto:[email protected]>> Subject: Re: [kepler-users] I need help making modular actors please. Message-ID: <[email protected] <mailto:[email protected]>> Content-Type: text/plain; charset="windows-1252"; Format="flowed" Changes to base classes should propagate to instances or subclasses, unless the instances or subclasses override the base classes somehow. perhaps that is what is happening? If you select "Open instance" instead of "Open actor" you can see what is an override vs. what is inherited from the base class. An example would help... Edward On 12/4/12 5:12 PM, Ian Szarka wrote: > Hi all. > > I am after advise about making modular actors. Please respond. > > I am developing a library of actors, currently I have 20 user actors - > many of which do similar things. I have built the actors in a modular > way with common functions in a handful of base actors. A few times I > have found bugs or need to change base functionality used in all of > the user actors. > > I have put base actors in the > ?C:\Users\Ian\KeplerData\workflows\MyWorkflows? folder and built the > composite user actors using them. However I have found that changes to > the base actors do not propagate to the user actors. > > Currently I am opening each user actor and making the same change for > the base actor 20 times! > > How can I do this so that functionality in base actors is correctly > used by other actors. > > Please help, I am after advise. > > Regards > > Ian. > > > > _______________________________________________ > Kepler-users mailing list > [email protected] <mailto:[email protected]> > http://lists.nceas.ucsb.edu/kepler/mailman/listinfo/kepler-users > -------------- next part -------------- A non-text attachment was scrubbed... Name: eal.vcf Type: text/x-vcard Size: 330 bytes Desc: not available URL: <http://lists.nceas.ucsb.edu/kepler/pipermail/kepler-users/attachments/20121205/18d46129/attachment-0001.vcf> ------------------------------ _______________________________________________ Kepler-users mailing list [email protected] <mailto:[email protected]> http://lists.nceas.ucsb.edu/kepler/mailman/listinfo/kepler-users End of Kepler-users Digest, Vol 91, Issue 3 ******************************************* _______________________________________________ Kepler-users mailing list [email protected] http://lists.nceas.ucsb.edu/kepler/mailman/listinfo/kepler-users
<<attachment: eal.vcf>>
_______________________________________________ Kepler-users mailing list [email protected] http://lists.nceas.ucsb.edu/kepler/mailman/listinfo/kepler-users

