public void addConnection(Connection conn){
  int position=findPositionForConnection(conn);
  if (position < mConnections.size() && conn == mConnections.get(position)) {
    throw new IllegalArgumentException("Already added.");
  }
  mConnections.add(position,conn);
}

public void addConnection ( Connection conn ) { int position = findPositionForConnection ( conn ) ; if ( position < mConnections . size ( ) && conn == mConnections . get ( position ) ) { throw new IllegalArgumentException ( "Already added." ) ; } mConnections . add ( position , conn ) ; }
insert the given connection into this list .
