Class ConnectorsCollector

java.lang.Object
com.nomagic.magicdraw.uml.ConnectorsCollector

@OpenApiAll public class ConnectorsCollector extends Object
An utility class to collect Connectors connected to some Element. Collects direct Connectors(connected directly to an Element) or indirect Connectors (connected though some Port)
  • Constructor Details

    • ConnectorsCollector

      public ConnectorsCollector()
  • Method Details

    • collectConnectors

      public static Collection<Connector> collectConnectors(ConnectableElement element)
      Collects direct and indirect Connectors
      Parameters:
      element - element
      Returns:
      direct and indirect Connectors
    • collectDirectConnectors

      public static Collection<Connector> collectDirectConnectors(ConnectableElement element)
      Collects only direct Connectors
      Parameters:
      element - element
      Returns:
      direct Connectors
    • getPort

      @CheckForNull public static Port getPort(Connector connector, Property property)
      Looks for a Port which is used to connect Connector on the given Property
      Parameters:
      connector - connector
      property - property
      Returns:
      a port on Property used to connect given Connector