v4.0
// This example illustrates how to access the ports collection
// while browsing the built operator.
var op = XSIFactory.CreateObjectFromPreset( "Loft", "Operators" );
var ePortGroups = new Enumerator(op.portgroups);
for ( ; ! ePortGroups.atEnd(); ePortGroups.moveNext() )
{
var portgroup = ePortGroups.item();
logmessage( "portgroup: " + portgroup.name );
var ePorts = new Enumerator(portgroup.ports);
for ( ; ! ePorts.atEnd(); ePorts.moveNext() )
{
var port = ePorts.item();
logmessage( "port: " + port.name );
}
} |