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

com.ircclouds.irc.api.utils.StringUtils Maven / Gradle / Ivy

There is a newer version: 1.0-0014
Show newest version
package com.ircclouds.irc.api.utils;

/**
 * 
 * @author
 * 
 */
public final class StringUtils
{

	private StringUtils()
	{

	}

	public static int indexOf(char aChar, int aCount, String aString)
	{
		int _numSpc = 0;
		int _strLen = aString.length();
		for (int _i = 0; _i < _strLen; _i++)
		{
			if (aString.charAt(_i) == aChar)
			{
				_numSpc++;
				if (_numSpc == aCount)
				{
					return _i;
				}
			}
		}

		return -1;
	}

	public static boolean isEmpty(String aString)
	{
		return aString == null || "".equals(aString);
	}
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy