Class
Tree
          
PREV CLASS NEXT CLASS
SUMMARY: INNER | FIELD | CONSTR | METHODDETAIL: FIELD | CONSTR | METHOD
 

com.newstep.solid.persistence.db
Class DataUtil

public class DataUtil      
Validates data format
 
 

Field Summary
private final static String
private final static String
Method Summary
public static String
collectionToStringArray(Collection col)
public static int
compareOctets(String a, String b)
public static boolean
hasValue(String str)
public static boolean
isEmpty(String str)
public static boolean
isIpAddress(String ipAddress)
public static boolean
isNumber(String number)
public static boolean
isNumber(Character c)
public static boolean
isPointCode(String pointCode)
public static boolean
isValidHttpChar(Character c)
public static boolean
isValidHttpString(String str)
public static int[]
splitOctets(String octets)
Field Detail
INVALID_HTTP_CHAR_SET
private final static String INVALID_HTTP_CHAR_SET
Final.
Multiplicity:
1
Static.
 

NUMBER_SET
private final static String NUMBER_SET
Final.
Multiplicity:
1
Static.
 
Method Detail
collectionToStringArray
public static String collectionToStringArray (Collection col)
 
Converts a Collection of String objects to an array of String objects.
Static.
 

compareOctets
public static int compareOctets (String a, String b)
 
Compares two series of octets given as Strings. The comparison is done
by comparing the numerically the octets from left to right, e.g.
1.2.4 is smaller than 1.2.11. Returns 0 if a and b are equal, negative
integer if a is less than b and positive integer if a is larger than b.
An empty octects String is considered smaller than a non-empty octets
String. This can be used for IP address and point code.
Static.
 

hasValue
public static boolean hasValue (String str)
 
checks if a String has a non-empty value. Returns false if the String is null or empty
Static.
 

isEmpty
public static boolean isEmpty (String str)
 
Static.
 

isIpAddress
public static boolean isIpAddress (String ipAddress)
 
Static.
 

isNumber
public static boolean isNumber (String number)
 
Validates if a string is a non-negative number.
Static.
 

isNumber
public static boolean isNumber (Character c)
 
Validates if a character is a number.
Static.
 

isPointCode
public static boolean isPointCode (String pointCode)
 
Static.
 

isValidHttpChar
public static boolean isValidHttpChar (Character c)
 
Static.
 

isValidHttpString
public static boolean isValidHttpString (String str)
 
Static.
 

splitOctets
public static int[] splitOctets (String octets)
 
Splits a series of octets aaa.bbb.ccc into an array of numbers aaa, bbb
and ccc. This can be used for IP address and point code.
Static.
 

Class
Tree
          
PREV CLASS NEXT CLASS
SUMMARY: INNER | FIELD | CONSTR | METHODDETAIL: FIELD | CONSTR | METHOD