Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.springframework.core.enums
Interface LabeledEnumResolver

All Known Implementing Classes:
  AbstractCachingLabeledEnumResolver, StaticLabeledEnumResolver

Deprecated. as of Spring 3.0, in favor of Java 5 enums.

    @Deprecated
    public interface LabeledEnumResolver

Interface for looking up `LabeledEnum` instances.

Since:
  1.2.2
Author:
  Keith Donald, Juergen Hoeller

Method Summary
`LabeledEnum` | `getLabeledEnumByCode(Class type, Comparable code)` Deprecated. Resolve a single `LabeledEnum` by its identifying code.
`LabeledEnum` | `getLabeledEnumByLabel(Class type, String label)` Deprecated. Resolve a single `LabeledEnum` by its identifying code.
`Map` | `getLabeledEnumMap(Class type)` Deprecated. Return a map of enumerations of a particular type.
`Set` | `getLabeledEnumSet(Class type)` Deprecated. Return a set of enumerations of a particular type.

Method Detail

### getLabeledEnumSet

    Set getLabeledEnumSet(Class type)
                          throws IllegalArgumentException

  Deprecated.
  Return a set of enumerations of a particular type. Each element in the set should be an instance of LabeledEnum.

  Parameters:
    `type` - the enum type
  Returns:
    a set of localized enumeration instances for the provided type
  Throws:
    `IllegalArgumentException` - if the type is not supported

### getLabeledEnumMap

    Map getLabeledEnumMap(Class type)
                          throws IllegalArgumentException

  Deprecated.
  Return a map of enumerations of a particular type. Each element in the map should be a key/value pair, where the key is the enum code, and the value is the `LabeledEnum` instance.

  Parameters:
    `type` - the enum type
  Returns:
    a Map of localized enumeration instances, with enum code as key and `LabeledEnum` instance as value
  Throws:
    `IllegalArgumentException` - if the type is not supported

### getLabeledEnumByCode

    LabeledEnum getLabeledEnumByCode(Class type,
                                     Comparable code)
                                     throws IllegalArgumentException

  Deprecated.
  Resolve a single `LabeledEnum` by its identifying code.

  Parameters:
    `type` - the enum type
    `code` - the enum code
  Returns:
    the enum
  Throws:
    `IllegalArgumentException` - if the code did not map to a valid instance

### getLabeledEnumByLabel

    LabeledEnum getLabeledEnumByLabel(Class type,
                                      String label)
                                      throws IllegalArgumentException

  Deprecated.
  Resolve a single `LabeledEnum` by its identifying code.

  Parameters:
    `type` - the enum type
    `label` - the enum label
  Returns:
    the enum
  Throws:
    `IllegalArgumentException` - if the label did not map to a valid instance

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD