import java.net.*;

public class Util
{
	public static String GetAbsURI(String baseUrl,String url) throws MalformedURLException
	{
		if(url.length() > 0 && url.charAt(0)=='#')
			return url;
		else
		{
			return (new URL(new URL(baseUrl),url)).toExternalForm();
		}
	}

	public static boolean StrNullOrEmpty(String str)
	{
		return str==null || str.length()==0;
	}

	public static String NullToEmptyStr(String str)
	{
		if(str==null)
			return "";
		else
			return str;
	}
}
