Enum Class DiskUse
- All Implemented Interfaces:
Serializable, Comparable<DiskUse>, Constable
Disk use indicates if the MongoDB server is allowed to write temporary files to disk during query/aggregation
execution. MongoDB 6.0 server (and later) default for allowDiskUseByDefault is true on the
server side.
- Since:
- 5.0
- Author:
- Christoph Strobl
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptionstatic DiskUseObtain theDiskUsecorresponding to the given Boolean flag.static DiskUseObtain theDiskUsereferred to by the given value.static DiskUseReturns the enum constant of this class with the specified name.static DiskUse[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
DEFAULT
Use the server default value and do not specify any override. -
ALLOW
Allow disk writes. -
DENY
Explicitly deny disk writes.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
of
-
of
Obtain theDiskUsereferred to by the given value. Considers null or empty Strings asDEFAULT, true asALLOW, false asDENYand delegates other values tovalueOf(String).- Parameters:
value- can be null.- Returns:
- the
DiskUsecorresponding to the given value. - Throws:
IllegalArgumentException- if not matchingDiskUsefound.
-