Generating XML Document by giving Object as input
Hi all,
I have to give some object as input for generating XML Document.Basing on the data in the object the XML file has to be generated.
Please give me your guidance in this issue.
Thanks&Regards
Madhu
Madhu,
You may:
1. Generate XML Document manually with DOM API
2. Use some complex lib like implementation of <a href="http://java.sun.com/webservices/jaxb/">JAXB</a> with ad-hoc control over format.
3. Use some simple library like <a href="http://xstream.codehaus.org/">XStream</a> with minimal format control.
Valery Silaev
EPAM Systems
http://www.NetWeaverTeam.com
Similar Messages
-
How to validate generated XML-Document in Memory by XML-Schema?
Hi all!
I have the following problem:
I am generating a Document using the DOM delivered with Xerces 2.6.2.
Before I'll send the generated xml-document through network to another system I have to check with my xml-schema if the document is correct.
In the DOM-FAQ I found an "example" trying to explain how it should work. But with this example the problems begin.
I am creating my document with this method:
public void createDocument() {
myDOM = DOMImplementationImpl.getDOMImplementation();
doc = myDOM.createDocument("", "documentData", null);
root = doc.getDocumentElement();
root.setAttribute(
"xmlns:xsi",
"http://www.w3.org/2001/XMLSchema-instance");
// root.setAttribute("xsi:noNamespaceSchemaLocation", "myScheme.xsd");
domConfig = ((DocumentImpl) doc).getDomConfig();
domConfig.setParameter(
"schema-location",
"file:///d:/workspace/XMLProject/WebContent/WEB-INF/myScheme.xsd");
domConfig.setParameter("error-handler", new EHandler());
domConfig.setParameter("validate", Boolean.TRUE);
}In the line getting the domConfig, it is getting differeing to the example: The example is like this:
import org.w3c.dom.Document;
import org.w3c.dom.DOMConfiguration;
import org.w3c.dom.ls.LSParser;
Document document = builder.parseURI("data/personal-schema.xml");
DOMConfiguration config = document.getConfig();
config.setParameter("error-handler",new MyErrorHandler());
config.setParameter("validate", Boolean.TRUE);
document.normalizeDocument();They get the DOM-Configuration from the document-Object, but my document-Object has no "getConfig()" and only after type-casting I get a getDomConfig()-Method to get the configuration.
Then I fill my document and call
((DocumentImpl) doc).normalizeDocument();When I run my Application I get the following error:
org.w3c.dom.DOMException: FEATURE_NOT_SUPPORTED: The parameter schema-location is recognized but the requested value cannot be set.
at org.apache.xerces.dom.DOMConfigurationImpl.setParameter(Unknown Source)
at xmlProject.createDocument(Convert.java:63)
at xmlProject.Convert.main(Convert.java:154)I tried several ways to get the validation without success.
The next question is how I should refer to my xml-schema (which path) and where to place it relative to my jar I will generate, because I will have no webserver I could place it on.
Has anyone any experience with validating a document created and not placed on disc?
I have also another question to SAX: I read, that it is reading a document without saving it in the memory. I think this means that if I am validating it by SAX it will be read once and for parsing it will be read a second time. If I would transfer the document over an tcp-connection, I only have the document once in my inputstream and after validation it would be consumed I think. But what can I parse then? Or did I missed a detail with the function of the SAX?
Thank you for your help!
Yours
Christianstatic final String schemaSource = argv[0];
static final String JAXP_SCHEMA_SOURCE =
"http://java.sun.com/xml/jaxp/properties/schemaSource";
DocumentBuilderFactory factory =
DocumentBuilderFactory.newInstance();
factory.setAttribute(JAXP_SCHEMA_SOURCE,
new File(schemaSource)); -
Content of generated XML document to variable - Oracle ...
Hello everybody,
here is sample code which generates XML document:
* This is a sample application program which is built using the
* classes generated by the XML DTD Class Generator. The External DTD
* File "Widl.dtd" or the XML document which "Widl.xml" which is compliant
* to Widl.dtd is used to generate the classes. The application
* SampleMain.java is used to generate the classes which takes the DTD
* or XML document as input parameters to generate classes.
import oracle.xml.classgen.CGNode;
import oracle.xml.classgen.CGDocument;
import oracle.xml.classgen.DTDClassGenerator;
import oracle.xml.classgen.InvalidContentException;
import oracle.xml.parser.v2.DTD;
public class TestWidl
public static void main (String args[])
try
WIDL w1 = new WIDL();
DTD dtd = w1.getDTDNode();
w1.setNAME("WIDL1");
w1.setVERSION(WIDL.VERSION_1_0);
SERVICE s1 = new SERVICE("Service1", "Service_URL");
s1.setINPUT("File");
s1.setOUTPUT("File");
BINDING b1 = new BINDING("Binding1");
b1.setTYPE(BINDING.TYPE_INPUT);
BINDING b2 = new BINDING("Binding2");
b2.setTYPE(BINDING.TYPE_OUTPUT);
VARIABLE v1 = new VARIABLE("Variable1", VARIABLE.NULLOK_FALSE);
v1.setTYPE(VARIABLE.TYPE_STRING);
v1.setUSAGE(VARIABLE.USAGE_INTERNAL);
v1.setVALUE("value");
VARIABLE v2 = new VARIABLE("Variable2", VARIABLE.NULLOK_TRUE);
v2.setTYPE(VARIABLE.TYPE_STRING1);
v2.setUSAGE(VARIABLE.USAGE_HEADER);
VARIABLE v3 = new VARIABLE("Variable3", VARIABLE.NULLOK_FALSE);
v3.setTYPE(VARIABLE.TYPE_STRING2);
v3.setUSAGE(VARIABLE.USAGE_FUNCTION);
v3.setMASK("mask");
CONDITION c1 = new CONDITION("CRef1", "CMatch1");
c1.setSERVICE("Service1");
c1.setTYPE(CONDITION.TYPE_SUCCESS);
CONDITION c2 = new CONDITION("CRef2", "CMatch2");
c2.setTYPE(CONDITION.TYPE_RETRY);
CONDITION c3 = new CONDITION("CRef3", "CMatch3");
c3.setSERVICE("Service3");
c3.setTYPE(CONDITION.TYPE_FAILURE);
REGION r1 = new REGION("Region1", "Start", "End");
b1.addNode(r1);
b1.addNode(v1);
b1.addNode(c1);
b1.addNode(v2);
b2.addNode(c2);
b2.addNode(v3);
w1.addNode(s1);
w1.addNode(b1);
w1.addNode(b2);
w1.validateContent();
w1.print(System.out);
catch (Exception e)
System.out.println(e.toString());
e.printStackTrace();
I see the method w1.print(System.out) which shows content of xml to console. But how can I store xml to some String variable? Thank you in advance.
Jan :)If there is a version of the "print" method that can write to a Writer, then:StringWriter sw = new StringWriter();
w1.print(sw);
String result = sw.toString();But if you can only write to an OutputStream then:ByteArrayOutputStream baos = new ByteArrayOutputStream();
w1.print(baos);
String result = new String(baos.toByteArray(), encoding);where "encoding" is a string containing the name of the encoding used to write the XML. Possibly you can control that via "w1.setENCODING(something)" or some other way. -
Question about generate xml document
Hi, I'm new to xml can anyone introduce me some tools to generate xml documents? or some faster way to generate xml documents.
a good site for the info www.xml.com or www.oasis.org
xml-spy is a good tool -
Hi,
My problem is about generating XML document. I'd like to be able to generate automaticaly (like what we can get at this kind of URL http://xdbserver:8080/oradb/USER/table_name) XML documents for any relational tables, I want the document being schema based and I want to store them in XDB in the repository.
I do not really matter at the time the way the xml is generated (I just do not want that it takes hours). Is there a way to do that with PL/SQL package or with a java classes?
Thanks in advance.
Vlad1)I'm using this PL/SQL proc to create XML :
(table_name in VARCHAR2)as --generation d'un fichier xml basé sur un schéma pour la table dont le nom est passé en paramètre
qryCtx DBMS_XMLGEN.ctxHandle;
result XMLType;
begin
qryCtx := dbms_xmlgen.newContext('SELECT * from VLAD.' || table_name);
-- set the row header to be EMPLOYEE
DBMS_XMLGEN.setRowTag(qryCtx, table_name);
-- now get the result
result := DBMS_XMLGEN.getXMLType(qryCtx,2); --2 for XMLSchema (1 for a DTD)
--insertion de result dans la table tempo
insert into tempo values(result);
--close context
DBMS_XMLGEN.closeContext(qryCtx);
exception
when others then
dbms_output.put_line(TO_CHAR(sqlerrm));
end;
I saw in the doc that DBMS_XMLGEN.getXMLType(qryCtx,2) with the "2" was for schema but what does it do exactly, does it generate a schema against the table_name?
2)I'd like to put the result which is XMLType in a XML file in the server, is there a way to do it with UTL FILE?
Vlad -
Urgetnt:Generate XML Document from Oracle Tables.
Environment is :9i Release 2
Requirement : Generate XML document from the data which is vailable in Oracle tables at client location.
Could some body help me on how to get ahead on this.
Thanks in advance,
Kumar.Implimentation in PowerBuilder7(Source is experimental.. need optimization):
kml_store = create datastore
selectblob kml into :kml_result from (select get_kml(:querry_type,:tmp_querry_value,1) as kml from dual) using sqlca;
if sqlca.sqlcode=100 then
MessageBox("INFO","No data found");
return false;
end if
if sqlca.sqlcode = -1 then
MessageBox("INFO","Error in generating KMl file");
return false
end if
li_FileNum = FileOpen("test.kml",StreamMode!, Write!, LockWrite!, Replace!);
b_len=Len(kml_result)
b_len=64244;
/*inserting in file :)*/
DO WHILE b_pos<=b_len
s_pipe=String(BlobMid(kml_result,b_pos,i_str_len))
ret = FileWrite(li_FileNum,s_pipe);
s_pipe="";
b_pos=b_pos+i_str_len;
LOOP
FileClose(li_FileNum);
Message was edited by:
user601564 -
New to XML, need to generate XML document
I have an existing application that uses an Oracle 9.2.0.3 database. An existing PL/SQL procedure generates a flat file interface using UTL_FILE. My task is to upgrade this procedure to generate an XML file and transform this XML file into different outputs (e.g. flat file interface, PDF file which I plan to use XSL Formatting Objects). My question is how should I generate the XML document from the PL/SQL procedure? Should I use the Oracle 9i SQL/XML capabilities? specifically xmlelement, etc? An if so should I also use UTL_FILE to generate the XML file? Your help will be appreciated.
Williams,
Do you want to generate an XML file from the data present in relational tables using PL/SQL ?
In that case you can use XML SQL Utility(XSU).
For more information on XSU click [url http://otn.oracle.com/docs/products/oracle9i/doc_library/release2/appdev.920/a96621/adx23xsp.htm#1008317]here.
Regards,
Anupama
[url http://otn.oracle.com/sample_code/]OTN Sample Code -
Can not generate XML Document Template
I have the below class
public class MyHome implements Serializable {
ArrayList rooms;
//getter/setter methods here
When I right click mouse and select "Generate XML Template Document", I got the error
Some fields could not be generated to the XML template
c:\e200\dv900\java\classes\java\util\ArrayList.class (The system cannot find the path specified)
Do you have any idea?Not with the info given...
Which jdev version?
Where do I find this menu, as I don't see it?
Timo -
Inserting PI into generated XML document
Can anyone tell me how to insert processing instructions into an XML document generated using the xmlcg generated classes? I understand that I can create a PI using the Document::createProcessingInstruction() method but how do I add it as a sibling to the root element? Any insight in this regard will be really appreciated.
Your question is not very clear.
Do you want to know How to insert an element into an XML document?
Answer: I can see you already know how to do it. You have added the element using addContent()
or do you want to know How to display the XML in a tidy format?
Answer: to view the XML in a properly formatted style you can you the Format class. A very basic way of viewing the XML would be:
* Prints the Document to the specified file.
* @param doc
* @param filename
* @param formatting
public static void printDocToFile(Document doc, String strFileName,
boolean formatting)
XMLOutputter xmlOut = null;
if (!formatting)
xmlOut = new XMLOutputter();
} else
Format prettyFormat = Format.getPrettyFormat();
prettyFormat.setOmitEncoding(false);
prettyFormat.setOmitDeclaration(false);
xmlOut = new XMLOutputter(prettyFormat);
try
if (doc != null)
FileWriter writer = new java.io.FileWriter(strFileName, true);
xmlOut.output(doc, writer);
writer.flush();
writer.close();
} else
System.out.println("Document is null.");
catch (Exception ex)
System.out.println(ex);
} -
Hello, All!
I have some questions about XML in Oracle 9.2
For examle, I have a query such as:
select to_clob(
((XMLElement("MSG" , XMLAttributes('EXPOPR' as "FORMAT",
'1' as "SENDER",
'2' as "RECIPIENT",
to_char(SYSDATE, 'YYYY.MM.DD HH24:MI:SS') as "TIME"
))) msg
from dual
MSG
<MSG FORMAT="EXPOPR" SENDER="1" RECIPIENT="2" TIME="2004.10.04 10:23:16"></MSG>
1) How I can get a full XML document from this result (add <?xml version ...> tag)? I know about SYS_XMLGen, but this function will add a <ROW> tag into XML, but I don't need this...
Also, I can use concatenation of strings, but it is not interestring for me...
2) How I can get the string without enclose tag </MSG>:
<MSG FORMAT="EXPOPR" SENDER="1" RECIPIENT="2"
TIME="2004.10.04 10:23:16" />
Thank for help.There is a new function XMLRoot that will be released as part of 10gR2 for this. In the mean time string concatenation is the only solution..
The following works in 10gR1
create or replace function XMLROOT (XML XMLType,
target varchar2 default NULL,
data varchar2 default NULL,
CHARSET varchar2 default 'UTF-8')
return XMLType deterministic
is
tempCLOB clob;
tempXML XMLtype;
PI VARCHAR2(256);
begin
PI := '<?' || target || ' ' || data || '?>';
select xmlparse(DOCUMENT '<?xml version="1.0" encoding="UTF-8"?>' || PI || XML.getClobVal() WELLFORMED)
into tempXML
from dual;
return tempXML;
end;
In 9.2 it would need to be something like this
create or replace function XMLROOT (XML XMLType,
target varchar2 default NULL,
data varchar2 default NULL,
CHARSET varchar2 default 'UTF-8')
return XMLType deterministic
is
tempCLOB clob;
tempXML XMLtype;
PI VARCHAR2(256);
begin
PI := '<?' || target || ' ' || data || '?>';
select xmltype('<?xml version="1.0" encoding="UTF-8"?>' || PI || XML.getClobVal(),0,1,1)
into tempXML
from dual;
return tempXML;
end;
/ -
Difficulty parsing XML document into query object
Background: Using CFMX 6.1 to take an XML file exported from
MS-Access and parse it into a query object.
Problem: Of the 6 columns defined in the target query, one of
the columns is only populated in the XML file a very low percentage
of the time. When trying to populate the column for a record that
has no volume I was getting the following error:
Element KEY6.XMLTEXT is undefined in a Java object of type
class coldfusion.xml.XmlNodeMap referenced as...
To get around this I made this code change:
Before
<cfset temp = QuerySetCell(mcquery, "CuKey6",
#mydoc.root.dataroot.qTop1000
.Key6.XmlText#, #i#)>
After
<cfif
StructKeyExists(mydoc.root.dataroot.qTop1000.XMLAttributes,"Key6")>
<cfset temp = QuerySetCell(mcquery, "CuKey6",
#mydoc.root.dataroot.qTop1000
.Key6.XmlText#, #i#)>
</cfif>
The new code gets around the error, but when the template is
executed, columns that DO have values
show up as "[empty string]".
I am trying to figure out why when the record has a actual
value it is now overwritten instead of populated
normally?Use XmlChildren[1], XmlChildren[2],... etc., in place of
Key1, Key2, etc. -
Generating an XML Document from an internal table in ABAP
Good day to all of you;
With ABAP, in the R/3 system, I'm trying to figure out a way to accomplish the following:
1) SELECT a set of Purchase Order data into an internal table.
2) Generate an XML document, containing the above data, using a specific schema.
I've been playing around with function module SAP_CONVERT_TO_XML_FORMAT which has the following interface:
CALL FUNCTION 'SAP_CONVERT_TO_XML_FORMAT'
EXPORTING
I_FIELD_SEPERATOR = ''
I_LINE_HEADER = ''
I_FILENAME = v_fname
I_APPL_KEEP = ''
I_XML_DOC_NAME = v_docname
IMPORTING
PE_BIN_FILESIZE = v_byte
TABLES
I_TAB_SAP_DATA = i_SapData
CHANGING
I_TAB_CONVERTED_DATA = i_XMLData
EXCEPTIONS
CONVERSION_FAILED = 1
OTHERS = 2.
I'm uncertain as to whether or not the Export parameter, I_XML_DOC_NAME refers to some schema or definition and therefore have been excluding it. In doing so, the generated XML document seems to use the field name/type information from my itab for the tags.
If this function module requires an XML Document Name, how do I create one and where do I store it in R/3? If this is not the recommended solution, is anyone familiar with a way to load an XML schema, retrieve some data then have SAP generate an XML document using the schema?
Many thanks for any help available.
THai Phillips
Try with the following Code
This program exports an internal table to an XML file.
Report ZPRUEBA_MML_13 *
Export an internal table to XML document *
NO BORRAR ESTE CODIGO *
REPORT ZPRUEBA_MML_13.
PANTALLA SELECCION *
PARAMETERS: GK_RUTA TYPE RLGRAP-FILENAME.
PANTALLA SELECCION *
TYPE TURNOS *
TYPES: BEGIN OF TURNOS,
LU LIKE T552A-TPR01,
MA LIKE T552A-TPR01,
MI LIKE T552A-TPR01,
JU LIKE T552A-TPR01,
VI LIKE T552A-TPR01,
SA LIKE T552A-TPR01,
DO LIKE T552A-TPR01,
END OF TURNOS.
TYPE TURNOS *
TYPE SOCIO *
TYPES: BEGIN OF SOCIO,
NUMERO LIKE PERNR-PERNR,
REPOSICION LIKE PA0050-ZAUVE,
NOMBRE LIKE PA0002-VORNA,
TURNOS TYPE TURNOS,
END OF SOCIO.
TYPE SOCIO *
ESTRUCTURA ACCESOS *
DATA: BEGIN OF ACCESOS OCCURS 0,
SOCIO TYPE SOCIO,
END OF ACCESOS.
ESTRUCTURA ACCESOS *
START OF SELECTION *
START-OF-SELECTION.
PERFORM LLENA_ACCESOS.
PERFORM DESCARGA_XML.
END-OF-SELECTION.
END OF SELECTION *
FORM LLENA_ACCESOS *
FORM LLENA_ACCESOS.
REFRESH ACCESOS.
CLEAR ACCESOS.
MOVE: '45050' TO ACCESOS-SOCIO-NUMERO,
'MOISES MORENO' TO ACCESOS-SOCIO-NOMBRE,
'0' TO ACCESOS-SOCIO-REPOSICION,
'T1' TO ACCESOS-SOCIO-TURNOS-LU,
'T2' TO ACCESOS-SOCIO-TURNOS-MA,
'T3' TO ACCESOS-SOCIO-TURNOS-MI,
'T4' TO ACCESOS-SOCIO-TURNOS-JU,
'T5' TO ACCESOS-SOCIO-TURNOS-VI,
'T6' TO ACCESOS-SOCIO-TURNOS-SA,
'T7' TO ACCESOS-SOCIO-TURNOS-DO.
APPEND ACCESOS.
CLEAR ACCESOS.
MOVE: '45051' TO ACCESOS-SOCIO-NUMERO,
'RUTH PEÑA' TO ACCESOS-SOCIO-NOMBRE,
'0' TO ACCESOS-SOCIO-REPOSICION,
'T1' TO ACCESOS-SOCIO-TURNOS-LU,
'T2' TO ACCESOS-SOCIO-TURNOS-MA,
'T3' TO ACCESOS-SOCIO-TURNOS-MI,
'T4' TO ACCESOS-SOCIO-TURNOS-JU,
'T5' TO ACCESOS-SOCIO-TURNOS-VI,
'T6' TO ACCESOS-SOCIO-TURNOS-SA,
'T7' TO ACCESOS-SOCIO-TURNOS-DO.
APPEND ACCESOS.
ENDFORM.
FORM LLENA_ACCESOS *
FORM DESCARGA_XML *
FORM DESCARGA_XML.
DATA: L_DOM TYPE REF TO IF_IXML_ELEMENT,
M_DOCUMENT TYPE REF TO IF_IXML_DOCUMENT,
G_IXML TYPE REF TO IF_IXML,
W_STRING TYPE XSTRING,
W_SIZE TYPE I,
W_RESULT TYPE I,
W_LINE TYPE STRING,
IT_XML TYPE DCXMLLINES,
S_XML LIKE LINE OF IT_XML,
W_RC LIKE SY-SUBRC.
DATA: XML TYPE DCXMLLINES.
DATA: RC TYPE SY-SUBRC,
BEGIN OF XML_TAB OCCURS 0,
D LIKE LINE OF XML,
END OF XML_TAB.
CLASS CL_IXML DEFINITION LOAD.
G_IXML = CL_IXML=>CREATE( ).
CHECK NOT G_IXML IS INITIAL.
M_DOCUMENT = G_IXML->CREATE_DOCUMENT( ).
CHECK NOT M_DOCUMENT IS INITIAL.
WRITE: / 'Converting DATA TO DOM 1:'.
CALL FUNCTION 'SDIXML_DATA_TO_DOM'
EXPORTING
NAME = 'ACCESOS'
DATAOBJECT = ACCESOS[]
IMPORTING
DATA_AS_DOM = L_DOM
CHANGING
DOCUMENT = M_DOCUMENT
EXCEPTIONS
ILLEGAL_NAME = 1
OTHERS = 2.
IF SY-SUBRC = 0.
WRITE 'Ok'.
ELSE.
WRITE: 'Err =',
SY-SUBRC.
ENDIF.
CHECK NOT L_DOM IS INITIAL.
W_RC = M_DOCUMENT->APPEND_CHILD( NEW_CHILD = L_DOM ).
IF W_RC IS INITIAL.
WRITE 'Ok'.
ELSE.
WRITE: 'Err =',
W_RC.
ENDIF.
CALL FUNCTION 'SDIXML_DOM_TO_XML'
EXPORTING
DOCUMENT = M_DOCUMENT
IMPORTING
XML_AS_STRING = W_STRING
SIZE = W_SIZE
TABLES
XML_AS_TABLE = IT_XML
EXCEPTIONS
NO_DOCUMENT = 1
OTHERS = 2.
IF SY-SUBRC = 0.
WRITE 'Ok'.
ELSE.
WRITE: 'Err =',
SY-SUBRC.
ENDIF.
LOOP AT IT_XML INTO XML_TAB-D.
APPEND XML_TAB.
ENDLOOP.
CALL FUNCTION 'WS_DOWNLOAD'
EXPORTING
BIN_FILESIZE = W_SIZE
FILENAME = GK_RUTA
FILETYPE = 'BIN'
TABLES
DATA_TAB = XML_TAB
EXCEPTIONS
OTHERS = 10.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM.
FORM DESCARGA_XML *
Thanks & regards
Sreenivasulu P -
Convert Objects into an XML Document? Possible?
Hello,
Is there a way to convert different objects into an XML File/Document
If I create 10 objects and then I want to create an XML Document
of these objects,is it possible to do this?
AjayHello,
Is there a way to convert different objects into an
XML File/Document
If I create 10 objects and then I want to create an
XML Document
of these objects,is it possible to do this?
Ajayjust override the .toString() method... -
How to generate XML from relational data : PL/SQL or Java
I'm new to Oracle XML and would appreciate some advice. I've been asked to generate XML documents from data stored in relational tables. The XML documents must be validated against a DTD. We will probably want to store the XML in the database.
I've seen a PL/SQL based approach as follows :
1.Mimic the structure of the DTD using SQL object types 2.Assign the relational data to the object type using PL/SQL as required
3.Use the SYS_XMLGEN package to render the required XML documents from the SQL objects
However, creating the object types seems to be quite time consuming (step 1 above) for anything other than the simplest of XML documents.
I've also seen that there is the Java based approach, namely :
1. Use the XML generator to build Java classes based on a DTD.
2. Use these classes to build the required XML
On the face of it, the Java based approach seems simpler. However, I'm not that familiar with Java.
Which is the best way to proceed ? Is the PL/SQL based approach worth pursuing or should I bite the bullet and brush up my Java ?
Is it possible to use a combination of PL/SQL and Java to populate the dtd generated java classes (step 2 of the Java approach) to reduce my learning curve ?
Thanks in advanceTo help answer your questions:
1) Now, in 9iR2, you can use SQL/XML as another choice.
2) You can also use XSU to generate the XML and use XSLT to transform it to a desired format instead of using object views if possible.
3) XDK provide Class generator support to populate XML data to Java classes. -
Generated XML doc file contains comments from MFC source code
Hello, in my project I use the option /doc to generate XML doc file from my source codes but unfortunately in the output XML file there are mixed also comments from original MFC source codes, see the part of generated xml file:
Is there a solution to ignore these MFC cpp files?
Many thanks
Regards
Petr Stejskal
<?xml version="1.0"?>
<style xmlns="http://www.w3.org/1999/xhtml">@namespace html url(http://www.w3.org/1999/xhtml); :root { font:small Verdana; font-weight: bold; padding: 2em; padding- } * { display: block; padding- } html|style { display: none; } html|span, html|a
{ display: inline; padding: 0; font-weight: normal; text-decoration: none; } html|span.block { display: block; } *[html|hidden], span.block[html|hidden] { display: none; } .expand { display: block; } .expand:before { content: '+'; color: red; } .collapse
{ display: block; } .collapse:before { content: '-'; color: red; } </style><doc><assembly><assembly>
"Console" </assembly></assembly><members><members><member name="T:_RS"><member
name="T:_RS">Reed-Solomon codec control block</member></member><member name="M:MMask_makeMask(System.Int32,System.Byte*,System.Int32,QRecLevel)"><member
name="M:MMask_makeMask(System.Int32,System.Byte*,System.Int32,QRecLevel)">Mode indicator. See Table 2 in Appendix 1 of JIS X0510:2004, pp.107.</member></member><member
name="M:CMFCControlRenderer.IsScaled"><member
name="M:CMFCControlRenderer.IsScaled"><summary><summary>Tells whether this control
renderer works with scaled (resized) images.</summary></summary><returns><returns>Returns TRUE if this control
renderer works with resized (scaled) images.</returns></returns></member></member><member name="M:CMFCControlRenderer.SmoothResize(System.Double)"><member
name="M:CMFCControlRenderer.SmoothResize(System.Double)"><summary><summary>
Smoothly resizes images.</summary></summary><param name="dblScale" /><param
name="dblScale"> Scale ratio.</param><returns><returns>
TRUE if resize succeeds; otherwise FALSE.</returns></returns></member></member><member name="M:CDrawingManager.CreateBitmap_32(HBITMAP__*,System.UInt32!System.Runtime.CompilerServices.IsLong)"><member
name="M:CDrawingManager.CreateBitmap_32(HBITMAP__*,System.UInt32!System.Runtime.CompilerServices.IsLong)"><summary><summary>
Creates a 32 bit bitmap from the specified bitmap.</summary></summary><returns><returns> A handle to created
bitmap, or NULL, if creation fails.</returns></returns><param name="bitmap" /><param
name="bitmap"> A handle to the original bitmap.</param><param name="clrTransparent"
/><param
name="clrTransparent"> An RGB value specifying transparent color of the original bitmap.</param></member></member><member
name="M:CDrawingManager.CreateBitmap_32(CSize!System.Runtime.CompilerServices.IsConst*!System.Runtime.CompilerServices.IsImplicitlyDereferenced,System.Void**)"><member
name="M:CDrawingManager.CreateBitmap_32(CSize!System.Runtime.CompilerServices.IsConst*!System.Runtime.CompilerServices.IsImplicitlyDereferenced,System.Void**)"><summary><summary>
Creates an empty 32 bit bitmap.</summary></summary><returns><returns> A handle to created bitmap, or NULL,
if creation fails.</returns></returns><param name="size" /><param
name="size">Specifies bitmap size.</param><param name="pBits" /><param
name="pBits">When the function returns contains a pointer to bitmap bits.</param></member></member><member
name="M:CDrawingManager.DrawRotated(CRect,CDC*!System.Runtime.CompilerServices.IsImplicitlyDereferenced,System.Int32)"><member
name="M:CDrawingManager.DrawRotated(CRect,CDC*!System.Runtime.CompilerServices.IsImplicitlyDereferenced,System.Int32)"><summary><summary>Rotates
a source DC content inside the given rectangle by +/- 90 degrees</summary></summary><param name="rectDest" /><param
name="rectDest">Destination rectangle</param><param name="dcSrc" /><param
name="dcSrc">The source device content.</param><param name="bClockWise"
/><param
name="bClockWise">TRUE - rotate +90 degrees, FALSE - 90.</param></member></member><member
name="M:AfxRegDeleteKey(HKEY__*,System.Char!System.Runtime.CompilerServices.IsConst*,ATL.CAtlTransactionManager*)"><member
name="M:AfxRegDeleteKey(HKEY__*,System.Char!System.Runtime.CompilerServices.IsConst*,ATL.CAtlTransactionManager*)"><summary><summary>Deletes
the specified registry key.</summary></summary><returns><returns> If the function succeeds, the return
value is ERROR_SUCCESS. If the function fails, the return value is a nonzero error code defined in Winerror.h</returns></returns><param name="hKey" /><param
name="hKey">A handle to an open registry key.</param><param name="lpSubKey"
/><param
name="lpSubKey">The name of the key to be deleted.</param><param name="pTM" /><param
name="pTM">Pointer to CAtlTransactionManager object</param></member></member><member
name="M:AfxRegOpenKeyEx(HKEY__*,System.Char!System.Runtime.CompilerServices.IsConst*,System.UInt32!System.Runtime.CompilerServices.IsLong,System.UInt32!System.Runtime.CompilerServices.IsLong,HKEY__**,ATL.CAtlTransactionManager*)"><member
name="M:AfxRegOpenKeyEx(HKEY__*,System.Char!System.Runtime.CompilerServices.IsConst*,System.UInt32!System.Runtime.CompilerServices.IsLong,System.UInt32!System.Runtime.CompilerServices.IsLong,HKEY__**,ATL.CAtlTransactionManager*)"><summary><summary>Opens
the specified registry key.</summary></summary><returns><returns> If the function succeeds, the return
value is ERROR_SUCCESS. If the function fails, the return value is a nonzero error code defined in Winerror.h</returns></returns><param name="hKey" /><param
name="hKey">A handle to an open registry key.</param><param name="lpSubKey"
/><param
name="lpSubKey">The name of a key that this function opens or creates.</param><param name="ulOptions"
/><param
name="ulOptions">This parameter is reserved and must be zero.</param><param name="samDesired" /><param
name="samDesired">A mask that specifies the desired access rights to the key.</param><param
name="phkResult" /><param
name="phkResult">A pointer to a variable that receives a handle to the openedkey.</param><param
name="pTM" /><param
name="pTM">Pointer to CAtlTransactionManager object</param></member></member></members>Hi stejsky,
Thank you for posting in MSDN forum.
>>In my project I use the option /doc to generate XML doc file from my source codes but unfortunately in the output XML file there are mixed also comments from original MFC source codes.
Based on your issue, could you please tell me how you use the option /doc to generate XML doc file from your source codes?
If you use the option /doc to generate the XML doc file by right-click the your MFC project->Properties->Configuration Properties->C/C++->Output file->set the Generate XML document files as Yes(/doc) like the following screen shot.
(1)If yes, since we could not reproduce your issue in mu side, so if possible, I suggest you could share me your MFC project so that we will further help you support this issue.
You could upload your MFC project to the OneDrive and then copy link here.
(2)If no, please try the above way to generate XML doc file and then check if you still get same issue.
Best Regards,
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey.
Maybe you are looking for
-
I have the most recent version of itunes and am now unable to use Home sharing or Itunes Match. I have checked all connections, software updates, restarted, re-booted to no avail. Any tips on a fix by the community would be appreciated.
-
i hi guys crested po with unit of measure kg and also made migo,miro and RFQ but now when i change unit of measurement from kg to pc in material master there is error the base unit of measure cannot be changed choose display errors 1 if there are no
-
How to generate a local file pdf with reports 11g
I want to generate a local pdf file to print it with client_host
-
Query link Freight Charges RDR2
Hi Experts, I have did the queries as below but i have a problem to link to RIR2 which is Freight charges. I have tried after i linked the result is no correct. Please Kindy advise. SELECT T0.LineStatus AS 'Row Status', T1.DocDate AS 'Posting Date',
-
BAPI_POSRVAPS_GETLIST3 not returing purchase requistion
HI , I am using this BAPI : BAPI_POSRVAPS_GETLIST3 to extract Purchase requistion creared by SNP forecast. On the basis of product and location. but it is not returning any thing , i have tried every thing. please help me out. parameters passed : CAL