public class JsClassGenerator extends JsFileWriter
indent, INDENTATION_UNITY, writer
Constructor and Description |
---|
JsClassGenerator(String filePath,
String typesPackage) |
Modifier and Type | Method and Description |
---|---|
void |
builderClass(ParsedValueObject valueObject,
String objectName,
JsClassGenerator write) |
void |
buildMethod(String objectName,
List<ValueObjectProperty> properties) |
void |
constructor(List<ValueObjectProperty> properties) |
void |
elementAccessor(ValueObjectType type) |
void |
extendGenericTypeJsDoc(ValueObjectType type) |
void |
fromJsonMethod(String objectName) |
void |
fromObjectMethod(String builderName,
List<ValueObjectProperty> properties) |
void |
getters(List<ValueObjectProperty> properties) |
void |
listConstructor() |
void |
setters(List<ValueObjectProperty> properties,
String builderName) |
void |
toJsonMethod() |
void |
toObjectMethod(List<ValueObjectProperty> properties) |
void |
validateElement(ValueObjectType type) |
void |
valueObjectClass(ParsedValueObject valueObject,
String objectName,
JsClassGenerator write) |
public JsClassGenerator(String filePath, String typesPackage) throws IOException
IOException
public void valueObjectClass(ParsedValueObject valueObject, String objectName, JsClassGenerator write) throws IOException, ProcessingException
IOException
ProcessingException
public void constructor(List<ValueObjectProperty> properties) throws IOException
IOException
public void getters(List<ValueObjectProperty> properties) throws IOException, ProcessingException
IOException
ProcessingException
public void toObjectMethod(List<ValueObjectProperty> properties) throws IOException, ProcessingException
IOException
ProcessingException
public void toJsonMethod() throws IOException
IOException
public void builderClass(ParsedValueObject valueObject, String objectName, JsClassGenerator write) throws IOException, ProcessingException
IOException
ProcessingException
public void validateElement(ValueObjectType type) throws ProcessingException, IOException
ProcessingException
IOException
public void setters(List<ValueObjectProperty> properties, String builderName) throws IOException, ProcessingException
IOException
ProcessingException
public void buildMethod(String objectName, List<ValueObjectProperty> properties) throws IOException
IOException
public void fromObjectMethod(String builderName, List<ValueObjectProperty> properties) throws IOException, ProcessingException
IOException
ProcessingException
public void fromJsonMethod(String objectName) throws IOException
IOException
public void elementAccessor(ValueObjectType type) throws IOException, ProcessingException
IOException
ProcessingException
public void extendGenericTypeJsDoc(ValueObjectType type) throws IOException, ProcessingException
IOException
ProcessingException
public void listConstructor() throws IOException
IOException
Copyright © 2019. All rights reserved.