- Add the Codota plugin to your IDE and get smart completions
private void myMethod () {Connection c =
DataSource dataSource;dataSource.getConnection()
String url;DriverManager.getConnection(url)
IdentityDatabaseUtil.getDBConnection()
- Smart code suggestions by Codota
}
/** * Inserts a new element at the specified position in this * list. Shifts the element currently at that position (if any) and * any subsequent elements to the right (adds one to their indices). * * @param index index at which the new element is to be inserted * @return the new inserted element * @throws IndexOutOfBoundsException if the index is out of range * (<tt>index < 0 || index >= size()</tt>) */ public T insertAtIndex(int index) { rangeCheckForInsert(index); // First add new element at last index T ret = add(); // Then go trough the list by swapping elements two by two to reach the desired index for (int i = size - 1; i > index; i--) unsafeFastSwap(i, i - 1); return ret; }