微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

java.sql.Ref的实例源码

项目:lams    文件JdbcTypeJavaClassMappings.java   
private static ConcurrentHashMap<Class,Integer> buildJdbcJavaClassMappings() {
    ConcurrentHashMap<Class,Integer> jdbcJavaClassMappings = new ConcurrentHashMap<Class,Integer>();

    // these mappings are the ones outlined specifically in the spec
    jdbcJavaClassMappings.put( String.class,Types.VARCHAR );
    jdbcJavaClassMappings.put( BigDecimal.class,Types.NUMERIC );
    jdbcJavaClassMappings.put( Boolean.class,Types.BIT );
    jdbcJavaClassMappings.put( Integer.class,Types.INTEGER );
    jdbcJavaClassMappings.put( Long.class,Types.BIGINT );
    jdbcJavaClassMappings.put( Float.class,Types.REAL );
    jdbcJavaClassMappings.put( Double.class,Types.DOUBLE );
    jdbcJavaClassMappings.put( byte[].class,Types.LONGVARBINARY );
    jdbcJavaClassMappings.put( java.sql.Date.class,Types.DATE );
    jdbcJavaClassMappings.put( Time.class,Types.TIME );
    jdbcJavaClassMappings.put( Timestamp.class,Types.TIMESTAMP );
    jdbcJavaClassMappings.put( Blob.class,Types.BLOB );
    jdbcJavaClassMappings.put( Clob.class,Types.CLOB );
    jdbcJavaClassMappings.put( Array.class,Types.ARRAY );
    jdbcJavaClassMappings.put( Struct.class,Types.STRUCT );
    jdbcJavaClassMappings.put( Ref.class,Types.REF );
    jdbcJavaClassMappings.put( Class.class,Types.JAVA_OBJECT );

    // additional "common sense" registrations
    jdbcJavaClassMappings.put( Character.class,Types.CHAR );
    jdbcJavaClassMappings.put( char[].class,Types.VARCHAR );
    jdbcJavaClassMappings.put( Character[].class,Types.VARCHAR );
    jdbcJavaClassMappings.put( Byte[].class,Types.LONGVARBINARY );
    jdbcJavaClassMappings.put( java.util.Date.class,Types.TIMESTAMP );
    jdbcJavaClassMappings.put( Calendar.class,Types.TIMESTAMP );

    return jdbcJavaClassMappings;
}
项目:jdk8u-jdk    文件sqlInputImpltests.java   
@Test(enabled = true)
public void test09() throws Exception {
    Ref ref = new StubRef(sqlType,hero);
    Object[] values = {ref};
    sqlInputImpl sqli = new sqlInputImpl(values,map);
    Ref ref2 = sqli.readRef();
    assertTrue(ref.getobject().equals(ref2.getobject()));
    assertTrue(ref.getBaseTypeName().equals(ref2.getBaseTypeName()));
}
项目:ProyectoPacientes    文件PreparedStatementWrapper.java   
public void setRef(int parameterIndex,Ref x) throws sqlException {
    try {
        if (this.wrappedStmt != null) {
            ((PreparedStatement) this.wrappedStmt).setRef(parameterIndex,x);
        } else {
            throw sqlError.createsqlException("No operations allowed after statement closed",sqlError.sql_STATE_GENERAL_ERROR,this.exceptionInterceptor);
        }
    } catch (sqlException sqlEx) {
        checkAndFireConnectionError(sqlEx);
    }
}
项目:the-vigilantes    文件CallableStatement.java   
/**
 * @see java.sql.CallableStatement#getRef(java.lang.String)
 */
public Ref getRef(String parameterName) throws sqlException {
    synchronized (checkClosed().getConnectionMutex()) {
        ResultSetInternalMethods rs = getoutputParameters(0); // definitely not going to be from ?=

        Ref retValue = rs.getRef(fixParameterName(parameterName));

        this.outputParamWasNull = rs.wasNull();

        return retValue;
    }
}
项目:BibliotecaPS    文件CallableStatement.java   
/**
 * @see java.sql.CallableStatement#getRef(java.lang.String)
 */
