ServerVersion Class

public final class ServerVersion
extends ExpandableStringEnum<ServerVersion>

Describes the version of the MongoDB account.

Field Summary

Modifier and Type Field and Description
static final ServerVersion FIVE_ZERO

Static value 5.0 for ServerVersion.

static final ServerVersion FOUR_TWO

Static value 4.2 for ServerVersion.

static final ServerVersion FOUR_ZERO

Static value 4.0 for ServerVersion.

static final ServerVersion SEVEN_ZERO

Static value 7.0 for ServerVersion.

static final ServerVersion SIX_ZERO

Static value 6.0 for ServerVersion.

static final ServerVersion THREE_SIX

Static value 3.6 for ServerVersion.

static final ServerVersion THREE_TWO

Static value 3.2 for ServerVersion.

Constructor Summary

Constructor Description
ServerVersion()

Deprecated

Use the fromString(String name) factory method.

Creates a new instance of ServerVersion value.

Method Summary

Modifier and Type Method and Description
static ServerVersion fromString(String name)

Creates or finds a ServerVersion from its string representation.

static Collection<ServerVersion> values()

Gets known ServerVersion values.

Methods inherited from ExpandableStringEnum

Methods inherited from java.lang.Object

Field Details

FIVE_ZERO

public static final ServerVersion FIVE_ZERO

Static value 5.0 for ServerVersion.

FOUR_TWO

public static final ServerVersion FOUR_TWO

Static value 4.2 for ServerVersion.

FOUR_ZERO

public static final ServerVersion FOUR_ZERO

Static value 4.0 for ServerVersion.

SEVEN_ZERO

public static final ServerVersion SEVEN_ZERO

Static value 7.0 for ServerVersion.

SIX_ZERO

public static final ServerVersion SIX_ZERO

Static value 6.0 for ServerVersion.

THREE_SIX

public static final ServerVersion THREE_SIX

Static value 3.6 for ServerVersion.

THREE_TWO

public static final ServerVersion THREE_TWO

Static value 3.2 for ServerVersion.

Constructor Details

ServerVersion

@Deprecated
public ServerVersion()

Deprecated

Use the fromString(String name) factory method.

Creates a new instance of ServerVersion value.

Method Details

fromString

public static ServerVersion fromString(String name)

Creates or finds a ServerVersion from its string representation.

Parameters:

name - a name to look for.

Returns:

the corresponding ServerVersion.

values

public static Collection values()

Gets known ServerVersion values.

Returns:

known ServerVersion values.

Applies to