1 19 20 package org.apache.avalon.excalibur.datasource.cluster; 21 22 import java.sql.Connection ; 23 import java.sql.SQLException ; 24 25 import org.apache.avalon.excalibur.datasource.DataSourceComponent; 26 27 32 public interface HashedDataSourceCluster 33 extends DataSourceComponent 34 { 35 38 String ROLE = HashedDataSourceCluster.class.getName(); 39 40 45 int getClusterSize(); 46 47 59 Connection getConnectionForHashObject( Object hashObject ) throws SQLException ; 60 61 73 Connection getConnectionForHashCode( int hashCode ) throws SQLException ; 74 75 86 Connection getConnectionForIndex( int index ) throws SQLException ; 87 88 95 int getIndexForHashObject( Object hashObject ); 96 97 104 int getIndexForHashCode( int hashCode ); 105 } 106 107 | Popular Tags |