Newbie Question: Gererating a mapping xml file

How is castor used, if even, to generate the mapping xml files from the classes generated by castor from an xsd? I have a(n) xsd that has many complex types and this called for the generation of many castor classes from that xsd...so, using these class files...how do I generate a single mapping xml file?
Here is the means by wich we use these two (the xsd and mapping file) in one of our methods?
xmlWriter.write(req, res, someDetail, "someDetail.castor.xml",
"someDetail.xsd");
Prior to this, the xsd files were simple and I created the mapping file by hand. I don't know how this translates when there are so many classes that were generated by caster.
Can someone point me in the direction of more information on how to create this mapping file from all of these classes?
Any advice would be appreciated.
-abe

Can do... I have been working on a readme.install to this end.  One question about the pre_upgrade script.  /usr/share/pacman/proto.install states:
## arg 1:  the new package version
## arg 2:  the old package version
#post_upgrade() {
  # do something here
I'm confused by the arg 1 and arg 2.  Is it simply the version number with nothing else.
EDIT: ok.. I get it,  Assign a variable to them to capture and check.
# $1: The new package version
# $2: The old package version
post_upgrade() {
NEW=`echo $1`
OLD=`echo $2`
if [ "$OLD" = "1.0.1" ]; then
do something
fi
Last edited by graysky (2010-02-11 22:01:03)

Similar Messages

  • Hibernate mapping XML files for the two SQL Server tables below.

    Hello all..,
    Question 1:
    I am working on a project that needs to support a database with an inherited legacy schema that you cannot change. The schema is provided below.Hibernate mapping XML files for the two SQL Server tables below. Please provide those two XML files. Assume some hypothetical package and class names. Assume that no "fancy" stuff such as lazy initialization, optimistic locking etc is needed at this time.
    CREATE TABLE [SURVEY_ANSWERS] (
    [ANSWER_ID] [int] IDENTITY (1,1) NOT NULL,
    [QUESTION_ID] [int] NOT NULL,
    [POSITION] [int] NULL,
    [TEXT] [varchar](350) NULL
    CREATE TABLE [dbo].[SURVEY_QUESTIONS] (
          [QUESTION_ID] [int] IDENTITY (1, 1) NOT NULL ,
          [TEXT] [varchar] (350) NULL
    GO
    ALTER TABLE SURVEY_ANSWERS
    ADD CONSTRAINT pk_SURVEY_ANSWERS PRIMARY KEY(ANSWER_ID,QUESTION_ID);
    ALTER TABLE [dbo].[SURVEY_QUESTIONS] ADD
           PRIMARY KEY  CLUSTERED
                [QUESTION_ID]
    GO
    ALTER TABLE [dbo].[SURVEY_ANSWERS] ADD
           FOREIGN KEY
                [QUESTION_ID]
          ) REFERENCES [dbo].[SURVEY_QUESTIONS] (
                [QUESTION_ID]
          )Question 2:
    Assume that you are working on a project developing, say, a banking application. You are the Architect and thinking that Hibernate ORM should be used for the entire access to the relational database. As usual, you have created (or auto-generated) a set of HBM XML files as well as POJOs for which you define the mappings. Assume now that a new requirement has just popped up. The system needs to be able to import new bank accounts and user information in bulk from a very large XML file at once and store it in the database. Assume the XML file contains all necessary information to populate fields in database tables. As performance is very important for this operation. Given this description, how would you approach the problem?
    Please describe briefly.
    -Thanks and regards
    Praveen Soni

    You're not fooling anyone Dennis_Mox. But nice try.Jeez, man. Mail me at denismox[at]yandex.ru, I will show you that exact test, dammit.

  • How to map XML File input to VO (eventually to update table) upon fileupld

    Reqirement: I am downloading an XML File (basically name-value pair) from user using OAMessageFileUploadBean. I need to take this file and update to an existing record in the table (cs_incidents_all). XML File schema is well-known in advance.
    Approach: Don't know what is the best, but I'm thinking if there is an OAF way to map the XML File (Blobdomain) to VO and get the rowIMPL.getColumn1Value to fetch all the datavalues then loop thru all the columns (xml-tags) and finally call plsql APIs which will update/insert into table (cs_incidents_all)
    Is this possible in OAF? If so please shed some light as to how to map XML File to VO.
    If this is not possible then please let me know the other way. I have to do this inside the oaf.
    Thank you,

    Can someone please let me know if this is possible in OAF?

  • All I want for my birthday is my jaxrpc-mapping.xml file.........;-)

    I am using JWSDP 2.0 with JDK 1.5. I have developed an ant script for building my web service files. When the script runs, the command line arguments are passed to the wscompile:
    wscompile -d C:\WorkSpaceForMyEclipse\WebService\WebContent\WEB-INF\classes "-features:rpcliteral, wsi" -g -import -keep -nd C:\WorkSpaceForMyEclipse\WebService\descriptors -s C:\WorkSpaceForMyEclipse\WebService\JavaSource -verbose -Xprintstacktrace -Xserializable C:\WorkSpaceForMyEclipse\WebService\WebContent\WEB-INF\wsdl\webservice-config.xml -classpath  <all the jar files from jwsdp project> <project jars>This all works well and good.
    My problem is I am not seeing a jaxrpc-mapping.xml file being created.
    When I add the mapping=${path}/jaxrpc-mapping.xml to the ant task, the builds break saying -mapping is not an option for wscompile....
    Am I doing something wrong? Can some guide me in the right direction for creating the mapping file? When I try axis, the mapping file is created, but it is not populated with any mappings. All I want for Christ is my jaxrpc-mapping.xml file. :-)
    Thanks in advance for reading my post. Any suggestions would be greatly appreciated.
    Russ

    If you are using rpc/literal and jdk 1.5, you would be better off using JAX-WS which does not require a mapping file. JAX-WS is the next generation Web services API that replaces JAX-RPC. Check out http://jax-ws.dev.java.net.

  • Castor XSD Code Generation ANT task: mapping  XML file?

    Hello,
    I am new to Castor and am using the Castor Code Generator ANT task to generate code from a XSD schema file.
    I am using a binding XML file as well. One thing that I have a question about is the needed XML mapping file. I set the ‘*generateMapping*’ attribute to ‘true’ but have not found a mapping XML document.
    Is there something I am doing wrong?
    I would have attached the XSD files(some are imported), binding XML file and the ANT build.xml file in a .zip file to this post, but this forum does not have a facility for file attachments, but I can email them upon request.
    Thanks in advance,
    Andrew

    Hi Andrew,
    JAXB is the Java standard (JSR-222) for generating Java classes from an XML schema. Several implementations of this standard are available:
    - Metro JAXB: The JAXB reference implementation, available in Java SE 6 and as part of GlassFish
    - EclipseLink JAXB (MOXy): Part of EclipseLink, also available in Oracle TopLink
    - JaxMe: Available from Apache
    - Etc...
    Castor is a proprietary XML binding tool. For Castor related questions you should visit the Castor website.
    -Blaise

  • Mutiple mapping XML files for one datasource

    One of our projects raised the following question. Any help would be greatly appreciated.
    "Can we have mutiple ToplinkMappings.xml files for one database? The reason we are looking at it is, our toplinkMappings.xml file size is keep growing in size(right now 2.2MB), we are getting into issues while comparing with the previous versions. The PVCS diff tool and beyond compare tools are not able to interpret the corresponding blocks of code on both the versions properly."
    Haiwei

    Hi Haiwei,
    Yes, you can have multiple deployment.xml files in a session. Take a look at Configuring Multiple Mapping Projects.
    --Shaun                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Newbie help please:  "Validation of XML file failed."

    Hopefully my question is short and easy.
    I'm a developer and haven't used FrameMaker before. However for unforeseen reasons, I've inherited our technical help documentation constructed in FrameMaker which I've never used. Unfortunately I'm under a very tight deadline and I'm attempting to update our already existing and fairly extensive application help files.
    However, I'm getting a "Validation of XML file failed" error for 90% of our .xml help docs. I opened our .book file in FrameMaker fairly easily, and can see all of our .xml files. However the variables already embedded in the documents aren't being recognized and seem to be causing the above error. I've located our variable definition files (xml) in the concepts folder, but FrameMaker doesn't seem to recognize them. Any suggestions on what I can check or how I can get FM to refer to the variable definitions? I'm working with a new installation of FM, is there some setup I overlooked?
    Many thanks,
    dana.

    Sheila and Rick,
    Thank you both so much for your offer of help. My apologies for not replying earlier. Other 'emergencies' and priorities at work took me in other directions. It turns out another solution has been found for the time being. But thank you again for your replies. They say a lot about this community and its support. :)
    Thanks again,
    dana.

  • How to map XML file to various of object in the RFC

    hello
    I recieve XML file (not devided to elements, but XML file)'
    and I would like to map it to a RFC that has various object.
    I there a way to do it?
    if it involve a java code, does any one has a written code example?
    THX
    Kfir

    thanks for the reply
    my source XML response will be looking something like this (it will be reponsed in a long string):
    <?xml version='1.0' encoding='UTF-8'?>
    <SOAP-ENV:Envelope xmlns:SOAP-ENV='http://schemas.xmlsoap.org/soap/envelope/' xmlns:xsd='http://www.w3.org/2001/XMLSchema' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>
    <SOAP-ENV:Header>
    </SOAP-ENV:Header>
    <SOAP-ENV:Body>
    <status>
    <retCode>00</retCode>
    <retCodeDesc>OK</retCodeDesc>
    <rRobjectId>09002347802d2981</rRobjectId>
    <rFileSize>7</rFileSize>
    <rTotalPages>1</rTotalPages>
    </status>
    </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>
    my RFC is:
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:sap-com:document:sap:rfc:functions" targetNamespace="urn:sap-com:document:sap:rfc:functions">
    <xsd:element name="ZRFC_SET_DOCUMENT.Response">
    <xsd:complexType>
    <xsd:all>
    <xsd:element name="RETCODE" type="xsd:string" minOccurs="0" />
    <xsd:element name="RETCODEDESC" type="xsd:string" minOccurs="0" />
    <xsd:element name="RFILESIZE" type="xsd:string" minOccurs="0" />
    <xsd:element name="RROJECTID" type="xsd:string" minOccurs="0" />
    <xsd:element name="RTOTALPAGES" type="xsd:string" minOccurs="0" />
    </xsd:all>
    </xsd:complexType>
    </xsd:element>
    </xsd:schema>

  • Inheritance of mapping xml files?

    How can one use inheritance (or other technique) to generate mapping files to be bundled with common components that are shared among several departments/projects. The original map (XML) would be distributed in a jar file with the classes. The idea is that the other people might want to extend components but don't want to have to map all of the objects again. Just want to add some new methods.

    Currently for coherent use of the MW, objects that inherit mappings must be in the same project (mapping file). This means that the common mapping file would need to be used as a starting point for the different components, and amendment methods/code APIs would have to be used at deployment by each of the components to modify the project according to their needs.
    HTH,
    -Mike

  • A few questions about using an XML file to add text into a TextArea component set as html

    I'm using AS2 in Flash CS3.
    I have a TextArea component in the stage that's loading its text from an XML and I've been able to use the ul and li tags to create lists. However, when I try to include a nested list it just inserts a line break between the nested list and the main list rather than indent it further. Is there a solution for this issue?
    Failing that, how would I be able to add non-breaking spaces into the XML so they will render inside the TextArea component? I've tried   and &#160; without success. I scoured the net for some help with this and found some information about modifying the font embedding xml file with a new entry for the non-breaking space and that didn't work either, so that leaves me somewhat stumped.

    flash doesn't handle nested lists (as you now know).  you can work-around that limitation using css and creating your own indent styles.  css have a marginLeft property you can use.

  • Question about backendobject-config.xml file

    Hello,
    I am trying to register a backend object in xcm/customer/backendobject-config.xml
    file,
    my entry looks like:
    <backendobject xmlns:isa="com.sapmarkets.isa.core.config" xmlns:xi="http://www.w3.org/2001/XInclude" xmlns:xml="http://www.w3.org/XML/1998/namespace">
         <configs>
         <!-- customer changes in backendobject-config should be done here by extending/overwriting the base configuration-->
         <xi:include href="$/modification/backendobject-config.xml#xpointer(backendobject/configs/*)"/>
              <config isa:extends="../config[@id='crmdefault']">
              <businessObject
              type="PricingBEO"
              name="PricingBEO" className="com.isa.pricing.beo.PricingBEO" connectionFactoryName="JCO" defaultConnectionName="ISAStateless"/>
              </config>
         </configs>
    </backendobject>
    but when I am debugging, the backend objet is null. Can somebody please tell me
    what is wrong with my entry?
    Thanks,
    Harsha

    Are you using crm as a backend? One option is that you are extending wrong config...

  • Newbie Question On Library Creation and File Duplication

    I'm new to iTune's hard drive file organizing structure, so bare with me.
    I have a single directory on Hard Drive 2 (HD2) called "Music". When I create a music library in iTunes from that music directory source, iTunes appears to create its own new directory in "Macintosh HD/Users/iTunes/Music" (HD1) and thus I now have duplicate directories of music on two different hard drives, HD1 and HD2. Add Time Machine to this mix (which backs up both drives) and I now have four directories with duplicate music. Nice.
    Okay. So, assuming this is the case (and please correct me if I am wrong), then my question is, once I create a Library via iTunes program, can I now delete my original HD2/Music directory of files since iTunes is referencing its newly created directory in HD1? Or, is there some sort of association still going on and I must live with the duplicate directories and subsequent quadrupled directories? (Which I know I can selectively exclude some stuff from Time Machine, but it is easier to back up everything.)
    Thank you in advance for your input and advise.

    Yes once music has been added to iTunes you can remove it from its original location with way you have iTunes set up at the moment.
    On the other hand you could change the iTunes preferences so that it does not copy files into the iTunes library, instead it leaves the files were there where and points to them.

  • Question about creating multiple XML files from same query

    I have a query like this:
    select * from emp;
    ename empno deptno
    Scott 10001 10
    Tiger 10002 10
    Hanson 10003 20
    Jason 10004 30
    I need to create multiple output files in xml format for each dept
    example:
    emp_dept_10.xml
    emp_dept_20.xml
    emp_dept_30.xml
    each file will have the information for employees in different departmemts.
    We are using DBMS_XMLGEN package to generate XML.
    The reason I need to do this is to avoid executing the same query 200 times for generating the same output for different departments. Please let me know if it is practically possible to do this.
    Any input is greatly appreciated.
    Thanks a lot!!

    one solution i can think of is to use SQLX operator instead of dbms_xmlgen.
    here is a sample example.
    declare
      l_xmltype xmltype;
      l_deptno  emp.deptno%type;
    begin
      for i in (select * from emp order by deptno)
      loop
        select xmlconcat(
                    xmlelement("ename", i.ename)
                   ,xmlelement("sal", i.sal)
                   ,xmlelement("detpno", i.deptno))
          into l_xmltype from dual;
        dbms_output.put_line(l_xmltype.GetClobVal());
      end loop;
    end;
    /Now here you can open the query once, keep writing to the file till the deptno
    is same, when the deptno changes, close the file and open a new file with new
    deptno and start writing.
    Note : in this way you will have to add the xmlprolog manually to each of the file which should not be an issue. after opening the file add the prolog string manually.
    Hope this helps.

  • Newb Question regarding Same InDesign CS4 file used on two different computers.

    Probably been answered 1,000 times or is common knowledge, but I could not get it narrowed down using the search feature.
    I would like to take an InDesign CS4 file ( a book) created on my imac, and work on it while away on a macbook pro with identical InDesign CS4 software. I will only be changing layout and some text, but will not be modifying anything that is a link other than re-sizing.
    After doing this, will I be able to put the updated file into my imac and be ready to go, or am I playing with fire? If I might do more harm than good, I will not do it. It's just that I have a big project due and I have to be out of town for 3 days and would like to work on it if I can while I'm gone.
    Thanks for any input,
    Sebastian Gaeta

    If you only copy the InDesign file then yes, preflight will alert you to the missing links. Just ignore it, or package the file and transfer the links, too.
    Better yet, get yourself a membership to Dropbox. With Dropbox installed on both computers you can keep the entire job (up to 2 GB) in one folder and the files will sync to Dropbox’s servers, which will then sync to all computers sharing that folder. Open InDesign file on Mac 1, make changes, close file. Open file on Mac 2, make changes, close file. Open file on Mac 1 and the changes will be there. Best of all, you can go to Dropbox’s website and access a file’s history. This means you can go back to previous version of the file if you need to.
    I add a folder to my Dropbox folder for any current job. When I’m done I move the files out and archive them.
    Self serving link: https://www.dropbox.com/referrals/NTUwMDUyOTI5
    If you sign up using the above link I get a tiny increase in my allotted storage.

  • Newbie question -  How to read all files for a backup

    Hello all,
    I have two users on my iMac. I am an administrator and the other user is a Standard user.
    From my account, I wish to run backup software that will backup the entire "User" directory. The problem I am having is that when I run the backup software (fyi: iBackup),
    it complains that it cannot read the files in the other user's account.
    I notice that when I browse to the other user's account, all the directories in their home folder are locked.
    How can I run my backup software so that it can read all files in the User directory?
    Thank you kindly!
    Jeff
    17" iMac Core Duo   Mac OS X (10.4.6)  

    Hi kneecarrot !
    I don't know if this will suit your needs, but one easy way of backing up other user's stuff is via the terminal . If you have an admin accountm just use:
    sudo ditto -rsrcFork /Users /Volumes/"nameof_anotherharddrive"/Users
    This will perform an identical clone of all your users home direcories for backup purposes. To restore the bkd'up files, just reverse the lines:
    sudo ditto -rsrcFork /Volumes/"nameof_anotherharddrive"/Users /Users
    ATTENTION: Be aware that it will restore the files to the exact structure and contents it was when backed up, erasing all new and modified files!! You may however copy just the files/folders you want to recover, e.g.:
    sudo ditto -rsrcFork /Volumes/"nameof_another_harddrive"/Users/"usera"/Documents /Users/"user_a"/Documents
    IMPORTANT: As with all terminal commands... be careful, think twice and double-check the syntax. You may want to test with non-critical stuff or demo user accounts first.
    Good luck,
    Michael
    MacBook Pro   Mac OS X (10.4.6)   2 Gig RAM

