[kepler-dev] getting links from a compositeEntity

Edward A. Lee eal at eecs.berkeley.edu
Thu Feb 16 20:17:07 PST 2006


CompositeEntity.exportFilter(int, Collection) takes a filter
argument so that it will return only links involving in the filter...

Edward

At 11:16 AM 2/16/2006, Chad Berkley wrote:
>I've got the relation objects, but what I'm trying to get at is the 
><link> moml elements.  When I call exportMoML() on a 
>ComponentRelation, I get something like this:
><relation name="relation" class="ptolemy.actor.TypedIORelation">
>
>I want that but also the <link> elements that tell what the relation 
>is linked to.  Do I have to go through the port list to get 
>these?  How do I get the links to serialize.
>
>thanks,
>chad
>
>Edward A. Lee wrote:
>>Links are not objects in the Ptolemy II abstract syntax.
>>Relations are objects...
>>Relations contain a list of references to ports that they
>>are linked to, and the ports contain a list of the relations
>>that they are linked to.
>>Edward
>>At 02:25 PM 2/15/2006, Chad Berkley wrote:
>>
>>>Hi,
>>>
>>>I'm trying to find a programatic way to access the links that are
>>>contained in a composite.  The only method I see that kind of does this
>>>is CompositeEntity.exportLinks() which just returns a string moml
>>>description of the links, but no objects.  Is there a way to get an
>>>object representation of links?
>>>
>>>thanks,
>>>chad
>>>_______________________________________________
>>>Kepler-dev mailing list
>>>Kepler-dev at ecoinformatics.org
>>>http://mercury.nceas.ucsb.edu/ecoinformatics/mailman/listinfo/kepler-dev
>>
>>------------
>>Edward A. Lee
>>Professor, Chair of the EE Division, Associate Chair of EECS
>>231 Cory Hall, UC Berkeley, Berkeley, CA 94720
>>phone: 510-642-0253 or 510-642-0455, fax: 510-642-2845
>>eal at eecs.Berkeley.EDU, http://ptolemy.eecs.berkeley.edu/~eal
>>----------------------------------------------------------------------------
>>Posted to the ptolemy-hackers mailing list.  Please send administrative
>>mail for this list to: ptolemy-hackers-request at ptolemy.eecs.berkeley.edu

------------
Edward A. Lee
Professor, Chair of the EE Division, Associate Chair of EECS
231 Cory Hall, UC Berkeley, Berkeley, CA 94720
phone: 510-642-0253 or 510-642-0455, fax: 510-642-2845
eal at eecs.Berkeley.EDU, http://ptolemy.eecs.berkeley.edu/~eal  



More information about the Kepler-dev mailing list