Class AbstractConnectable

java.lang.Object
org.refcodes.component.AbstractConnectable
Direct Known Subclasses:
AbstractConnectableAutomaton

public class AbstractConnectable extends Object
The AbstractConnectable provides base functionality required by connection related components.
  • Constructor Details

    • AbstractConnectable

      public AbstractConnectable()
  • Method Details

    • isThrownAsOfAlreadyClosed

      protected static boolean isThrownAsOfAlreadyClosed(IOException aException)
      Tests whether the provided exception is thrown as of something already being closed. In some cases, when something is already closed and some (wrapper) method tries to close it (again), then no exception should be propagated. This is very implementation specific regarding the underlying JDK as we expect something like "Pipe closed", "Connection closed" or the like to be contained in the aMessage.
      Parameters:
      aException - The IOException to be tested.
      Returns:
      True in case we have an exception as of something to be closed was already caused, else false.