Serializable identifierFrom(Serializable identifier, ResultSet resultSet) throws SQLException {
		if (isString(identifier) && hasValidClassIdType(resultSet)
			&& canConvertFromStringTo(classIdTypeFrom(resultSet))) {

			identifier = convertFromStringTo((String) identifier, classIdTypeFrom(resultSet));
		} else {
			// Assume it should be a Long type
			identifier = convertToLong(identifier);
		}

		return identifier;
	}
Serializable identifierFrom(Serializable identifier, ResultSet resultSet) throws SQLException {
		if (isString(identifier) && hasValidClassIdType(resultSet)
			&& canConvertFromStringTo(classIdTypeFrom(resultSet))) {

			identifier = convertFromStringTo((String) identifier, classIdTypeFrom(resultSet));
		} else {
			
			identifier = convertToLong(identifier);
		}

		return identifier;
	}
Serializable identifierFrom ( Serializable identifier , ResultSet resultSet ) throws SQLException { if ( isString ( identifier ) && hasValidClassIdType ( resultSet ) && canConvertFromStringTo ( classIdTypeFrom ( resultSet ) ) ) { identifier = convertFromStringTo ( ( String ) identifier , classIdTypeFrom ( resultSet ) ) ; } else { // Assume it should be a Long type identifier = convertToLong ( identifier ) ; } return identifier ; }
Converts the raw type from the database into the right Java type. For most applications the 'raw type' will be Long, for some applications
it could be String.
@param identifier The identifier from the database
@param resultSet  Result set of the query
@return The identifier in the appropriate target Java type. Typically Long or UUID.
@throws SQLException
Converts the raw type from the database into the right Java type . For most applications the raw type will be Long for some applications it could be String .