cytoscape.util
Class Misc
java.lang.Object
cytoscape.util.Misc
public class Misc
- extends Object
Constructor Summary |
Misc()
|
Misc
public Misc()
parseRGBText
public static Color parseRGBText(String text)
getRGBText
public static String getRGBText(Color color)
getPropertyValues
public static Vector getPropertyValues(Properties props,
String propName)
- return the (possibly multiple) value of the specified property as a vector.
property values (which typically come from cytoscape.prop files)
are usually scalar strings, but may be a list of such strings, surrounded by
parentheses, and delimited by the value of a property
called 'property.delimiter' (whose value is usually "::")
get the property value; check to see if it is a list; parse it if necessary
isList
public static boolean isList(String listString,
String startToken,
String endToken,
String delimiter)
- determine whether a string encodes a list
- Parameters:
listString
- a string containing one or more substringsstartToken
- marks the beginning of the list; must be at the very start (except
for possible leading whitespaceendToken
- marks the end of the list; must be at the very end (except
for possible trailing whitespacedelimiter
- the string (e.g., "::") which separates the substrings
- Returns:
- true or false
parseList
public static String[] parseList(String listString,
String startToken,
String endToken,
String delimiter)
- parse and return an array of strings
- Parameters:
listString
- a string containing one or more substringsstartToken
- marks the beginning of the list; must be at the very start (except
for possible leading whitespaceendToken
- marks the end of the list; must be at the very end (except
for possible trailing whitespacedelimiter
- the string (e.g., "::") which separates the substrings
- Returns:
- an array made up of the substrings