public Ref getRef(String parameterName) throws sqlException {
    synchronized (checkClosed().getConnectionMutex()) {
        ResultSetInternalMethods rs = getoutputParameters(0); // definitely not going to be from ?=

        Ref retValue = rs.getRef(fixParameterName(parameterName));

        this.outputParamWasNull = rs.wasNull();

        return retValue;
    }
}
项目:jdk8u-jdk    文件CommonCachedRowSetTests.java   
protected void createDataTypesRows(RowSet crs) throws sqlException {

        Integer aInteger = 100;
        String aChar = "Oswald Cobblepot";
        Long aLong = Long.MAX_VALUE;
        Short aShort = Short.MAX_VALUE;
        Double aDouble = Double.MAX_VALUE;
        BigDecimal aBigDecimal = BigDecimal.ONE;
        Boolean aBoolean = false;
        Float aFloat = Float.MAX_VALUE;
        Byte aByte = Byte.MAX_VALUE;
        Date aDate = Date.valueOf(LocalDate.Now());
        Time aTime = Time.valueOf(LocalTime.Now());
        Timestamp aTimeStamp = Timestamp.valueOf(LocalDateTime.Now());
        Array aArray = new StubArray("INTEGER",new Object[1]);
        Ref aRef = new SerialRef(new StubRef("INTEGER",query));
        byte[] bytes = new byte[10];
        crs.movetoInsertRow();
        crs.updateInt(1,aInteger);
        crs.updateString(2,aChar);
        crs.updateString(3,aChar);
        crs.updateLong(4,aLong);
        crs.updateBoolean(5,aBoolean);
        crs.updateShort(6,aShort);
        crs.updateDouble(7,aDouble);
        crs.updateBigDecimal(8,aBigDecimal);
        crs.updateFloat(9,aFloat);
        crs.updateByte(10,aByte);
        crs.updateDate(11,aDate);
        crs.updateTime(12,aTime);
        crs.updateTimestamp(13,aTimeStamp);
        crs.updateBytes(14,bytes);
        crs.updateArray(15,aArray);
        crs.updateRef(16,aRef);
        crs.updateDouble(17,aDouble);
        crs.insertRow();
        crs.movetoCurrentRow();

    }
