软件包 | 描述 |
---|---|
java.lang |
提供对java编程语言的设计基础课。
|
java.util |
包含集合框架、遗留的集合类、事件模型、日期和时间的设施、国际化和各种实用工具类(一个字符串标记,一个随机数发生器,和一位阵列)。
|
Modifier and Type | Class and Description |
---|---|
class |
Enum<E extends Enum<E>>
这是所有java语言枚举类型的公共基类。
|
Modifier and Type | Method and Description |
---|---|
static <T extends Enum<T>> |
Enum.valueOf(类<T> enumType, String name)
返回指定枚举类型具有指定名称的枚举常数。
|
Modifier and Type | Method and Description |
---|---|
类<? extends Enum> |
EnumConstantNotPresentException.enumType()
返回丢失的枚举常量的类型。
|
Constructor and Description |
---|
EnumConstantNotPresentException(类<? extends Enum> enumType, String constantName)
构建一个
EnumConstantNotPresentException指定常数。
|
Modifier and Type | Class and Description |
---|---|
class |
EnumMap<K extends Enum<K>,V>
一种用于枚举类型键实现专业
Map 。
|
class |
EnumSet<E extends Enum<E>>
一种用于枚举类型的专业
Set 实施。
|
Modifier and Type | Method and Description |
---|---|
static <E extends Enum<E>> |
EnumSet.allOf(类<E> elementType)
创建一个枚举集合包含所有在指定元素类型的元素。
|
static <E extends Enum<E>> |
EnumSet.complementOf(EnumSet<E> s)
创建一个枚举设置相同的元素类型为指定枚举集,最初包含所有这一类型的,不包含在指定集合中的元素。
|
static <E extends Enum<E>> |
EnumSet.copyOf(Collection<E> c)
创建一个枚举集合初始化指定集合。
|
static <E extends Enum<E>> |
EnumSet.copyOf(EnumSet<E> s)
创建一个枚举设置相同的元素类型为指定枚举集,最初包含相同的元素(如果有)。
|
static <E extends Enum<E>> |
EnumSet.noneOf(类<E> elementType)
创建一个空的枚举设置指定元素类型。
|
static <E extends Enum<E>> |
EnumSet.of(E e)
创建一个枚举集最初包含指定元素。
|
static <E extends Enum<E>> |
EnumSet.of(E first, E... rest)
创建一个枚举集最初包含指定的元素。
|
static <E extends Enum<E>> |
EnumSet.of(E e1, E e2)
创建一个枚举集最初包含指定的元素。
|
static <E extends Enum<E>> |
EnumSet.of(E e1, E e2, E e3)
创建一个枚举集最初包含指定的元素。
|
static <E extends Enum<E>> |
EnumSet.of(E e1, E e2, E e3, E e4)
创建一个枚举集最初包含指定的元素。
|
static <E extends Enum<E>> |
EnumSet.of(E e1, E e2, E e3, E e4, E e5)
创建一个枚举集最初包含指定的元素。
|
static <E extends Enum<E>> |
EnumSet.range(E from, E to)
创建一个枚举集合包含所有在最初的两个端点定义指定范围的元素。
|
Modifier and Type | Method and Description |
---|---|
static <E extends Enum<E>> |
EnumSet.of(E first, E... rest)
创建一个枚举集最初包含指定的元素。
|
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.