枚举 Villager.Career
- 所有已实现的接口:
Serializable
,Comparable<Villager.Career>
,java.lang.constant.Constable
- 封闭接口:
- Villager
The Career of this Villager.
Each
Villager.Profession
has a set of careers it is applicable to. Each
career dictates the trading options that are generated.-
嵌套类概要
从类继承的嵌套类/接口 java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
枚举常量概要
枚举常量说明Armorers primarily trade for iron armor, chainmail armor, and sometimes diamond armor.Butchers primarily trade for raw and cooked food.Cartographers primarily trade for explorer maps and some paper.Clerics primarily trade for rotten flesh, gold ingot, redstone, lapis, ender pearl, glowstone, and bottle o' enchanting.Farmers primarily trade for food-related items.Fisherman primarily trade for fish, as well as possibly selling string and/or coal.Fletchers primarily trade for string, bows, and arrows.Leatherworkers primarily trade for leather, and leather armor, as well as saddles.Librarians primarily trade for paper, books, and enchanted books.Nitwit villagers do not do anything.Shepherds primarily trade for wool items, and shears.Tool smiths primarily trade for iron and diamond tools.Weapon smiths primarily trade for iron and diamond weapons, sometimes enchanted. -
方法概要
修饰符和类型方法说明static List<Villager.Career>
getCareers
(Villager.Profession profession) Get an immutable list ofVillager.Career
s that can be used with a givenVillager.Profession
Get theVillager.Profession
thisVillager.Career
belongs to.static Villager.Career
返回带有指定名称的该类型的枚举常量。static Villager.Career[]
values()
按照声明该枚举类型的常量的顺序, 返回一个包含这些常量的数组。
-
枚举常量详细资料
-
FARMER
Farmers primarily trade for food-related items. -
FISHERMAN
Fisherman primarily trade for fish, as well as possibly selling string and/or coal. -
SHEPHERD
Shepherds primarily trade for wool items, and shears. -
FLETCHER
Fletchers primarily trade for string, bows, and arrows. -
LIBRARIAN
Librarians primarily trade for paper, books, and enchanted books. -
CARTOGRAPHER
Cartographers primarily trade for explorer maps and some paper. -
CLERIC
Clerics primarily trade for rotten flesh, gold ingot, redstone, lapis, ender pearl, glowstone, and bottle o' enchanting. -
ARMORER
Armorers primarily trade for iron armor, chainmail armor, and sometimes diamond armor. -
WEAPON_SMITH
Weapon smiths primarily trade for iron and diamond weapons, sometimes enchanted. -
TOOL_SMITH
Tool smiths primarily trade for iron and diamond tools. -
BUTCHER
Butchers primarily trade for raw and cooked food. -
LEATHERWORKER
Leatherworkers primarily trade for leather, and leather armor, as well as saddles. -
NITWIT
Nitwit villagers do not do anything. They do not have any trades by default.
-
-
方法详细资料
-
values
按照声明该枚举类型的常量的顺序, 返回一个包含这些常量的数组。- 返回:
- 按照声明该枚举类型的常量的顺序返回的包含这些常量的数组
-
valueOf
返回带有指定名称的该类型的枚举常量。 字符串必须与用于声明该类型的枚举常量的 标识符完全匹配。(不允许有多余 的空格字符。)- 参数:
name
- 要返回的枚举常量的名称。- 返回:
- 返回带有指定名称的枚举常量
- 抛出:
IllegalArgumentException
- 如果该枚举类型没有带有指定名称的常量NullPointerException
- 如果参数为空值
-
getProfession
Get theVillager.Profession
thisVillager.Career
belongs to.- 返回:
- the
Villager.Profession
.
-
getCareers
Get an immutable list ofVillager.Career
s that can be used with a givenVillager.Profession
- 参数:
profession
- the profession to get careers for- 返回:
- an immutable list of Careers that can be used by a profession, or an empty map if the profession was not found
-