org.apache.axis.wsdl.toJava
public class JavaBeanWriter extends JavaClassWriter
Modifier and Type | Field and Description |
---|---|
protected boolean |
enableDefaultConstructor
Field enableDefaultConstructor
|
protected boolean |
enableEquals
Field enableEquals
|
protected boolean |
enableFullConstructor
Field enableFullConstructor
|
protected boolean |
enableGetters
Field enableGetters
|
protected boolean |
enableHashCode
Field enableHashCode
|
protected boolean |
enableMemberFields
Field enableMemberFields
|
protected boolean |
enableSetters
Field enableSetters
|
protected boolean |
enableSimpleConstructors
Field enableSimpleConstructors
|
protected boolean |
enableToString
Field enableToString
|
protected java.util.Set |
enumerationTypes
Field enumerationTypes
|
protected JavaBeanHelperWriter |
helper
Field helper
|
protected boolean |
isAny
Field isAny
|
protected boolean |
isMixed
Field isMixed
|
protected java.util.Vector |
names
Field names
|
protected java.io.PrintWriter |
pw
Field pw
|
protected java.util.ArrayList |
simpleValueTypes
Field simpleValueTypes
|
className, namespaces, packageName
emitter, LINE_LENGTH
Modifier | Constructor and Description |
---|---|
protected |
JavaBeanWriter(Emitter emitter,
TypeEntry type,
java.util.Vector elements,
TypeEntry extendType,
java.util.Vector attributes,
JavaWriter helper)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
generate()
Generate a java source file and/or helper source file.
|
protected java.lang.String |
getBinaryTypeEncoderName(java.lang.String elementName)
Returns the class name that should be used to serialize and
deserialize this binary element
|
protected java.lang.String |
getClassModifiers()
Returns the appropriate extends text
|
protected TypeEntry |
getElementDecl(java.lang.String elementName)
Returns the TypeEntry of the given element
|
protected java.lang.String |
getExtendsText()
Returns the appropriate extends text
|
protected java.lang.String |
getImplementsText()
Returns the appropriate implements text
|
protected void |
preprocess()
Builds the names String vector.
|
protected void |
writeAccessMethods()
Writes the setter and getter methods
|
protected void |
writeDefaultConstructor()
Writes the default constructor.
|
protected void |
writeEqualsMethod()
Writes a general purpose equals method
|
protected void |
writeFileBody(java.io.PrintWriter pw)
Generate the binding for the given complex type.
|
protected void |
writeFileHeader(java.io.PrintWriter pw)
Write a common header, including the package name, the class
declaration, and the opening curly brace.
|
protected void |
writeFullConstructor()
Writes the full constructor.
|
protected void |
writeHashCodeMethod()
Writes a general purpose hashCode method.
|
protected void |
writeMemberFields()
Writes the member fields.
|
protected void |
writeMinimalConstructor() |
protected void |
writeSimpleConstructors()
Writes the constructors for SimpleTypes.
|
protected void |
writeSimpleTypeGetter(java.lang.String simpleValueType,
java.lang.String name,
java.lang.String returnString)
Method writeSimpleTypeGetter
|
protected void |
writeSimpleTypeSetter(java.lang.String simpleValueType)
Method writeSimpleTypeSetter
|
protected void |
writeToStringMethod()
Writes the toString method
Currently the toString method is only written for
simpleTypes.
|
getClassName, getClassText, getFileName, getPackage, registerFile, writeFileFooter, writeHeaderComments, writePackage
closePrintWriter, getJavadocDescriptionPart, getPrintWriter, isFileGenerated, verboseMessage, writeComment, writeComment
protected JavaBeanHelperWriter helper
protected java.util.Vector names
protected java.util.ArrayList simpleValueTypes
protected java.util.Set enumerationTypes
protected java.io.PrintWriter pw
protected boolean enableDefaultConstructor
protected boolean enableFullConstructor
protected boolean enableSimpleConstructors
protected boolean enableToString
protected boolean enableSetters
protected boolean enableGetters
protected boolean enableEquals
protected boolean enableHashCode
protected boolean enableMemberFields
protected boolean isAny
protected boolean isMixed
protected JavaBeanWriter(Emitter emitter, TypeEntry type, java.util.Vector elements, TypeEntry extendType, java.util.Vector attributes, JavaWriter helper)
emitter
- type
- The type representing this classelements
- Vector containing the Type and name of each propertyextendType
- The type representing the extended class (or null)attributes
- Vector containing the attribute types and nameshelper
- Helper class writerprotected void writeFileHeader(java.io.PrintWriter pw) throws java.io.IOException
writeFileHeader
in class JavaClassWriter
java.io.IOException
protected void writeFileBody(java.io.PrintWriter pw) throws java.io.IOException
writeFileBody
in class JavaWriter
pw
- java.io.IOException
protected void preprocess()
protected java.lang.String getBinaryTypeEncoderName(java.lang.String elementName)
protected TypeEntry getElementDecl(java.lang.String elementName)
protected java.lang.String getClassModifiers()
getClassModifiers
in class JavaClassWriter
protected java.lang.String getExtendsText()
getExtendsText
in class JavaClassWriter
protected java.lang.String getImplementsText()
getImplementsText
in class JavaClassWriter
protected void writeMemberFields()
protected void writeDefaultConstructor()
protected void writeMinimalConstructor()
protected void writeFullConstructor()
protected void writeSimpleConstructors()
protected void writeSimpleTypeGetter(java.lang.String simpleValueType, java.lang.String name, java.lang.String returnString)
simpleValueType
- name
- returnString
- protected void writeToStringMethod()
protected void writeSimpleTypeSetter(java.lang.String simpleValueType)
simpleValueType
- protected void writeAccessMethods()
protected void writeEqualsMethod()
protected void writeHashCodeMethod()
public void generate() throws java.io.IOException
generate
in interface Generator
generate
in class JavaWriter
java.io.IOException
Copyright ? 2005 Apache Web Services Project. All Rights Reserved.