public enum SrxVersion extends Enum<SrxVersion>
| Enum Constant and Description |
|---|
VERSION_1_0 |
VERSION_2_0 |
| Modifier and Type | Method and Description |
|---|---|
static SrxVersion |
parse(BufferedReader reader)
Returns SRX document version.
|
static SrxVersion |
parse(String versionString) |
String |
toString() |
static SrxVersion |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static SrxVersion[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final SrxVersion VERSION_1_0
public static final SrxVersion VERSION_2_0
public static SrxVersion[] values()
for (SrxVersion c : SrxVersion.values()) System.out.println(c);
public static SrxVersion valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic String toString()
toString in class Enum<SrxVersion>public static SrxVersion parse(String versionString)
public static SrxVersion parse(BufferedReader reader)
HEADER_BUFFER_LENGHT
and trying to match version regular expression, so it is imperfect.
It must be possible to mark the given reader (Reader.mark(int)).reader - buffered reader containing SRX document with unknown versionIORuntimeException - if IO error occursIllegalArgumentException - if reader does not support markingCopyright © 2018. All Rights Reserved.