public enum ResourcePrefix extends java.lang.Enum<ResourcePrefix>
Resource prefixes recognized by the Spring Framework.Resource| Enum Constant and Description |
|---|
CLASSPATH_URL_PREFIX |
FILESYSTEM_URL_PREFIX |
HTTP_URL_PREFIX |
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
RESOURCE_PATH_SEPARATOR |
| Modifier and Type | Method and Description |
|---|---|
static ResourcePrefix |
from(java.lang.String prefix)
Factory method used to try and find a
ResourcePrefix enumerated value
matching the given prefix. |
java.lang.String |
getProtocol()
Gets the network protocol that this
ResourcePrefix represents. |
protected java.lang.String |
getUrlPrefixPattern()
|
java.lang.String |
toString() |
java.lang.String |
toUrlPrefix()
Gets the
ResourcePrefix as a prefix use in a URL. |
static ResourcePrefix |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static ResourcePrefix[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final ResourcePrefix CLASSPATH_URL_PREFIX
public static final ResourcePrefix FILESYSTEM_URL_PREFIX
public static final ResourcePrefix HTTP_URL_PREFIX
public static final java.lang.String RESOURCE_PATH_SEPARATOR
public static ResourcePrefix[] values()
for (ResourcePrefix c : ResourcePrefix.values()) System.out.println(c);
public static ResourcePrefix 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 null@Nullable public static ResourcePrefix from(@Nullable java.lang.String prefix)
ResourcePrefix enumerated value
matching the given prefix.prefix - String with the name of the prefix.ResourcePrefix matching the given prefix by name, or null
if the prefix does not match any ResourcePrefix enumerated value.public java.lang.String getProtocol()
ResourcePrefix represents.ResourcePrefix represents.protected java.lang.String getUrlPrefixPattern()
pattern or template used to construct a URL prefix
from this ResourcePrefix.toUrlPrefix()public java.lang.String toString()
toString in class java.lang.Enum<ResourcePrefix>public java.lang.String toUrlPrefix()
ResourcePrefix as a prefix use in a URL.URL prefix.getUrlPrefixPattern()