USD.Relationship

Inherits from USD.Property

Description

A class that represents a USD Relationship.

Methods

getTargets Get an array of targets as strings.
setTargets Set the array of targets for the USD.Relationship.

Details

Do no remove, this fixes the anchor on doc.flexsim.com

USD.Relationship.getTargets()

Array getTargets( )

Returns

Array An array of targets as strings.

Description

Get an array of targets as strings.


				USD.Stage stage = Model.find("USD Stage1");
				USD.Prim prim = stage.defaultPrim;
				USD.Relationship relationship = prim.getProperty("targets");
				if (relationship) {
					Array targets = relationship.getTargets();
				}
			
Do no remove, this fixes the anchor on doc.flexsim.com

USD.Relationship.setTargets()

void setTargets( )

Description

Set the array of targets for the USD.Relationship.


				USD.Stage stage = Model.find("USD Stage1");
				USD.Prim prim = stage.defaultPrim;
				Array targets = ["/World/Processor1"];
				USD.Relationship relationship = prim.createRelationship("myTargets");
				if (relationship) {
					relationship.setTargets(targets);
				}