Class Connectors


  • public class Connectors
    extends java.lang.Object
    Convenient static methods to work with Connector.
    • Constructor Detail

      • Connectors

        public Connectors()
    • Method Detail

      • collectConnectors

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

        public static java.util.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
      • getFirstEnd

        @CheckForNull
        public static ConnectorEnd getFirstEnd​(Connector connector)
        Return a first connector end
        Parameters:
        connector - connector
        Returns:
        end
      • getSecondEnd

        @CheckForNull
        public static ConnectorEnd getSecondEnd​(Connector connector)
        Return a second connector end
        Parameters:
        connector - connector
        Returns:
        end
      • getOppositeEnd

        @CheckForNull
        public static ConnectorEnd getOppositeEnd​(ConnectorEnd end)
        Gets opposite connector end for a given connector end.
        Parameters:
        end - connector end for which to get opposite end
        Returns:
        opposite connector end for a given connector end