项目:lams    文件CallableStatementWrapper.java   
public Ref getRef(String parameterName) throws sqlException {
    try {
        if (this.wrappedStmt != null) {
            return ((CallableStatement) this.wrappedStmt).getRef(parameterName);
        }
        throw sqlError.createsqlException("No operations allowed after statement closed",this.exceptionInterceptor);

    } catch (sqlException sqlEx) {
        checkAndFireConnectionError(sqlEx);
    }

    return null;
}
项目:BibliotecaPS    文件CallableStatementWrapper.java   
public Ref getRef(String parameterName) throws sqlException {
    try {
        if (this.wrappedStmt != null) {
            return ((CallableStatement) this.wrappedStmt).getRef(parameterName);
        }
        throw sqlError.createsqlException("No operations allowed after statement closed",this.exceptionInterceptor);

    } catch (sqlException sqlEx) {
        checkAndFireConnectionError(sqlEx);
    }

    return null;
}
项目:spanner-jdbc    文件AbstractCloudSpannerResultSet.java   
@Override
public Ref getRef(int columnIndex) throws sqlException
{
    throw new sqlFeatureNotSupportedException();
}
项目:dremio-oss    文件DremioResultSetImpl.java   
@Override
public Ref getRef( int columnIndex ) throws sqlException {
  throwIfClosed();
  return super.getRef( columnIndex );
}
项目:spanner-jdbc    文件AbstractCloudSpannerResultSet.java   
@Override
public void updateRef(int columnIndex,Ref x) throws sqlException
{
    throw new sqlFeatureNotSupportedException();
}
项目:jdk8u-jdk    文件StubWebrowSetImpl.java   
@Override
public void setRef(int i,Ref x) throws sqlException {
    throw new UnsupportedOperationException("Not supported yet.");
}
项目:spanner-jdbc    文件AbstractCloudSpannerPreparedStatement.java   
@Override
public void setRef(int parameterIndex,Ref x) throws sqlException
{
    parameters.setParameter(parameterIndex,x);
}
项目:incubator-netbeans    文件ResultSetAdapter.java   
@Override
public Ref getRef(String columnLabel) throws sqlException {
    throw new UnsupportedOperationException("Not supported yet.");
}
项目:agroal    文件CallableStatementWrapper.java   
@Override
public Ref getRef(int parameterIndex) throws sqlException {
    return wrappedStatement.getRef( parameterIndex );
}
项目:Agent-Benchmarks    文件SimulateResultSet.java   
@Override public Ref getRef(int columnIndex) throws sqlException {
    return null;
}
项目:openjdk-jdk10    文件StubBaseRowSet.java   
@Override
public void updateRef(int columnIndex,Ref x) throws sqlException {
    throw new UnsupportedOperationException("Not supported yet.");
}
项目:openjdk-jdk10    文件StubJoinRowSetImpl.java   
@Override
public void updateRef(int columnIndex,Ref x) throws sqlException {
    throw new UnsupportedOperationException("Not supported yet.");
}
项目:Openjsharp    文件JdbcOdbcPreparedStatement.java   
public void setRef(int parameterIndex,Ref x) throws sqlException{
    setobject(parameterIndex,x,Types.REF);
}
项目:sstore-soft    文件JDBC4ResultSet.java   
@Override
public Ref getRef(int columnIndex) throws sqlException {
    checkColumnBounds(columnIndex);
    throw sqlError.noSupport();
}
项目:sstore-soft    文件JDBC4ResultSet.java   
@Override
public Ref getRef(String columnLabel) throws sqlException {
    return getRef(findColumn(columnLabel));
}
项目:sstore-soft    文件JDBC4ResultSet.java   
@Override
public void updateRef(String columnLabel,Ref x) throws sqlException {
    throw sqlError.noSupport();
}
项目:sstore-soft    文件JDBC4CallableStatement.java   
@Override
public Ref getRef(String parameterName) throws sqlException
{
    checkClosed();
    throw sqlError.noSupport();
}
项目:QDrill    文件AvaticaDrillsqlAccessor.java   
@Override
public Ref getRef() throws sqlException {
  throw new sqlFeatureNotSupportedException();
}
项目:agroal    文件MockResultSet.java   
@Override
default void updateRef(String columnLabel,Ref x) throws sqlException {
}
项目:jdk8u-jdk    文件StubJoinRowSetImpl.java   
@Override
public void updateRef(int columnIndex,Ref x) throws sqlException {
    throw new UnsupportedOperationException("Not supported yet.");
}
项目:QDrill    文件DrillResultSetImpl.java   
@Override
public void updateRef( String columnLabel,Ref x ) throws sqlException {
  checkNotClosed();
  super.updateRef( columnLabel,x );
}
项目:preflex    文件PreparedStatementWrapper.java   
@Override
public void setRef(int parameterIndex,Ref x) throws sqlException {
    pstmt.setRef(parameterIndex,x);
}
项目:preflex    文件CallableStatementWrapper.java   
@Override
public Ref getRef(int parameterIndex) throws sqlException {
    return stmt.getRef(parameterIndex);
}
项目:preflex    文件CallableStatementWrapper.java   
@Override
public Ref getRef(String parameterName) throws sqlException {
    return stmt.getRef(parameterName);
}
项目:openjdk-jdk10    文件StubFilteredRowSetImpl.java   
@Override
public Ref getRef(int columnIndex) throws sqlException {
    throw new UnsupportedOperationException("Not supported yet.");
}
项目:jdk8u-jdk    文件StubFilteredRowSetImpl.java   
@Override
public Ref getRef(int columnIndex) throws sqlException {
    throw new UnsupportedOperationException("Not supported yet.");
}
项目:mycat-src-1.6.1-RELEASE    文件MongoResultSet.java   
@Override
public Ref getRef(int columnIndex) throws sqlException {

    return null;
}
项目:mycat-src-1.6.1-RELEASE    文件MongoResultSet.java   
@Override
public Ref getRef(String columnLabel) throws sqlException {

    return null;
}
项目:tomcat7    文件Statement.java   
@Override
public Ref getRef(int parameterIndex) throws sqlException {
    // Todo Auto-generated method stub
    return null;
}
项目:agroal    文件ResultSetWrapper.java   
@Override
public void updateRef(String columnLabel,Ref x) throws sqlException {
    wrappedResultSet.updateRef( columnLabel,x );
}
项目:openjdk-jdk10    文件StubJdbcRowSetImpl.java   
@Override
public void setRef(int i,Ref x) throws sqlException {
    throw new UnsupportedOperationException("Not supported yet.");
}
项目:lams    文件PreparedStatement.java   
public Ref getRef(int parameterIndex) throws sqlException {
    return this.bindingsAsRs.getRef(parameterIndex);
}
项目:BibliotecaPS    文件ResultSetImpl.java   
/**
 * @see ResultSetInternalMethods#updateRef(String,Ref)
 */
public void updateRef(String arg0,Ref arg1) throws sqlException {
    throw sqlError.createsqlFeatureNotSupportedException();
}
项目:tomcat7    文件ResultSet.java   
@Override
public void updateRef(String columnLabel,Ref x) throws sqlException {
    // Todo Auto-generated method stub

}

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。