1 21 22 package org.apache.derby.impl.jdbc; 23 24 import java.sql.SQLException ; 25 import org.apache.derby.iapi.reference.SQLState; 26 import org.apache.derby.iapi.sql.ParameterValueSet; 27 import org.apache.derby.iapi.types.DataTypeDescriptor; 28 29 public class EmbedParameterMetaData40 extends EmbedParameterMetaData30 { 30 31 37 protected EmbedParameterMetaData40(ParameterValueSet pvs, 38 DataTypeDescriptor[] types) { 39 super(pvs,types); 40 } 41 42 53 public boolean isWrapperFor(Class <?> interfaces) throws SQLException { 54 return interfaces.isInstance(this); 55 } 56 57 65 public <T> T unwrap(java.lang.Class <T> interfaces) 66 throws SQLException { 67 try { 72 return interfaces.cast(this); 73 } catch (ClassCastException cce) { 74 throw Util.generateCsSQLException(SQLState.UNABLE_TO_UNWRAP, 75 interfaces); 76 } 77 } 78 } 79 | Popular Tags |