Maybe you are looking for

  • To run a program in BACKGROUND using SUBMIT

    I need to run a program in background using the SUBMIT option. Here i have to pass an internal table form one program to another which will be used to update sales orders using BDC. Questions 1} Can we execute a program in background using SUBMIT? 2}

  • Greyed out .MOV HELP!

    This isnt specifically FCPX, but I assume most people here have greater experience with media files. I recently shot a 2 camera Biography interview and my final and most critical clip is greyed out in the "Finder" window. I have tried other macs, dro

  • NTSC DVD Sources Lag with 23.976fps Encode

    I've never had this problem before with other DVD sources but for some reason in this particular project, from the two areas in this compilation that I made with the NTSC DVD-Video content, in the MainConcept h264 23.976fps @ 3000kbps render, the vid

  • Iphoto problem with file transfer

    hello i have a problem, i transfer my iphoto library from my brother account to my account, and when i try to open them i can't because my mac tell me that i don't have license and power to do that. I've tried to change sharing settings from my broth

  • How do I stop jpegs automatically opening Photoshop? And instead open in Preview

    When I installed Photoshop CS6 I must have selected to open all JPEGS via Photoshop. I need to deselect this option and elect to open JPEGS as before, in Preview. How can I accomplish this? Thanks for your help, this is slowing me down.