public enum ServerType extends java.lang.Enum<ServerType>
Enum Constant and Description |
---|
REPLICA_SET_ARBITER
A replica set arbiter.
|
REPLICA_SET_GHOST
A replica set member that does not report a set name or a hosts list
|
REPLICA_SET_OTHER
A replica set member that is none of the other types (a passive, for example).
|
REPLICA_SET_PRIMARY
A replica set primary.
|
REPLICA_SET_SECONDARY
A replica set secondary.
|
SHARD_ROUTER
A router to a sharded cluster, i.e.
|
STANDALONE
A standalone mongod server.
|
UNKNOWN
The server type is not yet known.
|
Modifier and Type | Method and Description |
---|---|
abstract ClusterType |
getClusterType()
The type of the cluster to which this server belongs
|
static ServerType |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static ServerType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final ServerType STANDALONE
public static final ServerType REPLICA_SET_PRIMARY
public static final ServerType REPLICA_SET_SECONDARY
public static final ServerType REPLICA_SET_ARBITER
public static final ServerType REPLICA_SET_OTHER
public static final ServerType REPLICA_SET_GHOST
public static final ServerType SHARD_ROUTER
public static final ServerType UNKNOWN
public static ServerType[] values()
for (ServerType c : ServerType.values()) System.out.println(c);
public static ServerType valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is nullpublic abstract ClusterType getClusterType()