What about storing the Connector instance created in the constructor and ask it here about the port instead of iterating over all connectors?