Modifier | Constructor and Description |
---|---|
protected |
TitleRule() |
Modifier and Type | Method and Description |
---|---|
com.sun.codemodel.JDocComment |
apply(String nodeName,
com.fasterxml.jackson.databind.JsonNode node,
com.fasterxml.jackson.databind.JsonNode parent,
com.sun.codemodel.JDocCommentable generatableType,
Schema schema)
Applies this schema rule to take the required code generation steps.
|
public com.sun.codemodel.JDocComment apply(String nodeName, com.fasterxml.jackson.databind.JsonNode node, com.fasterxml.jackson.databind.JsonNode parent, com.sun.codemodel.JDocCommentable generatableType, Schema schema)
When a title node is found and applied with this rule, the value of the title is added as a JavaDoc comment. This rule is typically applied to the generated field, generated getter and generated setter for the property.
Note that the title is always inserted at the top of the JavaDoc comment.
apply
in interface Rule<com.sun.codemodel.JDocCommentable,com.sun.codemodel.JDocComment>
nodeName
- the name of the property to which this title appliesnode
- the "title" schema nodeparent
- the parent nodegeneratableType
- comment-able code generation construct, usually a field or
method, which should have this title appliedschema
- the schema to which this schema rule (and the given node)
belongs.Copyright © 2022. All rights reserved.