5179: responses in out NOCOPY wf_responseList_t)
5180: IS
5181:
5182: p xmlparser.parser;
5183: doc xmldom.DOMDocument;
5184:
5185: nl xmldom.DOMNodeList;
5186: len1 number;
5187: len2 number;
5181:
5182: p xmlparser.parser;
5183: doc xmldom.DOMDocument;
5184:
5185: nl xmldom.DOMNodeList;
5186: len1 number;
5187: len2 number;
5188: n xmldom.DOMNode;
5189: m xmldom.DOMNode;
5184:
5185: nl xmldom.DOMNodeList;
5186: len1 number;
5187: len2 number;
5188: n xmldom.DOMNode;
5189: m xmldom.DOMNode;
5190: nnm xmldom.DOMNamedNodeMap;
5191:
5192: fromAddress varchar2(4000);
5185: nl xmldom.DOMNodeList;
5186: len1 number;
5187: len2 number;
5188: n xmldom.DOMNode;
5189: m xmldom.DOMNode;
5190: nnm xmldom.DOMNamedNodeMap;
5191:
5192: fromAddress varchar2(4000);
5193: attrname varchar2(4000);
5186: len1 number;
5187: len2 number;
5188: n xmldom.DOMNode;
5189: m xmldom.DOMNode;
5190: nnm xmldom.DOMNamedNodeMap;
5191:
5192: fromAddress varchar2(4000);
5193: attrname varchar2(4000);
5194: attrval varchar2(4000);
5228: -- get document
5229: doc := xmlparser.getDocument(p);
5230:
5231: -- get all elements
5232: nl := xmldom.getElementsByTagName(doc, '*');
5233: len1 := xmldom.getLength(nl);
5234:
5235: -- loop through elements
5236: for j in 0..len1-1 loop
5229: doc := xmlparser.getDocument(p);
5230:
5231: -- get all elements
5232: nl := xmldom.getElementsByTagName(doc, '*');
5233: len1 := xmldom.getLength(nl);
5234:
5235: -- loop through elements
5236: for j in 0..len1-1 loop
5237:
5234:
5235: -- loop through elements
5236: for j in 0..len1-1 loop
5237:
5238: n := xmldom.item(nl, j);
5239: node_name := xmldom.getNodeName(n);
5240:
5241: step := 'Processing ['||node_name||']';
5242: if node_name = 'NOTIFICATION' then
5235: -- loop through elements
5236: for j in 0..len1-1 loop
5237:
5238: n := xmldom.item(nl, j);
5239: node_name := xmldom.getNodeName(n);
5240:
5241: step := 'Processing ['||node_name||']';
5242: if node_name = 'NOTIFICATION' then
5243:
5241: step := 'Processing ['||node_name||']';
5242: if node_name = 'NOTIFICATION' then
5243:
5244: -- get all attributes of element
5245: nnm := xmldom.getAttributes(n);
5246:
5247: if (xmldom.isNull(nnm) = FALSE) then
5248:
5249: len2 := xmldom.getLength(nnm);
5243:
5244: -- get all attributes of element
5245: nnm := xmldom.getAttributes(n);
5246:
5247: if (xmldom.isNull(nnm) = FALSE) then
5248:
5249: len2 := xmldom.getLength(nnm);
5250:
5251: -- loop through attributes
5245: nnm := xmldom.getAttributes(n);
5246:
5247: if (xmldom.isNull(nnm) = FALSE) then
5248:
5249: len2 := xmldom.getLength(nnm);
5250:
5251: -- loop through attributes
5252: for i in 0..len2-1 loop
5253:
5250:
5251: -- loop through attributes
5252: for i in 0..len2-1 loop
5253:
5254: m := xmldom.item(nnm, i);
5255: attrname := xmldom.getNodeName(m);
5256:
5257: step := 'Processing ['||node_name||'] ['||attrname||']';
5258:
5251: -- loop through attributes
5252: for i in 0..len2-1 loop
5253:
5254: m := xmldom.item(nnm, i);
5255: attrname := xmldom.getNodeName(m);
5256:
5257: step := 'Processing ['||node_name||'] ['||attrname||']';
5258:
5259: if attrname = 'node' then
5257: step := 'Processing ['||node_name||'] ['||attrname||']';
5258:
5259: if attrname = 'node' then
5260:
5261: attrval := xmldom.getNodeValue(m);
5262: node := attrval;
5263: elsif attrname = 'version' then
5264:
5265: attrval := xmldom.getNodeValue(m);
5261: attrval := xmldom.getNodeValue(m);
5262: node := attrval;
5263: elsif attrname = 'version' then
5264:
5265: attrval := xmldom.getNodeValue(m);
5266: begin
5267: version := to_number(attrval);
5268: exception
5269: when others then
5283: elsif node_name = 'NAME' then
5284:
5285: if from_node_found then
5286:
5287: n := xmldom.getFirstChild(n);
5288:
5289: if ((not xmldom.isNull(n))
5290: and (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5291:
5285: if from_node_found then
5286:
5287: n := xmldom.getFirstChild(n);
5288:
5289: if ((not xmldom.isNull(n))
5290: and (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5291:
5292: node_data := xmlDom.getNodeValue(n);
5293: fromRole := node_data;
5286:
5287: n := xmldom.getFirstChild(n);
5288:
5289: if ((not xmldom.isNull(n))
5290: and (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5291:
5292: node_data := xmlDom.getNodeValue(n);
5293: fromRole := node_data;
5294:
5288:
5289: if ((not xmldom.isNull(n))
5290: and (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5291:
5292: node_data := xmlDom.getNodeValue(n);
5293: fromRole := node_data;
5294:
5295: end if;
5296:
5301: if from_node_found then
5302:
5303: from_node_found := FALSE;
5304:
5305: n := xmldom.getFirstChild(n);
5306:
5307: if ((not xmldom.isNull(n))
5308: and (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5309:
5303: from_node_found := FALSE;
5304:
5305: n := xmldom.getFirstChild(n);
5306:
5307: if ((not xmldom.isNull(n))
5308: and (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5309:
5310: node_data := xmlDom.getNodeValue(n);
5311: fromAddress := node_data;
5304:
5305: n := xmldom.getFirstChild(n);
5306:
5307: if ((not xmldom.isNull(n))
5308: and (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5309:
5310: node_data := xmlDom.getNodeValue(n);
5311: fromAddress := node_data;
5312:
5306:
5307: if ((not xmldom.isNull(n))
5308: and (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5309:
5310: node_data := xmlDom.getNodeValue(n);
5311: fromAddress := node_data;
5312:
5313: fromRole := '"'||fromRole||'" <'||fromAddress||'>';
5314:
5318:
5319: elsif node_name = 'ATTRIBUTE' then
5320:
5321: -- get all attributes of element
5322: nnm := xmldom.getAttributes(n);
5323:
5324: if (xmldom.isNull(nnm) = FALSE) then
5325:
5326: attribute_found := FALSE;
5320:
5321: -- get all attributes of element
5322: nnm := xmldom.getAttributes(n);
5323:
5324: if (xmldom.isNull(nnm) = FALSE) then
5325:
5326: attribute_found := FALSE;
5327: response_attr_name := '';
5328: response_attr_val := '';
5328: response_attr_val := '';
5329: response_attr_type := '';
5330: response_attr_format := '';
5331:
5332: len2 := xmldom.getLength(nnm);
5333:
5334: -- loop through attributes
5335: for i in 0..len2-1 loop
5336:
5333:
5334: -- loop through attributes
5335: for i in 0..len2-1 loop
5336:
5337: m := xmldom.item(nnm, i);
5338: attrname := xmldom.getNodeName(m);
5339:
5340: step := 'Processing ['||node_name||'] ['||attrname||']';
5341:
5334: -- loop through attributes
5335: for i in 0..len2-1 loop
5336:
5337: m := xmldom.item(nnm, i);
5338: attrname := xmldom.getNodeName(m);
5339:
5340: step := 'Processing ['||node_name||'] ['||attrname||']';
5341:
5342: if attrname = 'name' then
5341:
5342: if attrname = 'name' then
5343:
5344: attribute_found := TRUE;
5345: attrval := xmldom.getNodeValue(m);
5346: response_attr_name := attrval;
5347:
5348: elsif attrname = 'type' then
5349:
5346: response_attr_name := attrval;
5347:
5348: elsif attrname = 'type' then
5349:
5350: attrval := xmldom.getNodeValue(m);
5351: response_attr_type := attrval;
5352:
5353: elsif attrname = 'format' then
5354:
5351: response_attr_type := attrval;
5352:
5353: elsif attrname = 'format' then
5354:
5355: attrval := xmldom.getNodeValue(m);
5356: response_attr_format := attrval;
5357:
5358: end if;
5359:
5360: end loop;
5361:
5362: if attribute_found then
5363:
5364: n := xmldom.getFirstChild(n);
5365:
5366: if ((not xmldom.isNull(n)) and
5367: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5368:
5362: if attribute_found then
5363:
5364: n := xmldom.getFirstChild(n);
5365:
5366: if ((not xmldom.isNull(n)) and
5367: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5368:
5369: node_data := substrb(xmlDom.getNodeValue(n), 1, 32000);
5370: response_attr_val := node_data;
5363:
5364: n := xmldom.getFirstChild(n);
5365:
5366: if ((not xmldom.isNull(n)) and
5367: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5368:
5369: node_data := substrb(xmlDom.getNodeValue(n), 1, 32000);
5370: response_attr_val := node_data;
5371: end if;
5365:
5366: if ((not xmldom.isNull(n)) and
5367: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5368:
5369: node_data := substrb(xmlDom.getNodeValue(n), 1, 32000);
5370: response_attr_val := node_data;
5371: end if;
5372:
5373: response_count := response_count + 1;
5385: step := 'Fishished {'||step||'}';
5386:
5387: end loop;
5388:
5389: if (not xmldom.isNull(doc)) then
5390: xmldom.freeDocument (doc);
5391: end if;
5392:
5393: xmlparser.freeParser (p);
5386:
5387: end loop;
5388:
5389: if (not xmldom.isNull(doc)) then
5390: xmldom.freeDocument (doc);
5391: end if;
5392:
5393: xmlparser.freeParser (p);
5394:
5393: xmlparser.freeParser (p);
5394:
5395: exception
5396:
5397: when xmldom.INDEX_SIZE_ERR then
5398: wf_core.context('WF_XML','getResponseDetails', step);
5399: raise;
5400:
5401: when xmldom.DOMSTRING_SIZE_ERR then
5397: when xmldom.INDEX_SIZE_ERR then
5398: wf_core.context('WF_XML','getResponseDetails', step);
5399: raise;
5400:
5401: when xmldom.DOMSTRING_SIZE_ERR then
5402: wf_core.context('WF_XML','getResponseDetails', step);
5403: raise;
5404:
5405: when xmldom.HIERARCHY_REQUEST_ERR then
5401: when xmldom.DOMSTRING_SIZE_ERR then
5402: wf_core.context('WF_XML','getResponseDetails', step);
5403: raise;
5404:
5405: when xmldom.HIERARCHY_REQUEST_ERR then
5406: wf_core.context('WF_XML','getResponseDetails', step);
5407: raise;
5408:
5409: when xmldom.WRONG_DOCUMENT_ERR then
5405: when xmldom.HIERARCHY_REQUEST_ERR then
5406: wf_core.context('WF_XML','getResponseDetails', step);
5407: raise;
5408:
5409: when xmldom.WRONG_DOCUMENT_ERR then
5410: wf_core.context('WF_XML','getResponseDetails', step);
5411: raise;
5412:
5413: when xmldom.INVALID_CHARACTER_ERR then
5409: when xmldom.WRONG_DOCUMENT_ERR then
5410: wf_core.context('WF_XML','getResponseDetails', step);
5411: raise;
5412:
5413: when xmldom.INVALID_CHARACTER_ERR then
5414: wf_core.context('WF_XML','getResponseDetails', step);
5415: raise;
5416:
5417: when xmldom.NO_DATA_ALLOWED_ERR then
5413: when xmldom.INVALID_CHARACTER_ERR then
5414: wf_core.context('WF_XML','getResponseDetails', step);
5415: raise;
5416:
5417: when xmldom.NO_DATA_ALLOWED_ERR then
5418: wf_core.context('WF_XML','getResponseDetails', step);
5419: raise;
5420:
5421: when xmldom.NO_MODIFICATION_ALLOWED_ERR then
5417: when xmldom.NO_DATA_ALLOWED_ERR then
5418: wf_core.context('WF_XML','getResponseDetails', step);
5419: raise;
5420:
5421: when xmldom.NO_MODIFICATION_ALLOWED_ERR then
5422: wf_core.context('WF_XML','getResponseDetails', step);
5423: raise;
5424:
5425: when xmldom.NOT_FOUND_ERR then
5421: when xmldom.NO_MODIFICATION_ALLOWED_ERR then
5422: wf_core.context('WF_XML','getResponseDetails', step);
5423: raise;
5424:
5425: when xmldom.NOT_FOUND_ERR then
5426: wf_core.context('WF_XML','getResponseDetails', step);
5427: raise;
5428:
5429: when xmldom.NOT_SUPPORTED_ERR then
5425: when xmldom.NOT_FOUND_ERR then
5426: wf_core.context('WF_XML','getResponseDetails', step);
5427: raise;
5428:
5429: when xmldom.NOT_SUPPORTED_ERR then
5430: wf_core.context('WF_XML','getResponseDetails', step);
5431: raise;
5432:
5433: when xmldom.INUSE_ATTRIBUTE_ERR then
5429: when xmldom.NOT_SUPPORTED_ERR then
5430: wf_core.context('WF_XML','getResponseDetails', step);
5431: raise;
5432:
5433: when xmldom.INUSE_ATTRIBUTE_ERR then
5434: wf_core.context('WF_XML','getResponseDetails', step);
5435: raise;
5436:
5437: when others then
5874: pFromRole OUT NOCOPY varchar2,
5875: pFromAddress OUT NOCOPY varchar2)
5876: is
5877: p xmlparser.parser;
5878: doc xmldom.DOMDocument;
5879:
5880: nl xmldom.DOMNodeList;
5881: len1 number;
5882: len2 number;
5876: is
5877: p xmlparser.parser;
5878: doc xmldom.DOMDocument;
5879:
5880: nl xmldom.DOMNodeList;
5881: len1 number;
5882: len2 number;
5883: n xmldom.DOMNode;
5884: m xmldom.DOMNode;
5879:
5880: nl xmldom.DOMNodeList;
5881: len1 number;
5882: len2 number;
5883: n xmldom.DOMNode;
5884: m xmldom.DOMNode;
5885: nnm xmldom.DOMNamedNodeMap;
5886:
5887: from_node_found boolean := FALSE;
5880: nl xmldom.DOMNodeList;
5881: len1 number;
5882: len2 number;
5883: n xmldom.DOMNode;
5884: m xmldom.DOMNode;
5885: nnm xmldom.DOMNamedNodeMap;
5886:
5887: from_node_found boolean := FALSE;
5888: fromRole varchar2(4000);
5881: len1 number;
5882: len2 number;
5883: n xmldom.DOMNode;
5884: m xmldom.DOMNode;
5885: nnm xmldom.DOMNamedNodeMap;
5886:
5887: from_node_found boolean := FALSE;
5888: fromRole varchar2(4000);
5889: fromAddress varchar2(4000);
5913: -- get document
5914: doc := xmlparser.getDocument(p);
5915:
5916: -- get all elements
5917: nl := xmldom.getElementsByTagName(doc, '*');
5918: len1 := xmldom.getLength(nl);
5919:
5920: -- loop through elements
5921: for j in 0..len1-1 loop
5914: doc := xmlparser.getDocument(p);
5915:
5916: -- get all elements
5917: nl := xmldom.getElementsByTagName(doc, '*');
5918: len1 := xmldom.getLength(nl);
5919:
5920: -- loop through elements
5921: for j in 0..len1-1 loop
5922: n := xmldom.item(nl, j);
5918: len1 := xmldom.getLength(nl);
5919:
5920: -- loop through elements
5921: for j in 0..len1-1 loop
5922: n := xmldom.item(nl, j);
5923: node_name := xmldom.getNodeName(n);
5924:
5925: if node_name = 'NOTIFICATION' then
5926: -- get all attributes of element
5919:
5920: -- loop through elements
5921: for j in 0..len1-1 loop
5922: n := xmldom.item(nl, j);
5923: node_name := xmldom.getNodeName(n);
5924:
5925: if node_name = 'NOTIFICATION' then
5926: -- get all attributes of element
5927: nnm := xmldom.getAttributes(n);
5923: node_name := xmldom.getNodeName(n);
5924:
5925: if node_name = 'NOTIFICATION' then
5926: -- get all attributes of element
5927: nnm := xmldom.getAttributes(n);
5928:
5929: if (xmldom.isNull(nnm) = FALSE) then
5930:
5931: len2 := xmldom.getLength(nnm);
5925: if node_name = 'NOTIFICATION' then
5926: -- get all attributes of element
5927: nnm := xmldom.getAttributes(n);
5928:
5929: if (xmldom.isNull(nnm) = FALSE) then
5930:
5931: len2 := xmldom.getLength(nnm);
5932:
5933: -- loop through attributes
5927: nnm := xmldom.getAttributes(n);
5928:
5929: if (xmldom.isNull(nnm) = FALSE) then
5930:
5931: len2 := xmldom.getLength(nnm);
5932:
5933: -- loop through attributes
5934: for i in 0..len2-1 loop
5935: m := xmldom.item(nnm, i);
5931: len2 := xmldom.getLength(nnm);
5932:
5933: -- loop through attributes
5934: for i in 0..len2-1 loop
5935: m := xmldom.item(nnm, i);
5936: attrname := xmldom.getNodeName(m);
5937: if attrname = 'node' then
5938: attrval := xmldom.getNodeValue(m);
5939: pnode := attrval;
5932:
5933: -- loop through attributes
5934: for i in 0..len2-1 loop
5935: m := xmldom.item(nnm, i);
5936: attrname := xmldom.getNodeName(m);
5937: if attrname = 'node' then
5938: attrval := xmldom.getNodeValue(m);
5939: pnode := attrval;
5940: -- exit;
5934: for i in 0..len2-1 loop
5935: m := xmldom.item(nnm, i);
5936: attrname := xmldom.getNodeName(m);
5937: if attrname = 'node' then
5938: attrval := xmldom.getNodeValue(m);
5939: pnode := attrval;
5940: -- exit;
5941: elsif attrname = 'language' then
5942: attrval := xmldom.getNodeValue(m);
5938: attrval := xmldom.getNodeValue(m);
5939: pnode := attrval;
5940: -- exit;
5941: elsif attrname = 'language' then
5942: attrval := xmldom.getNodeValue(m);
5943: planguage := attrval;
5944: elsif attrname = 'territory' then
5945: attrval := xmldom.getNodeValue(m);
5946: pterritory := attrval;
5941: elsif attrname = 'language' then
5942: attrval := xmldom.getNodeValue(m);
5943: planguage := attrval;
5944: elsif attrname = 'territory' then
5945: attrval := xmldom.getNodeValue(m);
5946: pterritory := attrval;
5947: elsif attrname = 'codeset' then
5948: attrval := xmldom.getNodeValue(m);
5949: pcodeset := attrval;
5944: elsif attrname = 'territory' then
5945: attrval := xmldom.getNodeValue(m);
5946: pterritory := attrval;
5947: elsif attrname = 'codeset' then
5948: attrval := xmldom.getNodeValue(m);
5949: pcodeset := attrval;
5950: end if;
5951:
5952: end loop;
5951:
5952: end loop;
5953: end if;
5954: elsif node_name = 'SUBJECT' then
5955: n := xmldom.getFirstChild(n);
5956:
5957: if ((not xmldom.isNull(n)) and
5958: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5959:
5953: end if;
5954: elsif node_name = 'SUBJECT' then
5955: n := xmldom.getFirstChild(n);
5956:
5957: if ((not xmldom.isNull(n)) and
5958: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5959:
5960: node_data := xmlDom.getNodeValue(n);
5961: psubject := node_data;
5954: elsif node_name = 'SUBJECT' then
5955: n := xmldom.getFirstChild(n);
5956:
5957: if ((not xmldom.isNull(n)) and
5958: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5959:
5960: node_data := xmlDom.getNodeValue(n);
5961: psubject := node_data;
5962:
5956:
5957: if ((not xmldom.isNull(n)) and
5958: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5959:
5960: node_data := xmlDom.getNodeValue(n);
5961: psubject := node_data;
5962:
5963: end if;
5964:
5966: from_node_found := TRUE;
5967:
5968: elsif node_name = 'NAME' then
5969: if from_node_found then
5970: n := xmldom.getFirstChild(n);
5971:
5972: if ((not xmldom.isNull(n)) and
5973: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5974:
5968: elsif node_name = 'NAME' then
5969: if from_node_found then
5970: n := xmldom.getFirstChild(n);
5971:
5972: if ((not xmldom.isNull(n)) and
5973: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5974:
5975: node_data := xmlDom.getNodeValue(n);
5976: pfromRole := node_data;
5969: if from_node_found then
5970: n := xmldom.getFirstChild(n);
5971:
5972: if ((not xmldom.isNull(n)) and
5973: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5974:
5975: node_data := xmlDom.getNodeValue(n);
5976: pfromRole := node_data;
5977:
5971:
5972: if ((not xmldom.isNull(n)) and
5973: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5974:
5975: node_data := xmlDom.getNodeValue(n);
5976: pfromRole := node_data;
5977:
5978: end if;
5979: end if;
5981: if from_node_found then
5982:
5983: from_node_found := FALSE;
5984:
5985: n := xmldom.getFirstChild(n);
5986:
5987: if ((not xmldom.isNull(n)) and
5988: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5989:
5983: from_node_found := FALSE;
5984:
5985: n := xmldom.getFirstChild(n);
5986:
5987: if ((not xmldom.isNull(n)) and
5988: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5989:
5990: node_data := xmlDom.getNodeValue(n);
5991: pfromAddress := node_data;
5984:
5985: n := xmldom.getFirstChild(n);
5986:
5987: if ((not xmldom.isNull(n)) and
5988: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5989:
5990: node_data := xmlDom.getNodeValue(n);
5991: pfromAddress := node_data;
5992:
5986:
5987: if ((not xmldom.isNull(n)) and
5988: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
5989:
5990: node_data := xmlDom.getNodeValue(n);
5991: pfromAddress := node_data;
5992:
5993: end if;
5994: end if;
5993: end if;
5994: end if;
5995: elsif node_name = 'MESSAGE' then
5996:
5997: nnm := xmldom.getAttributes(n);
5998:
5999: if (xmldom.isNull(nnm) = FALSE) then
6000:
6001: len2 := xmldom.getLength(nnm);
5995: elsif node_name = 'MESSAGE' then
5996:
5997: nnm := xmldom.getAttributes(n);
5998:
5999: if (xmldom.isNull(nnm) = FALSE) then
6000:
6001: len2 := xmldom.getLength(nnm);
6002:
6003: -- loop through attributes
5997: nnm := xmldom.getAttributes(n);
5998:
5999: if (xmldom.isNull(nnm) = FALSE) then
6000:
6001: len2 := xmldom.getLength(nnm);
6002:
6003: -- loop through attributes
6004: for i in 0..len2-1 loop
6005: m := xmldom.item(nnm, i);
6001: len2 := xmldom.getLength(nnm);
6002:
6003: -- loop through attributes
6004: for i in 0..len2-1 loop
6005: m := xmldom.item(nnm, i);
6006: attrname := xmldom.getNodeName(m);
6007: if upper(attrname) = 'CONTENT-TYPE' then
6008: attrval := xmldom.getNodeValue(m);
6009: contentType := attrval;
6002:
6003: -- loop through attributes
6004: for i in 0..len2-1 loop
6005: m := xmldom.item(nnm, i);
6006: attrname := xmldom.getNodeName(m);
6007: if upper(attrname) = 'CONTENT-TYPE' then
6008: attrval := xmldom.getNodeValue(m);
6009: contentType := attrval;
6010: exit;
6004: for i in 0..len2-1 loop
6005: m := xmldom.item(nnm, i);
6006: attrname := xmldom.getNodeName(m);
6007: if upper(attrname) = 'CONTENT-TYPE' then
6008: attrval := xmldom.getNodeValue(m);
6009: contentType := attrval;
6010: exit;
6011: end if;
6012: end loop;
6012: end loop;
6013: textPlain_found := upper(contentType) = 'TEXT/PLAIN';
6014: end if;
6015: if textPlain_found then
6016: n := xmldom.getFirstChild(n);
6017:
6018: if ((not xmldom.isNull(n)) and
6019: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
6020:
6014: end if;
6015: if textPlain_found then
6016: n := xmldom.getFirstChild(n);
6017:
6018: if ((not xmldom.isNull(n)) and
6019: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
6020:
6021: node_data := xmlDom.getNodeValue(n);
6022: pcontentBody := node_data;
6015: if textPlain_found then
6016: n := xmldom.getFirstChild(n);
6017:
6018: if ((not xmldom.isNull(n)) and
6019: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
6020:
6021: node_data := xmlDom.getNodeValue(n);
6022: pcontentBody := node_data;
6023: end if;
6017:
6018: if ((not xmldom.isNull(n)) and
6019: (xmldom.getNodeType(n) = xmldom.TEXT_NODE)) then
6020:
6021: node_data := xmlDom.getNodeValue(n);
6022: pcontentBody := node_data;
6023: end if;
6024: end if;
6025: end if;