if (spaceIndex != -1)
{
desc = desc.substring(spaceIndex + 1);
}
Element apiDesc = outputObject.createElement("apiDesc");
CDATASection cdata = outputObject.createCDATASection(asDocUtil.validateText(desc, "param", record.getAttribute("fullname")));
apiDesc.appendChild(cdata);
apiParam.appendChild(apiDesc);
asDocUtil.convertDescToDITA(apiDesc, oldNewNamesMap);
params.appendChild(apiParam);
paramFound = true;
}
}
else if (tagName.equals("param"))
{
}
else if (tagName.equals("includeExample"))
{
includeExamplesFound = true;
// get the <example> element after reading the file and
// creating a <codeblock>
// add the <example> to the detail node..
includeExamples.add(processIncludeExampleTag(record.getAttribute("fullname"), child.getTextContent()));
}
else if (tagName.equals("tiptext"))
{
tipTextFound = true;
Element apiTipText = outputObject.createElement("apiTipText");
CDATASection cdata = outputObject.createCDATASection(asDocUtil.validateText(child.getTextContent(), "tiptext", record.getAttribute("fullname")));
apiTipText.appendChild(cdata);
asDocUtil.convertDescToDITA(apiTipText, oldNewNamesMap);
apiTipTexts.appendChild(apiTipText);
}
else if (tagName.equals("copy"))
{
String copyRef = child.getTextContent();
copyRef = copyRef.replaceAll("[\\n\\s]", "");
if (copyRef.equals(""))
{
continue;
}
Element shortDescElement = asDocUtil.getElementByTagName(target, "shortdesc");
if (shortDescElement == null)
{
shortDescElement = outputObject.createElement("shortdesc");
target.appendChild(shortDescElement);
}
shortDescElement.setAttribute("conref", copyRef);
Element detailNode = asDocUtil.getDetailNode(target);
if (detailNode == null)
{
continue;
}
Element apiDesc = asDocUtil.getElementImmediateChildByTagName(detailNode, "apiDesc");
if (apiDesc != null)
{
apiDesc.setAttribute("conref", copyRef);
}
}
else if (tagName.equals("default"))
{
Element apiDefaultValue = outputObject.createElement("apiDefaultValue");
apiDefaultValue.setTextContent(child.getTextContent());
Element defNode = asDocUtil.getDefNode(target);
defNode.appendChild(apiDefaultValue);
}
else if (tagName.equals("inheritDoc"))
{
Element apiInheritDoc = outputObject.createElement("apiInheritDoc");
target.appendChild(apiInheritDoc);
}
else
{
customsFound = true;
customData = outputObject.createElement(child.getNodeName());
NodeList customsChildren = child.getChildNodes();
if (customsChildren != null && customsChildren.getLength() != 0)
{
if (customsChildren.item(0).getNodeType() == Node.CDATA_SECTION_NODE)
{
CDATASection cdata = outputObject.createCDATASection(child.getTextContent());
cdata.setData(((CDATASection)customsChildren.item(0)).getData());
customData.appendChild(cdata);
}
else
{
CDATASection cdata = outputObject.createCDATASection(child.getTextContent());
customData.appendChild(cdata);
}
}
}