Enum Downloader.ResolveMode
- java.lang.Object
-
- java.lang.Enum<Downloader.ResolveMode>
-
- org.spongepowered.gradle.vanilla.resolver.Downloader.ResolveMode
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Comparable<Downloader.ResolveMode>
- Enclosing interface:
- Downloader
public static enum Downloader.ResolveMode extends java.lang.Enum<Downloader.ResolveMode>
A mode to control usage of any potential locale cache
-
-
Enum Constant Summary
Enum Constants Enum Constant Description LOCAL_ONLYOnly check the local storage.LOCAL_THEN_REMOTETest and validate local before querying remote.REMOTE_ONLYIgnore any existing local state and always resolve from the remote.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Downloader.ResolveModevalueOf(java.lang.String name)Returns the enum constant of this type with the specified name.static Downloader.ResolveMode[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
LOCAL_THEN_REMOTE
public static final Downloader.ResolveMode LOCAL_THEN_REMOTE
Test and validate local before querying remote.
-
LOCAL_ONLY
public static final Downloader.ResolveMode LOCAL_ONLY
Only check the local storage.In this mode, hash validation failures will result in a printed warning rather than an error.
-
REMOTE_ONLY
public static final Downloader.ResolveMode REMOTE_ONLY
Ignore any existing local state and always resolve from the remote.
-
-
Method Detail
-
values
public static Downloader.ResolveMode[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (Downloader.ResolveMode c : Downloader.ResolveMode.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Downloader.ResolveMode valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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:
java.lang.IllegalArgumentException- if this enum type has no constant with the specified namejava.lang.NullPointerException- if the argument is null
-
-