|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectuk.ac.ed.inf.ec.EcNumberGenerator
public class EcNumberGenerator
Given a string such as 1.2.3.4 or 1.2.-.-.- checks if it is a valid Enzyme commission number and generates the Java EcNumber object (including its parent EC numbers)
| Field Summary | |
|---|---|
static java.lang.String |
DASH
the substitute for an unknown digit blocks (a dash) |
static java.lang.String |
DOT
the separator for the digit blocks (dot) |
static int |
FULL_HIERARCHY_LENGHT
the number of levels in the EC number parent-child hierarchy (if -.-.-.- is included = 5, traditional ec hierarchy = 4 ) |
static java.lang.String |
MAX_LEVEL1_CLASS
maximum value for level 1 class: currently 6. |
static java.lang.String |
MAX_LEVEL1_REGEXP
regexp from 1 to 6 |
static java.lang.String |
MAX_LEVEL2_CLASS
maximum value for level 2 class: 99 in this implementation. |
static java.lang.String |
MAX_LEVEL2_REGEXP
regexp from 0 to 99 |
static java.lang.String |
MAX_LEVEL3_CLASS
maximum value for level 3 class: 99 in this implementation. |
static java.lang.String |
MAX_LEVEL3_REGEXP
regexp from 0 to 99 |
static java.lang.String |
MAX_LEVEL4_CLASS
maximum value for level 4 class: 999 in this implementation. |
static java.lang.String |
MAX_LEVEL4_REGEXP
regexp from 0 to 999 |
| Constructor Summary | |
|---|---|
EcNumberGenerator(java.lang.String ec)
|
|
| Method Summary | |
|---|---|
static boolean |
couldBeDashedEc(java.lang.String string)
Checks whether the string could contain a validly formatted ec number with dashes (1.-.-.-, 1.2.3.- etc., but not 1.-.3.4) |
static boolean |
couldBeEc(java.lang.String string)
Checks if the string could contain a validly formatted EC number. |
static EcNumber |
generateEcNumber(java.lang.String ec)
|
static boolean |
isValidEcBlock(java.lang.String block)
True if the string contains a dash '-' or a positive integer or a positive integer preceded by 'n' (new uniprot ec numbers) |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String DASH
public static final java.lang.String DOT
public static final java.lang.String MAX_LEVEL1_CLASS
public static final java.lang.String MAX_LEVEL1_REGEXP
public static final java.lang.String MAX_LEVEL2_CLASS
public static final java.lang.String MAX_LEVEL2_REGEXP
public static final java.lang.String MAX_LEVEL3_CLASS
public static final java.lang.String MAX_LEVEL3_REGEXP
public static final java.lang.String MAX_LEVEL4_CLASS
public static final java.lang.String MAX_LEVEL4_REGEXP
public static final int FULL_HIERARCHY_LENGHT
| Constructor Detail |
|---|
public EcNumberGenerator(java.lang.String ec)
ec - the ec number string| Method Detail |
|---|
public static boolean couldBeDashedEc(java.lang.String string)
string - the ec string
public static boolean couldBeEc(java.lang.String string)
string - the ec number string
public static EcNumber generateEcNumber(java.lang.String ec)
public static boolean isValidEcBlock(java.lang.String block)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||