Java Code Examples for javax.sql.PooledConnection#toString()

The following examples show how to use javax.sql.PooledConnection#toString() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: J2EEDataSourceTest.java    From gemfirexd-oss with Apache License 2.0 5 votes vote down vote up
/** 
 * Check the format of a pooled connection
 **/
private static void assertStringFormat(PooledConnection pc) throws Exception
{
    String prefix = assertStringPrefix(pc);
    String connstr = pc.toString();
    String format = prefix + " \\(ID = [0-9]+\\), Physical Connection = " +
        "<none>|" + CONNSTRING_FORMAT;
    assertTrue(connstr.matches(format));
}
 
Example 2
Source File: J2EEDataSourceTest.java    From gemfirexd-oss with Apache License 2.0 5 votes vote down vote up
/** 
 * Check the format of a pooled connection
 **/
private static void assertStringFormat(PooledConnection pc) throws Exception
{
    String prefix = assertStringPrefix(pc);
    String connstr = pc.toString();
    String format = prefix + " \\(ID = [0-9]+\\), Physical Connection = " +
        "<none>|" + CONNSTRING_FORMAT;
    assertTrue(connstr.matches(format));
}
 
Example 3
Source File: J2EEDataSourceTest.java    From spliceengine with GNU Affero General Public License v3.0 5 votes vote down vote up
/**
 * Check the format of a pooled connection
 **/
private static void assertStringFormat(PooledConnection pc) throws Exception
{
    String prefix = assertStringPrefix(pc);
    String connstr = pc.toString();
    String format = prefix + " \\(ID = [0-9]+\\), Physical Connection = " +
            "<none>|" + CONNSTRING_FORMAT;
    assertTrue(connstr.matches(format));
}