Initial revision of a string-related utilities class.
git-svn-id: https://samskivert.googlecode.com/svn/trunk@10 6335cc39-0255-0410-8fd6-9bcaacd3b74c
This commit is contained in:
@@ -0,0 +1,9 @@
|
|||||||
|
#
|
||||||
|
# $Id: Makefile,v 1.1 2000/10/31 00:04:15 mdb Exp $
|
||||||
|
|
||||||
|
ROOT = ../../..
|
||||||
|
|
||||||
|
SRCS = \
|
||||||
|
StringUtil.java \
|
||||||
|
|
||||||
|
include $(ROOT)/build/Makefile.java
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
//
|
||||||
|
// $Id: StringUtil.java,v 1.1 2000/10/31 00:04:15 mdb Exp $
|
||||||
|
|
||||||
|
package com.samskivert.util;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* String related utility functions.
|
||||||
|
*/
|
||||||
|
public class StringUtil
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* @return true if the string is null or empty, false otherwise.
|
||||||
|
*/
|
||||||
|
public static boolean blank (String value)
|
||||||
|
{
|
||||||
|
return (value == null || value.trim().length() == 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user