T - the type of json node expected to be producedpublic interface IValueProducer<T extends JsonNode>
JsonTemplate has implemented some basic node producers which can suit most of the cases.
Other libraries, such as Guava, Apache Commons, JFaker, support powerful data generations. Users are freely to customize, extend, and add their own producers.
| 限定符和类型 | 方法和说明 |
|---|---|
String |
getTypeName()
Returns the name of the producer used in the template.
|
T |
produce()
Produces a node without any parameter.
|
T |
produce(List<String> valueList)
Produces a node with a list parameter.
|
T |
produce(Map<String,String> paramMap)
Produces a node with a map parameter.
|
T |
produce(String value)
Produces a node with a single parameter.
|
String getTypeName()
T produce()
T produce(String value)
value - the single parameterT produce(List<String> valueList)
valueList - the list of enumerated valuesCopyright © 2019. All rights reserved.