All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.springframework.data.simpledb.util.StringUtil Maven / Gradle / Ivy

Go to download

Provides a POJO centric model as per Spring Data interfaces to interact with Amazon SimpleDB, a non-relational datastore

There is a newer version: 1.0.1
Show newest version
package org.springframework.data.simpledb.util;

public final class StringUtil {

	private StringUtil() {
		// utility class
	}

	public static String toLowerFirstChar(String source) {
		if(source == null) {
			return null;
		}

		if(source.length() == 1) {
			return source.toLowerCase();
		} else {
			String rest = source.substring(1);
			String start = String.valueOf(source.charAt(0));
			return start.toLowerCase() + rest;
		}
	}
	
	public static String removeExtraSpaces(final String source) {
		return source.replaceAll(" +", " ");
	}

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy