public class XMLSchemaGenerator extends Object
| Constructor and Description |
|---|
XMLSchemaGenerator(ProcessingEnvironment processingEnvironment,
ViewProcessor.JavaEnvironment env,
File rootDirectory,
TypeElement javaClass,
TypeElement builderClass) |
| Modifier and Type | Method and Description |
|---|---|
void |
addInclude(File includeFile) |
void |
addSubGenerator(XMLSchemaGenerator generator) |
File |
getCommonDir() |
File |
getJavaSourceFile()
Gets the Java source file associated with this schema, if it is in the common/src/main/java directory
|
File |
getSchemaFile() |
boolean |
isJavaSourceChanged()
Checks if the Java source file has changed since the schema file was generated.
|
void |
setAllTags(Map<String,TypeElement> tags) |
void |
setChecksum(String checksum)
Sets a checksum to embed in the file.
|
void |
setPartialSchema(boolean partial) |
void |
setWriteElements(boolean writeElements) |
StringBuilder |
writeSchema(StringBuilder sb) |
StringBuilder |
writeSchema(StringBuilder sb,
boolean writeHeader) |
void |
writeToFile()
Writes to file.
|
public XMLSchemaGenerator(ProcessingEnvironment processingEnvironment, ViewProcessor.JavaEnvironment env, File rootDirectory, TypeElement javaClass, TypeElement builderClass)
public void setPartialSchema(boolean partial)
public void setAllTags(Map<String,TypeElement> tags)
public void setChecksum(String checksum)
checksum - public void addInclude(File includeFile)
public void addSubGenerator(XMLSchemaGenerator generator)
public void writeToFile()
throws IOException
IOExceptionpublic File getCommonDir()
public File getJavaSourceFile()
public boolean isJavaSourceChanged()
public File getSchemaFile() throws IOException
IOExceptionpublic void setWriteElements(boolean writeElements)
public StringBuilder writeSchema(StringBuilder sb) throws IOException
IOExceptionpublic StringBuilder writeSchema(StringBuilder sb, boolean writeHeader) throws IOException
IOExceptionCopyright © 2022. All Rights Reserved.