Enum Class ResourcePrefix

java.lang.Object
java.lang.Enum<ResourcePrefix>
org.springframework.geode.core.io.support.ResourcePrefix
All Implemented Interfaces:
Serializable, Comparable<ResourcePrefix>, Constable

public enum ResourcePrefix extends Enum<ResourcePrefix>
An enumeration of Resource prefixes recognized by the Spring Framework.
Since:
1.3.1
See Also:
  • Resource
  • Enum Constant Details

    • CLASSPATH_URL_PREFIX

      public static final ResourcePrefix CLASSPATH_URL_PREFIX
    • FILESYSTEM_URL_PREFIX

      public static final ResourcePrefix FILESYSTEM_URL_PREFIX
    • HTTP_URL_PREFIX

      public static final ResourcePrefix HTTP_URL_PREFIX
  • Field Details

  • Method Details

    • values

      public static ResourcePrefix[] 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

      public static ResourcePrefix valueOf(String name)
      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 name
      NullPointerException - if the argument is null
    • from

      @Nullable public static ResourcePrefix from(@Nullable String prefix)
      Factory method used to try and find a ResourcePrefix enumerated value matching the given prefix.
      Parameters:
      prefix - String with the name of the prefix.
      Returns:
      a ResourcePrefix matching the given prefix by name, or null if the prefix does not match any ResourcePrefix enumerated value.
    • getProtocol

      public String getProtocol()
      Gets the network protocol that this ResourcePrefix represents.
      Returns:
      the network protocol that this ResourcePrefix represents.
    • getUrlPrefixPattern

      protected String getUrlPrefixPattern()
      Gets the pattern or template used to construct a URL prefix from this ResourcePrefix.
      Returns:
      the pattern or template used to construct a URL prefix from this ResourcePrefix.
      See Also:
    • toString

      public String toString()
      Overrides:
      toString in class Enum<ResourcePrefix>
    • toUrlPrefix

      public String toUrlPrefix()
      Gets the ResourcePrefix as a prefix use in a URL.
      Returns:
      the URL prefix.
      See Also: