List of usage examples for org.springframework.jdbc.core SqlParameter SqlParameter
public SqlParameter(String name, int sqlType, int scale)
From source file:org.codehaus.grepo.procedure.compile.ProcedureCompilationUtils.java
/** * @param in The annotation./* www . j a va2 s. co m*/ * @param context The procedure execution context. * @return Returns the created descriptor. */ public static ProcedureParamDescriptor createParamDescriptor(In in, ProcedureExecutionContext context) { SqlParameter sp = null; if (in.scale() >= 0) { sp = new SqlParameter(in.name(), in.sqlType(), in.scale()); } else if (StringUtils.isNotEmpty(in.typeName())) { sp = new SqlParameter(in.name(), in.sqlType(), in.typeName()); } else { sp = new SqlParameter(in.name(), in.sqlType()); } return new ProcedureParamDescriptor(sp.getName(), ProcedureParamType.IN, sp, in.index()); }