public final class Version extends Object implements Serializable, Comparable<Version>
Modifier and Type | Field and Description |
---|---|
static Version |
FIX40
Version 4.0
|
static Version |
FIX41
Version 4.1
|
static Version |
FIX42
Version 4.2
|
static Version |
FIX43
Version 4.3
|
static Version |
FIX44
Version 4.4
|
static Version |
FIX50
Version 5.0
|
static Version |
FIX50_SP1
Version 5.0 SP1
|
static Version |
FIX50_SP2
Version 5.0 SP2
|
static Version |
FIX50_SP2_LATEST
Version 5.0 SP2 Latest
|
static Version |
UNKNOWN
Unknown FIX version.
|
Modifier and Type | Method and Description |
---|---|
void |
checkUsable()
Checks whether this version is initialized and can be used.
|
int |
compareTo(Version o) |
static Set<Version> |
getAllBaseVersions()
Returns base FIX versions.
|
static List<Version> |
getAllVersions()
Returns all base and dialect FIX versions.
|
ApplVerId |
getApplVerId()
Returns ApplVerID(1128) value.
|
Version |
getBaseVersion()
Returns base FIX version if this is dialect or itself if not.
|
String |
getBeginString()
Returns the value of the BeginString (tag=8) field.
|
static Version |
getByApplVerId(ApplVerId applVerId)
Returns FIX version by the
ApplVerID(1128) value.
|
static Version |
getByBeginString(String beginString)
Returns instance by FIX begin string.
|
static Version |
getByBeginStringBytesStrict(byte[] buffer,
int offset,
int length)
Returns FIX version by the begin string in the buffer.
|
static Version |
getByDefaultApplVerId(ApplVerId defaultApplVerID)
Returns FIX version by the
DefaultApplVerID(1137) value.
|
static Version |
getById(String id)
Returns instance by base or dialect FIX version id.
|
static Version |
getByIdStrict(String id)
Returns instance by base or dialect FIX version id.
|
static Version |
getByNumber(String number)
Returns instance by FIX version number.
|
byte[] |
getBytes()
Returns FIX string as a byte array.
|
ApplVerId |
getDefaultApplVerId()
Returns DefaultApplVerID(1137) value.
|
static Version |
getDialectVersion(Version baseVersion,
String id)
Returns dialect FIX version with the specified base FIX version and dialect name.
|
String |
getId()
Returns base or dialect FIX version id.
|
String |
getNumber()
Returns FIX version number.
|
boolean |
isUsable()
Returns whether this version is initialized and can be used.
|
String |
toString() |
public static final Version UNKNOWN
public static final Version FIX40
public static final Version FIX41
public static final Version FIX42
public static final Version FIX43
public static final Version FIX44
public static final Version FIX50
public static final Version FIX50_SP1
public static final Version FIX50_SP2
public static final Version FIX50_SP2_LATEST
public static Set<Version> getAllBaseVersions()
public static List<Version> getAllVersions()
public ApplVerId getApplVerId()
public String getBeginString()
FIX.4.2
.public byte[] getBytes()
getBeginString()
.public ApplVerId getDefaultApplVerId()
public String getId()
FIX.4.2
Example: Lava
public String getNumber()
4.2
.public boolean isUsable()
public void checkUsable()
VersionNotUsable
- if this version is not initialized or can not be used.public static Version getByApplVerId(ApplVerId applVerId)
applVerId
- ApplVerID(1128) valuepublic static Version getByBeginString(String beginString)
beginString
- FIX begin stringpublic static Version getByBeginStringBytesStrict(byte[] buffer, int offset, int length)
buffer
- source bufferoffset
- offset in the bufferlength
- lengthpublic static Version getByDefaultApplVerId(ApplVerId defaultApplVerID)
defaultApplVerID
- DefaultApplVerID(1137) valuepublic static Version getByIdStrict(String id)
id
- FIX version name or dialect name. Example: FIX.4.2
. Example: Lava
.RuntimeException
- if not foundpublic static Version getById(String id)
id
- FIX version name or dialect name. Example: FIX.4.2
. Example: Lava
.UNKNOWN
if not foundpublic static Version getByNumber(String number)
number
- FIX version number. Example: 4.2
public static Version getDialectVersion(Version baseVersion, String id)
getById(String)
if you just need to get a version
by name.baseVersion
- base FIX versionid
- dialect idpublic int compareTo(Version o)
compareTo
in interface Comparable<Version>
public Version getBaseVersion()
Copyright © 2005–2024 Onix Solutions. All rights reserved.