public class ChEBIIdentifier extends AbstractIdentifier
The identifier consists of a unique number preceded by the "CHEBI:" suffix.
| Modifier and Type | Field and Description |
|---|---|
static Pattern |
PATTERN
The pattern to verify the identifier.
|
| Constructor and Description |
|---|
ChEBIIdentifier(String identifier)
Creates a new identifier.
|
| Modifier and Type | Method and Description |
|---|---|
static boolean |
check(Identifier identifier)
Returns true, if the identifier is valid.
|
static Optional<Identifier> |
find(Collection<Identifier> identifiers)
Searches a valid PubChem identifier in a collection of identifiers and returns it.
|
int |
getConsecutiveNumber()
Returns the consecutive number without the "CHEBI:" part.
|
static Pattern |
getPattern()
Returns the pattern used to validate the identifier.
|
equals, getIdentifier, hashCode, toStringpublic static final Pattern PATTERN
public ChEBIIdentifier(String identifier) throws IllegalArgumentException
identifier - The identifier.IllegalArgumentException - If the identifier not valid.public static boolean check(Identifier identifier)
identifier - The identifier.public static Optional<Identifier> find(Collection<Identifier> identifiers)
identifiers - A collection of identifiers.public static Pattern getPattern()
public int getConsecutiveNumber()
Copyright © 2017. All rights reserved.