return obj;
}
public void marshal(RegistryObject object,Element parent)
{
AuthToken authToken = (AuthToken)object;
Element element = parent.getOwnerDocument().createElement(AuthTokenHandler.TAG_NAME);
AbstractHandler handler = null;
String generic = authToken.getGeneric();
if ((generic != null) && (generic.trim().length() > 0))
{
element.setAttribute("generic",generic);
if (generic.equals(IRegistry.UDDI_V1_GENERIC))
element.setAttribute("xmlns",IRegistry.UDDI_V1_NAMESPACE);
else if (generic.equals(IRegistry.UDDI_V2_GENERIC))
element.setAttribute("xmlns",IRegistry.UDDI_V2_NAMESPACE);
else if (generic.equals(IRegistry.UDDI_V3_GENERIC))
element.setAttribute("xmlns",IRegistry.UDDI_V3_NAMESPACE);
}
else // Default to UDDI v2 values
{
element.setAttribute("generic",IRegistry.UDDI_V2_GENERIC);
element.setAttribute("xmlns",IRegistry.UDDI_V2_NAMESPACE);
}
String operator = authToken.getOperator();
if (operator != null)
element.setAttribute("operator",operator);
else
element.setAttribute("operator","");
AuthInfo authInfo = authToken.getAuthInfo();
if (authInfo != null)
{
handler = maker.lookup(AuthInfoHandler.TAG_NAME);
handler.marshal(authInfo,element);
}