Class ProtocolMessageDocumentation
java.lang.Object
wtf.choco.veinminer.documentation.ProtocolMessageDocumentation
Represents documentation for a protocol message.
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic final class
A builder forProtocolMessageDocumentation
instances. -
Method Summary
Modifier and TypeMethodDescriptionbuilder
(MessageDirection direction, int messageId) Create a newProtocolMessageDocumentation.Builder
.Generate an HTML table containing all the fields in this message and their information.Generate a Markdown-friendly formatted string containing the name, description, andHTML table
of this message.Get the description of this message.Get theMessageDirection
of this message.Get a list of allfields
in this message.int
getId()
Get the unique id of this message.getName()
Get the name of this message.
-
Method Details
-
getDirection
Get theMessageDirection
of this message.- Returns:
- the direction
-
getId
public int getId()Get the unique id of this message.- Returns:
- the unique id
-
getName
Get the name of this message.- Returns:
- the name
-
getDescription
Get the description of this message.- Returns:
- the description
-
getFields
Get a list of allfields
in this message.- Returns:
- the fields
-
generateMessageMarkdown
Generate a Markdown-friendly formatted string containing the name, description, andHTML table
of this message.- Returns:
- the message Markdown
-
generateMessageHTMLTable
Generate an HTML table containing all the fields in this message and their information.- Returns:
- the message HTML table
-
builder
public static ProtocolMessageDocumentation.Builder builder(MessageDirection direction, int messageId) Create a newProtocolMessageDocumentation.Builder
.- Parameters:
direction
- the direction of the message being documentedmessageId
- the id of the message being documented- Returns:
- the builder instance
-