类 HoverEvent
java.lang.Object
net.md_5.bungee.api.chat.HoverEvent
-
嵌套类概要
嵌套类 -
构造器概要
构造器构造器说明HoverEvent(HoverEvent.Action action, List<Content> contents) HoverEvent(HoverEvent.Action action, BaseComponent[] value) 已过时。HoverEvent(HoverEvent.Action action, Content... contents) Creates event with an action and a list of contents. -
方法概要
修饰符和类型方法说明voidaddContent(Content content) Adds a content to this hover event.booleanThe action of this event.static Class<?>getClass(HoverEvent.Action action, boolean array) Gets the appropriateContentclass for anHoverEvent.Actionfor the GSON serializationList of contents to provide for this event.getValue()已过时。inthashCode()booleanisLegacy()Returns whether this hover event is prior to 1.16voidsetLegacy(boolean legacy) Returns whether this hover event is prior to 1.16toString()
-
构造器详细资料
-
HoverEvent
Creates event with an action and a list of contents.- 参数:
action- action of this eventcontents- array of contents, provide at least one
-
HoverEvent
Legacy constructor to create hover event.- 参数:
action- the actionvalue- the value
-
HoverEvent
-
-
方法详细资料
-
getValue
已过时。 -
addContent
Adds a content to this hover event.- 参数:
content- the content add- 抛出:
IllegalArgumentException- if is a legacy component and already has a contentUnsupportedOperationException- if content action does not match hover event action
-
getClass
Gets the appropriateContentclass for anHoverEvent.Actionfor the GSON serialization- 参数:
action- the action to get forarray- if to return the arrayed class- 返回:
- the class
-
getAction
The action of this event. -
getContents
List of contents to provide for this event. -
isLegacy
public boolean isLegacy()Returns whether this hover event is prior to 1.16 -
toString
-
equals
-
hashCode
public int hashCode() -
setLegacy
public void setLegacy(boolean legacy) Returns whether this hover event is prior to 1.16
-
HoverEvent(Action, Content[])