public abstract class GeneratorBase extends Object implements GeneratorConstants, ProcessorAction, ModelVisitor, SOAPTypeVisitor, LiteralTypeVisitor
| Modifier and Type | Field and Description |
|---|---|
protected SOAPVersion |
curSOAPVersion |
protected File |
destDir |
protected boolean |
donotOverride |
protected boolean |
encodeTypes |
protected ProcessorEnvironment |
env |
protected boolean |
generateSerializableIf |
protected String |
JAXRPCVersion |
protected Model |
model |
protected boolean |
multiRefEncoding |
protected File |
nonclassDestDir |
protected IndentingWriter |
out |
protected boolean |
serializeInterfaces |
protected Service |
service |
protected String |
servicePackage |
protected File |
sourceDir |
protected String |
targetVersion |
protected SerializerWriterFactory |
writerFactory |
ARRAY, ARRAY_LITERAL_SERIALIZER_SUFFIX, ARRAY_SOAP_SERIALIZER_SUFFIX, ATTACHMENT_SERIALIZER_NAME, BASE_SERIALIZER_NAME, COLLECTION_INTERFACE_SERIALIZER_NAME, COLLECTION_SERIALIZER_NAME, DATA_HANDLER_ENCODER_NAME, DESERIALIZER_SUFFIX, DONT_ENCODE_TYPE_STR, DONT_SERIALIZE_AS_REF_STR, DOT_STR, DYNAMIC_SERIALIZER_NAME, ENCODE_TYPE_STR, FAULT_BUILDER_SUFFIX, FAULT_SOAPSERIALIZER_SUFFIX, FILE_TYPE_ENUMERATION, FILE_TYPE_ENUMERATION_ENCODER, FILE_TYPE_EXCEPTION, FILE_TYPE_FAULT_EXCEPTION_BUILDER, FILE_TYPE_HOLDER, FILE_TYPE_INTERFACE_SERIALIZER, FILE_TYPE_LITERAL_OBJECT_SERIALIZER, FILE_TYPE_SERIALIZER, FILE_TYPE_SERIALIZER_REGISTRY, FILE_TYPE_SERVICE_IMPL, FILE_TYPE_SERVLET_CONFIG, FILE_TYPE_SOAP_FAULT_SERIALIZER, FILE_TYPE_SOAP_OBJECT_BUILDER, FILE_TYPE_SOAP_OBJECT_SERIALIZER, FILE_TYPE_STUB, FILE_TYPE_TIE, FILE_TYPE_VALUETYPE, GET, HOLDER_SUFFIX, ID_REMOTE_EXCEPTION, ID_STUB_BASE, ID_TIE_BASE, IMAGE_ENCODER_NAME, IMPL_SUFFIX, IS, JAVA_PACKAGE_PREFIX, JAVA_SRC_SUFFIX, JAVAX_PACKAGE_PREFIX, JAX_RPC_MAP_ENTRY_SERIALIZER_NAME, LITERAL_FRAGMENT_SERIALIZER_NAME, LITERAL_SERIALIZER_SUFFIX, LITERAL_SIMPLE_TYPE_SERIALIZER_NAME, MAP_INTERFACE_SERIALIZER_NAME, MAP_SERIALIZER_NAME, MEMBER_PREFIX, MIME_MULTIPART_ENCODER_NAME, NOT_NULLABLE_STR, NOT_REFERENCEABLE_STR, NS_PREFIX, NULLABLE_STR, OPCODE_SUFFIX, QNAME_SUFFIX, REFERENCEABLE_SERIALIZER_NAME, REFERENCEABLE_STR, RESPONSE, SERIALIZE_AS_REF_STR, SERIALIZER_REGISTRY_SUFFIX, SERIALIZER_SUFFIX, SERVANT_SUFFIX, SERVICE_IMPL_SUFFIX, SERVICE_SUFFIX, SET, SIMPLE_MULTI_TYPE_SERIALIZER_NAME, SIMPLE_TYPE_SERIALIZER_NAME, SKELETON_SUFFIX, SOAP_BUILDER_SUFFIX, SOAP_INTERFACE_SERIALIZER_SUFFIX, SOAP_SERIALIZER_SUFFIX, SOAP_VERSION_11, SOAP_VERSION_12, SOAP12CONSTANTS_NS_SOAP_ENCODING, SOAPCONSTANTS_NS_SOAP_ENCODING, SOURCE_ENCODER_NAME, STUB_SUFFIX, TIE_SUFFIX, TYPE_QNAME_SUFFIX, UNDERSCORE, XSD_ANY_URI_ENCODER_NAME, XSD_BASE64_BINARY_ENCODER_NAME, XSD_BOOLEAN_ENCODER_NAME, XSD_BOXED_BASE64_BINARY_ENCODER_NAME, XSD_BOXED_HEX_BINARY_ENCODER_NAME, XSD_BYTE_ENCODER_NAME, XSD_DATE_ENCODER_NAME, XSD_DATE_TIME_CALENDAR_ENCODER_NAME, XSD_DATE_TIME_DATE_ENCODER_NAME, XSD_DECIMAL_ENCODER_NAME, XSD_DOUBLE_ENCODER_NAME, XSD_FLOAT_ENCODER_NAME, XSD_HEX_BINARY_ENCODER_NAME, XSD_INT_ENCODER_NAME, XSD_INTEGER_ENCODER_NAME, XSD_LIST_ENCODER_NAME, XSD_LIST_TYPE_ENCODER_NAME, XSD_LONG_ENCODER_NAME, XSD_NEGATIVE_INTEGER_ENCODER_NAME, XSD_NON_NEGATIVE_INTEGER_ENCODER_NAME, XSD_NON_POSITIVE_INTEGER_ENCODER_NAME, XSD_POSITIVE_INTEGER_ENCODER_NAME, XSD_QNAME_ENCODER_NAME, XSD_SHORT_ENCODER_NAME, XSD_STRING_ENCODER_NAME, XSD_TIME_ENCODER_NAME, XSD_UNSIGNED_BYTE_ENCODER_NAME, XSD_UNSIGNED_INT_ENCODER_NAME, XSD_UNSIGNED_LONG_ENCODER_NAME, XSD_UNSIGNED_SHORT_ENCODER_NAMEARRAY_LIST_CLASSNAME, ARRAY_STR, BIGDECIMAL_CLASSNAME, BIGINTEGER_CLASSNAME, BOOLEAN_CLASSNAME, BOXED_BOOLEAN_CLASSNAME, BOXED_BYTE_ARRAY_CLASSNAME, BOXED_BYTE_CLASSNAME, BOXED_CHAR_CLASSNAME, BOXED_DOUBLE_CLASSNAME, BOXED_FLOAT_CLASSNAME, BOXED_INTEGER_CLASSNAME, BOXED_LONG_CLASSNAME, BOXED_SHORT_CLASSNAME, BRACKETS, BYTE_ARRAY_CLASSNAME, BYTE_CLASSNAME, CALENDAR_CLASSNAME, CHAR_CLASSNAME, CLASS_CLASSNAME, COLLECTION_CLASSNAME, DATA_HANDLER_CLASSNAME, DATE_CLASSNAME, DOUBLE_CLASSNAME, FALSE_STR, FLOAT_CLASSNAME, HASH_MAP_CLASSNAME, HASH_SET_CLASSNAME, HASHTABLE_CLASSNAME, IMAGE_CLASSNAME, INT_CLASSNAME, IOEXCEPTION_CLASSNAME, JAX_RPC_MAP_ENTRY_CLASSNAME, LINKED_LIST_CLASSNAME, LIST_CLASSNAME, LONG_CLASSNAME, MAP_CLASSNAME, MIME_MULTIPART_CLASSNAME, NULL_STR, OBJECT_CLASSNAME, PROPERTIES_CLASSNAME, QNAME_CLASSNAME, SET_CLASSNAME, SHORT_CLASSNAME, SOAPELEMENT_CLASSNAME, SOURCE_CLASSNAME, STACK_CLASSNAME, STRING_ARRAY_CLASSNAME, STRING_CLASSNAME, TREE_MAP_CLASSNAME, TREE_SET_CLASSNAME, URI_CLASSNAME, VECTOR_CLASSNAME, VOID_CLASSNAME, ZERO_STRARRAY_ELEMENT_NAME, COLLECTION_ELEMENT_NAME, JAX_RPC_MAP_ENTRY_KEY_NAME, JAX_RPC_MAP_ENTRY_VALUE_NAME, JAXRPC_URI, QNAME_TYPE_ARRAY_LIST, QNAME_TYPE_COLLECTION, QNAME_TYPE_DATA_HANDLER, QNAME_TYPE_HASH_MAP, QNAME_TYPE_HASH_SET, QNAME_TYPE_HASHTABLE, QNAME_TYPE_IMAGE, QNAME_TYPE_JAX_RPC_MAP_ENTRY, QNAME_TYPE_LINKED_LIST, QNAME_TYPE_LIST, QNAME_TYPE_MAP, QNAME_TYPE_MIME_MULTIPART, QNAME_TYPE_PROPERTIES, QNAME_TYPE_SET, QNAME_TYPE_SOURCE, QNAME_TYPE_STACK, QNAME_TYPE_TREE_MAP, QNAME_TYPE_TREE_SET, QNAME_TYPE_VECTORFILE_TYPE_REMOTE_INTERFACE, FILE_TYPE_SERVICE, FILE_TYPE_WSDL| Modifier | Constructor and Description |
|---|---|
|
GeneratorBase() |
protected |
GeneratorBase(Model model,
Configuration config,
Properties properties) |
protected File sourceDir
protected File destDir
protected File nonclassDestDir
protected ProcessorEnvironment env
protected Model model
protected Service service
protected IndentingWriter out
protected boolean encodeTypes
protected boolean multiRefEncoding
protected boolean serializeInterfaces
protected SerializerWriterFactory writerFactory
protected SOAPVersion curSOAPVersion
protected String JAXRPCVersion
protected String targetVersion
protected boolean generateSerializableIf
protected boolean donotOverride
protected String servicePackage
public GeneratorBase()
protected GeneratorBase(Model model, Configuration config, Properties properties)
public void perform(Model model, Configuration config, Properties properties)
perform in interface ProcessorActionpublic abstract GeneratorBase getGenerator(Model model, Configuration config, Properties properties)
public abstract GeneratorBase getGenerator(Model model, Configuration config, Properties properties, SOAPVersion ver)
protected void doGeneration()
public void visit(Model model) throws Exception
visit in interface ModelVisitorExceptionpublic void visit(Service service) throws Exception
visit in interface ModelVisitorExceptionprotected void postVisitService(Service service) throws Exception
Exceptionpublic void visit(Port port) throws Exception
visit in interface ModelVisitorExceptionpublic void visit(Operation operation) throws Exception
visit in interface ModelVisitorExceptionprotected void preVisitOperation(Operation operation) throws Exception
Exceptionprotected void visitOperation(Operation operation) throws Exception
Exceptionprotected void postVisitOperation(Operation operation) throws Exception
Exceptionpublic void visit(Parameter param) throws Exception
visit in interface ModelVisitorExceptionprotected void preVisitParameter(Parameter param) throws Exception
Exceptionprotected void postVisitParameter(Parameter param) throws Exception
Exceptionpublic void visit(Block block) throws Exception
visit in interface ModelVisitorExceptionpublic void visit(Response response) throws Exception
visit in interface ModelVisitorExceptionprotected void preVisitResponse(Response response) throws Exception
Exceptionprotected void responseHeaderBlock(Block block) throws Exception
Exceptionprotected void responseAttachmentBlock(Block block) throws Exception
Exceptionprotected void postVisitResponse(Response response) throws Exception
Exceptionpublic void visit(Request request) throws Exception
visit in interface ModelVisitorExceptionprotected void requestHeaderBlock(Block block) throws Exception
Exceptionprotected void postVisitRequest(Request request) throws Exception
Exceptionpublic void visit(Fault fault) throws Exception
visit in interface ModelVisitorExceptionpublic void visit(SOAPCustomType type) throws Exception
visit in interface SOAPTypeVisitorExceptionprotected void preVisitSOAPCustomType(SOAPCustomType type) throws Exception
Exceptionprotected void visitSOAPCustomType(SOAPCustomType type) throws Exception
Exceptionprotected void postVisitSOAPCustomType(SOAPCustomType type) throws Exception
Exceptionpublic void visit(SOAPSimpleType type) throws Exception
visit in interface SOAPTypeVisitorExceptionprotected void preVisitSOAPSimpleType(SOAPSimpleType type) throws Exception
Exceptionprotected void visitSOAPSimpleType(SOAPSimpleType type) throws Exception
Exceptionprotected void postVisitSOAPSimpleType(SOAPSimpleType type) throws Exception
Exceptionpublic void visit(SOAPAnyType type) throws Exception
visit in interface SOAPTypeVisitorExceptionprotected void preVisitSOAPAnyType(SOAPAnyType type) throws Exception
Exceptionprotected void visitSOAPAnyType(SOAPAnyType type) throws Exception
Exceptionprotected void postVisitSOAPAnyType(SOAPAnyType type) throws Exception
Exceptionpublic void visit(SOAPEnumerationType type) throws Exception
visit in interface SOAPTypeVisitorExceptionprotected void preVisitSOAPEnumerationType(SOAPEnumerationType type) throws Exception
Exceptionprotected void visitSOAPEnumerationType(SOAPEnumerationType type) throws Exception
Exceptionprotected void postVisitSOAPEnumerationType(SOAPEnumerationType type) throws Exception
Exceptionpublic void visit(SOAPListType type) throws Exception
visit in interface SOAPTypeVisitorExceptionpublic void visit(SOAPArrayType type) throws Exception
visit in interface SOAPTypeVisitorExceptionprotected void preVisitSOAPArrayType(SOAPArrayType type) throws Exception
Exceptionprotected void visitSOAPArrayType(SOAPArrayType type) throws Exception
Exceptionprotected void postVisitSOAPArrayType(SOAPArrayType type) throws Exception
Exceptionpublic void visit(SOAPOrderedStructureType type) throws Exception
visit in interface SOAPTypeVisitorExceptionprotected void preVisitSOAPOrderedStructureType(SOAPOrderedStructureType type) throws Exception
Exceptionprotected void visitSOAPOrderedStructureType(SOAPOrderedStructureType type) throws Exception
Exceptionprotected void postVisitSOAPOrderedStructureType(SOAPOrderedStructureType type) throws Exception
Exceptionpublic void visit(SOAPUnorderedStructureType type) throws Exception
visit in interface SOAPTypeVisitorExceptionprotected void preVisitSOAPUnorderedStructureType(SOAPUnorderedStructureType type) throws Exception
Exceptionprotected void visitSOAPUnorderedStructureType(SOAPUnorderedStructureType type) throws Exception
Exceptionprotected void postVisitSOAPUnorderedStructureType(SOAPUnorderedStructureType type) throws Exception
Exceptionpublic void visit(RPCRequestOrderedStructureType type) throws Exception
visit in interface SOAPTypeVisitorExceptionprotected void preVisitRPCRequestOrderedStructureType(RPCRequestOrderedStructureType type) throws Exception
Exceptionprotected void visitRPCRequestOrderedStructureType(RPCRequestOrderedStructureType type) throws Exception
Exceptionprotected void postVisitRPCRequestOrderedStructureType(RPCRequestOrderedStructureType type) throws Exception
Exceptionpublic void visit(RPCRequestUnorderedStructureType type) throws Exception
visit in interface SOAPTypeVisitorExceptionprotected void preVisitRPCRequestUnorderedStructureType(RPCRequestUnorderedStructureType type) throws Exception
Exceptionprotected void visitRPCRequestUnorderedStructureType(RPCRequestUnorderedStructureType type) throws Exception
Exceptionprotected void postVisitRPCRequestUnorderedStructureType(RPCRequestUnorderedStructureType type) throws Exception
Exceptionpublic void visit(RPCResponseStructureType type) throws Exception
visit in interface SOAPTypeVisitorExceptionprotected void preVisitRPCResponseStructureType(RPCResponseStructureType type) throws Exception
Exceptionprotected void visitRPCResponseStructureType(RPCResponseStructureType type) throws Exception
Exceptionprotected void postVisitRPCResponseStructureType(RPCResponseStructureType type) throws Exception
Exceptionpublic void visit(SOAPStructureType type) throws Exception
Exceptionprotected void preVisitSOAPStructureType(SOAPStructureType type) throws Exception
Exceptionprotected void visitSOAPStructureType(SOAPStructureType type) throws Exception
Exceptionprotected void postVisitSOAPStructureType(SOAPStructureType type) throws Exception
Exceptionpublic void visit(LiteralListType type) throws Exception
visit in interface LiteralTypeVisitorExceptionprotected void visitLiteralListType(LiteralListType type) throws Exception
type - Exceptionprotected void visitSOAPListType(SOAPListType type) throws Exception
type - Exceptionpublic void visit(LiteralIDType type) throws Exception
visit in interface LiteralTypeVisitorExceptionpublic void visit(LiteralSimpleType type) throws Exception
visit in interface LiteralTypeVisitorExceptionprotected void preVisitLiteralSimpleType(LiteralSimpleType type) throws Exception
Exceptionprotected void visitLiteralSimpleType(LiteralSimpleType type) throws Exception
Exceptionprotected void postVisitLiteralSimpleType(LiteralSimpleType type) throws Exception
Exceptionpublic void visit(LiteralSequenceType type) throws Exception
visit in interface LiteralTypeVisitorExceptionprotected void preVisitLiteralSequenceType(LiteralSequenceType type) throws Exception
Exceptionprotected void visitLiteralSequenceType(LiteralSequenceType type) throws Exception
Exceptionprotected void postVisitLiteralSequenceType(LiteralSequenceType type) throws Exception
Exceptionpublic void visit(LiteralAllType type) throws Exception
visit in interface LiteralTypeVisitorExceptionprotected void preVisitLiteralAllType(LiteralAllType type) throws Exception
Exceptionprotected void visitLiteralAllType(LiteralAllType type) throws Exception
Exceptionprotected void postVisitLiteralAllType(LiteralAllType type) throws Exception
Exceptionpublic void visit(LiteralArrayType type) throws Exception
visit in interface LiteralTypeVisitorExceptionprotected void preVisitLiteralArrayType(LiteralArrayType type) throws Exception
Exceptionprotected void visitLiteralArrayType(LiteralArrayType type) throws Exception
Exceptionprotected void postVisitLiteralArrayType(LiteralArrayType type) throws Exception
Exceptionpublic void visit(LiteralArrayWrapperType type) throws Exception
visit in interface LiteralTypeVisitorExceptionprotected void preVisitLiteralArrayWrapperType(LiteralArrayWrapperType type) throws Exception
Exceptionprotected void visitLiteralArrayWrapperType(LiteralArrayWrapperType type) throws Exception
Exceptionprotected void postVisitLiteralArrayWrapperType(LiteralArrayWrapperType type) throws Exception
Exceptionpublic void visit(LiteralFragmentType type) throws Exception
visit in interface LiteralTypeVisitorExceptionprotected void preVisitLiteralFragmentType(LiteralFragmentType type) throws Exception
Exceptionprotected void visitLiteralFragmentType(LiteralFragmentType type) throws Exception
Exceptionprotected void postVisitLiteralFragmentType(LiteralFragmentType type) throws Exception
Exceptionpublic void visit(LiteralEnumerationType type) throws Exception
visit in interface LiteralTypeVisitorExceptionpublic void preVisitLiteralEnumerationType(LiteralEnumerationType type) throws Exception
Exceptionpublic void visitLiteralEnumerationType(LiteralEnumerationType type) throws Exception
Exceptionpublic void postVisitLiteralEnumerationType(LiteralEnumerationType type) throws Exception
Exceptionpublic void visit(LiteralAttachmentType type) throws Exception
visit in interface LiteralTypeVisitorExceptionprotected void preVisitLiteralAttachmentType(LiteralAttachmentType type) throws Exception
Exceptionprotected void visitLiteralAttachmentType(LiteralAttachmentType type) throws Exception
Exceptionprotected void postVisitLiteralAttachmentType(LiteralAttachmentType type) throws Exception
Exceptionprotected void writeWarning(IndentingWriter p) throws IOException
IOExceptionpublic static void writeWarning(IndentingWriter p, String version, String targetVersion) throws IOException
IOExceptionpublic void writePackage(IndentingWriter p, String classNameStr) throws IOException
IOExceptionpublic static void writePackage(IndentingWriter p, String classNameStr, String version, String sourceVersion) throws IOException
IOExceptionpublic static void writePackageOnly(IndentingWriter p, String classNameStr) throws IOException
IOExceptionprotected void log(String msg)
protected void warn(String key)
protected void info(String key)
protected static void fail(String key)
protected static void fail(Localizable arg)
protected static void fail(Throwable arg)
Copyright © 2017–2019 Eclipse Foundation. All rights reserved.