Quintiq file version 2.0 
 | 
#parent: #root 
 | 
StaticMethod GetDownstreamComponents (LibOpt_Component component, LibOpt_Components found) as LibOpt_Components 
 | 
{ 
 | 
  Description: 
 | 
  [* 
 | 
    Return a set containing the given component, all downstream components and all components in the found set. 
 | 
     
 | 
    A downstream component is any component that can be found by following the outgoing links starting at the given component. 
 | 
     
 | 
    The found set may not be null. 
 | 
  *] 
 | 
  TextBody: 
 | 
  [* 
 | 
    if( found.Find( component ) < 0 ) 
 | 
    { 
 | 
      found.Add( component ); 
 | 
       
 | 
      traverse( component.GetOutgoingLinks(), Elements, link ) 
 | 
      { 
 | 
        found := LibOpt_Utility::GetDownstreamComponents( link.Destination(), found ); 
 | 
      } 
 | 
    } 
 | 
     
 | 
    return found; 
 | 
  *] 
 | 
  InterfaceProperties { Accessibility: 'Module' } 
 | 
} 
 |