fieldName = pFieldName;
}
public boolean isCasting() { return !child.getObjectSG().getTypeSG().isComplex(); }
public void generate(JavaMethod pMethod, Object pValue) throws SAXException {
ObjectSG objectSG = child.getObjectSG();
JavaField f = pMethod.getJavaSource().newJavaField(fieldName + "_qname", QName.class);
f.setStatic(true);
f.setFinal(true);
f.addLine("new ", QName.class, "(", JavaSource.getQuoted(objectSG.getName().getNamespaceURI()),
", ", JavaSource.getQuoted(objectSG.getName().getLocalName()), ");");
if (objectSG.getTypeSG().isComplex()) {
pMethod.addLine(fieldName, ".marshal(", data, ", ", f, ", ", pValue, ");");
} else {
Object v = child.getObjectSG().getTypeSG().getSimpleTypeSG().getCastToString(pMethod, pValue, data);