Enum Class HuggingFaceHub.RepoType
- All Implemented Interfaces:
Serializable, Comparable<HuggingFaceHub.RepoType>, Constable
- Enclosing class:
HuggingFaceHub
Supported Hugging Face repository types.
-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum Constants -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionReturns the cache directory prefix for this repo type.static HuggingFaceHub.RepoTypeReturns the enum constant of this class with the specified name.static HuggingFaceHub.RepoType[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
MODEL
A model repository (default). -
DATASET
A dataset repository. -
SPACE
A Space repository.
-
-
Field Details
-
urlSegment
The URL path segment used in the Hugging Face API.
-
-
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
-
cachePrefix
Returns the cache directory prefix for this repo type. Models use"models", datasets"datasets", spaces"spaces".- Returns:
- the cache folder name prefix.
-