Here you can find the source of getJavaType(String rdbType)
Parameter | Description |
---|---|
rdbType | a parameter |
public static Integer getJavaType(String rdbType)
//package com.java2s; /******************************************************************************* * Copyright (c) 2013 hangum./*from w w w . j av a 2 s. c o m*/ * All rights reserved. This program and the accompanying materials * are made available under the terms of the GNU Lesser Public License v2.1 * which accompanies this distribution, and is available at * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html * * Contributors: * hangum - initial API and implementation ******************************************************************************/ import java.util.HashMap; import java.util.Map; public class Main { private static Map<String, Integer> mapTypes = new HashMap<String, Integer>(); /** * rdb type to java * * @param rdbType * @return */ public static Integer getJavaType(String rdbType) { Integer javaType = mapTypes.get(rdbType); if (javaType == null) { // logger.info("SQL type to Java type not found is" + rdbType); return java.sql.Types.VARCHAR; } return javaType; } }