Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@
import org.springframework.data.jdbc.repository.support.JdbcRepositoryFactory;
import org.springframework.data.jdbc.testing.TestConfiguration;
import org.springframework.data.repository.CrudRepository;
import org.springframework.lang.Nullable;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.rules.SpringClassRule;
import org.springframework.test.context.junit4.rules.SpringMethodRule;
Expand Down Expand Up @@ -93,9 +92,9 @@ JdbcCustomConversions jdbcCustomConversions() {
*
* @Override
* @Nullable
* public BigDecimal convert(@Nullable String source) {
* public BigDecimal convert(String source) {
*
* return source == null ? null : new BigDecimal(source);
* return source == new BigDecimal(source);
* }
* }
* </pre>
Expand Down Expand Up @@ -130,9 +129,9 @@ enum StringToBigDecimalConverter implements Converter<String, JdbcValue> {
INSTANCE;

@Override
public JdbcValue convert(@Nullable String source) {
public JdbcValue convert(String source) {

Object value = source == null ? null : new BigDecimal(source);
Object value = new BigDecimal(source);
return JdbcValue.of(value, JDBCType.DECIMAL);
}

Expand All @@ -144,11 +143,7 @@ enum BigDecimalToString implements Converter<BigDecimal, String> {
INSTANCE;

@Override
public String convert(@Nullable BigDecimal source) {

if (source == null) {
return null;
}
public String convert(BigDecimal source) {

return source.toString();
}
Expand Down