Matching XML structure to unmarshal classes

Hello
I am wanting to use data binding ( Castor or other ) to parse xml mesages recieved by a server.
Can someone tell me if it possible to achieve the folowing:
I am goig to have several types of message structures coming into the server which will need binding. The following two example are fictitious but demonstrate my question.
MESSAGE 1
<message>
     <type>type1</type>
</message>
Unmarsal class as follows:
public class Message1
    private String type;
    public Message1( String type )
        this.type = type;
    public Message1() { }
    public String getType()
        return type;
    public void setType(String type)
        this.type = type;
}MESSAGE 2
<message>
     <type>type2</type>
     <somevar>xyz</somevar>
     <anothervar>xyz</anothervar>
</message>
Unmarsal class as follows:
public class Message2
    private String type;
     private String somevar;
     private String anothervar;
    public Message2( String type, String somevar, String anothervar)
        this.type = type;
          this.somevar = somevar;
          this.anothervar = anothervar;
    public Message2() { }
    public String getType()
        return type;
    public String getSomeVar()
        return somevar;
    public String getAnotherVar()
        return anothervar;
    public void setType(String type)
        this.type = type;
    public void setSomeVar(String somevar)
        this.somevar = somevar;
    public void setAnotherVar(String anothervar)
        this.anothervar = anothervar;
}The marshalling of these messages is simple when I know what the message structure is however in the server It will not know this.
My question Is how do I match the messages and classes?
Kindest Regards.

Check the solution given by Rajat in the this discussion forum at
XML File Input to Generated Classes
Regards,
Anupama

Similar Messages

  • Xml structure being ignored

    XML structure in "Bus Card Order Form" created in inDesign is being ignored by Acrobat>Tools>Forms>More Form Options>Export Data. 
    inDesign form also has DTD.
    1. inDesign "BC Order Form" is output to interactive pdf fillable form
    2. pdf filled form is then saved.
    3. XML is then exported per above, however XML structure does not match. Rather, root is redefined as "fields' and all fields are listed alphabetically.  
    4. xml data does not flow into fields in BC template.
    Both "Bus Card Order Form' and 'BC Template' have matching xml structure.
    What am I doing wrong?

    Nevermind my previous post; I see the error in our own code. You're
    right; the file isn't being used. This will be fixed in our 2.5 final
    release. Sorry!
    In the meantime, I suggest you continue to use the 2.4
    kodo-reverse-schema.jar

  • How can I get the XML structure from a flat structure?

    Hi all,
    in my XI SP 12 I use a JMS adapter to read information using the WebSphereMQ transport protocol.
    The structure that I receive have this format:
    <Name_A.KeyFieldValue><Name_A.fieldName_A1_Value>...<Name_A.fieldName_AN_Value>
    <NumberRecordType_B><NumberRecordType_c>
    <Name_B.KeyFieldValue><Name_B.fieldName_B1_Value>...<Name_B.fieldName_BN_Value>
    <Name_B.KeyFieldValue><Name_B.fieldName_B1_Value>...<Name_B.fieldName_BN_Value>
    <Name_C.KeyFieldValue><Name_C.fieldName_C1_Value>...<Name_C.fieldName_CN_Value>
    <Name_C.KeyFieldValue><Name_C.fieldName_C1_Value>...<Name_C.fieldName_CN_Value>
    the problem is that in this structure each line is not separated by a carriage return or a comma, I have all the information in a single line:
    <Name_A.KeyFieldValue><Name_A.fieldName_A1_Value>...<Name_A.fieldName_AN_Value><NumberRecordType_B><NumberRecordType_c><Name_B.KeyFieldValue><Name_B.fieldName_B1_Value>...<Name_B.fieldName_BN_Value>...<Name_B.KeyFieldValue><Name_B.fieldName_B1_Value>...<Name_B.fieldName_BN_Value><Name_C.KeyFieldValue><Name_C.fieldName_C1_Value>...<Name_C.fieldName_CN_Value>...<Name_C.KeyFieldValue><Name_C.fieldName_C1_Value>...<Name_C.fieldName_CN_Value>
    and the customer don't want to insert a line separator.
    Then, the question is:
    How can I get the XML structure from this structure?
    If possible, I don't want to develop new Module and add it in the JMS Module Sequence.
    PS I have already read the article "How to Use the Content Conversion Module with the XI 3 J2EE JMS Adapter.pdf" and it doesn't seem to help me.
    Best Regards,
    Paolo

    To get context parameters from your web.xml file you can simply get the ActionServlet object from an implementing action object class. In the perform (or execute) method make the following call.
    ServletContext context = getServlet().getServletContext();
    String tempContextVar =
    context.getInitParameter("<your context param >");

  • XSLT Mapping to convert u201C.CSVu201D file into XML Structure.

    Hi All,
    I wanted to know can we use XSLT Mapping to convert u201C.CSVu201D file into XML Structure.
    I am communicating between two XI Systems. First XI system is going to give u201C.CSVu201D file as main document. I need to post IDOC Corresponding to this. So what I want to do is read this u201C.CSVu201D file (Main document in payload) and first convet it into XML and then use second mapping which will convert XML to IDOC.
    I know this is possible with JAVA Mapping but just wanted to confirm can we do this with XSLT mapping as well?
    Regards,
    Gouri

    Hi Amit,
    I know this way it shd work as i am able see other XSLT files. But this particular file is not visible.
    I am copying following code only in sample.xslt file.
    <xsl:stylesheet
      xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
      xmlns:fn="fn"
      xmlns:xs="http://www.w3.org/2001/XMLSchema"
      version="2.0" exclude-result-prefixes="xs fn">
    <xsl:output indent="yes" encoding="US-ASCII" />
    <xsl:param name="pathToCSV" select="'file:///c:/csv.csv'" />
    <xsl:function name="fn:getTokens" as="xs:string+">
        <xsl:param name="str" as="xs:string" />
        <xsl:analyze-string select="concat($str, ',')" regex='(("["]*")+|[,]*),'>
            <xsl:matching-substring>
            <xsl:sequence select='replace(regex-group(1), "^""|""$|("")""", "$1")' />
            </xsl:matching-substring>
        </xsl:analyze-string>
    </xsl:function>
    <xsl:template match="/" name="main">
        <xsl:choose>
        <xsl:when test="unparsed-text-available($pathToCSV)">
            <xsl:variable name="csv" select="unparsed-text($pathToCSV)" />
            <xsl:variable name="lines" select="tokenize($csv, ' ')" as="xs:string+" />
            <xsl:variable name="elemNames" select="fn:getTokens($lines[1])" as="xs:string+" />
            <root>
            <xsl:for-each select="$lines[position() &gt; 1]">
                <row>
                <xsl:variable name="lineItems" select="fn:getTokens(.)" as="xs:string+" />
                <xsl:for-each select="$elemNames">
                    <xsl:variable name="pos" select="position()" />
                    <elem name="{.}">
                    <xsl:value-of select="$lineItems[$pos]" />
                    </elem>
                </xsl:for-each>
                </row>
            </xsl:for-each>
            </root>
        </xsl:when>
        <xsl:otherwise>
            <xsl:text>Cannot locate : </xsl:text><xsl:value-of select="$pathToCSV" />
        </xsl:otherwise>
        </xsl:choose>
    </xsl:template>
    </xsl:stylesheet>
    Is this correct?
    -Gouri

  • Convert IDOC XML structure to flat file - and now?

    Hi,
    we are working with input message ORDERS05 and want to convert it to flat file.
    So we used the implementation description from "how to convert an IDOC-XML structure to a flat file....".
    Looks like this is a standard procedure described here fitting for all IDOCs.
    We followed the guide, making XI ready for Abap-Mapping, implemented the Abap class like described, added an interface mapping with source ORDERS05 to a mess.type dummy destination, added with type Abap-class the class implemented from the guide and completed the Int.Dir. implementation.
    For comparism purpose we have two systems as receiver, one with a standard flat file with regular graph.mapping in XI, one with the Abap mapping.
    Result:
    Error description in SXMB_MONI:
    Didn´t expect something like that! The IDOC was delivered successfully to the other simple flat file receiver.
    Any idea what we made wrong (we are on SP17) or if there is a standard mistake you can do when following the guide?
    Best regards
    Dirk

    Hi,
    I've got the same problem. He the solution in my case:
    The problem is:
    My IDOC has no element <STDMES>, but the method IF_MAPPING~EXECUTE from the 'HOW-TO Guide' does not check this situation:
    el_element = idocument->find_from_name('STDMES').
    ls_edidc-stdmes = el_element->get_value().
    thows the exception.
    Solution:
    make shure that the field STDMESis set or change the method to:
    el_element = idocument->find_from_name('STDMES').
    if not el_element is initial.
        ls_edidc-stdmes = el_element->get_value().
    endif.
    Best regards
    Dieter

  • Converting string data from a web service respons into XML structure of XI

    Hi,
    We receive a string structure from a web service.
    The string structure has an xml type format, that is all the tags and its content are in one line .
    The WSDL file of the webservice defines its response structure as a string type.
    How do i convert this string into proper XML structure (predefined by me in Integration repository).
    OR how do i make XI understand this string as an XML structure for further processing.
    Later i have to map this XML message type into IDoc.
    Himani

    Hi Himani,
    Please find the code for ur requirement -
    String need to parse -<response_webservice><from_date>20080101</from_date><to_date>20080202</to_date></response_webservice>
    Below mentioned code will convert it to -<MT_DATA><FROMDATE>20080202</FROMDATE><TODATE>20080101</TODATE></MT_DATA>
    Create a Message type and map it like this using java mapping ( no need to use Graphical mapping).
    Use MT_DATA as source and map it to your target structure .
    import java.io.FileInputStream;
    import java.io.IOException;
    import java.io.StringReader;
    import java.util.HashMap;
    import java.util.Map;
    import javax.xml.parsers.DocumentBuilder;
    import javax.xml.parsers.DocumentBuilderFactory;
    import javax.xml.parsers.FactoryConfigurationError;
    import javax.xml.parsers.ParserConfigurationException;
    import javax.xml.transform.TransformerFactoryConfigurationError;
    import org.w3c.dom.DOMException;
    import org.w3c.dom.Document;
    import org.w3c.dom.Element;
    import org.w3c.dom.NodeList;
    import org.w3c.dom.Text;
    import org.xml.sax.InputSource;
    import org.xml.sax.SAXException;
    public class XMLParser {
         private Map param = null;
         public static void main(String[] args) {
              try {
                   XMLParser wdb = new XMLParser();
                   wdb.parse();
              } catch (Exception e) {
                   e.printStackTrace();
         public void setParameter(Map param) {
              this.param = param;
              if (param == null) {
                   this.param = new HashMap();
         public void parse() {
              String document = "<response_webservice><from_date>20080101</from_date><to_date>20080202</to_date></response_webservice>";
              try {
                   Document sdoc;
                   DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
                   // Using factory get an instance of document builder
                   DocumentBuilder db = dbf.newDocumentBuilder();
                   // parse using builder to get DOM representation of the XML file
                   sdoc = db.parse(new InputSource(new StringReader(document)));
                   Element docEle = sdoc.getDocumentElement();
                   NodeList nl = docEle.getElementsByTagName("from_date");
                   Element lstElmnt = (Element) nl.item(0);
                   NodeList nl1 = docEle.getElementsByTagName("to_date");
                   Element fstElmnt = (Element) nl1.item(0);
                   System.out.println(fstElmnt.getFirstChild().getNodeValue());
                   System.out.println(lstElmnt.getFirstChild().getNodeValue());
                   Document tdoc = db.newDocument();
                   Element structure = createElement("MT_DATA", null, tdoc);
                   tdoc.appendChild(structure);
                   Element statement = createElement("FROMDATE", fstElmnt.getFirstChild().getNodeValue(), tdoc);
                   structure.appendChild(statement);
                   Element statement2 = createElement("TODATE", lstElmnt.getFirstChild().getNodeValue(), tdoc);
                   structure.appendChild(statement2);
                   System.out.println("Struct is :::"+tdoc.getDocumentElement().toString());               
              } catch (DOMException e) {
                   // TODO Auto-generated catch block
                   e.printStackTrace();
              }  catch (IOException e) {
                   // TODO Auto-generated catch block
                   e.printStackTrace();
              } catch (FactoryConfigurationError e) {
                   // TODO Auto-generated catch block
                   e.printStackTrace();
              } catch (ParserConfigurationException e) {
                   // TODO Auto-generated catch block
                   e.printStackTrace();
              } catch (SAXException e) {
                   // TODO Auto-generated catch block
                   e.printStackTrace();
              } catch (TransformerFactoryConfigurationError e) {
                   // TODO Auto-generated catch block
                   e.printStackTrace();
         static Element createElement(String elementName, String content,
                   Document document) {
              Element returnElement;
              returnElement = document.createElement(elementName);
              if (content != null) {
                   Text T = document.createTextNode(content);
                   returnElement.appendChild(T);
              return returnElement;
         static Element createElement(String elementName, String content,
                   String attributeName, String attributeValue, Document document) {
              Element returnElement = createElement(elementName, content, document);
              returnElement.setAttribute(attributeName, attributeValue);
              return returnElement;
    Regards,
    Kishore

  • Mapping complete input XML structure into one field on target

    Hi,
    I have a scenario where I need to map the complete input XML structure as it is, into one field on target side. so can we achieve this in Graphical Mapping? If yes, please share your valuable info.
    Regards,
    Shiva.

    Hello,
    this is the java map code.just compile it and made a .zip file import it and use it Interface Mapping.
    import com.sap.aii.mapping.api.StreamTransformation;
    import com.sap.aii.mapping.api.AbstractTrace;
    import com.sap.aii.mapping.api.StreamTransformationConstants;
    import java.util.Map;
    import java.io.*;
    public class PayloadToXMLField1 implements StreamTransformation {
        String strXML = new String();
       //Declare the XML tag for your XML message
       String StartXMLTag = "<DocumentBody>";
       String EndXMLTag = "</DocumentBody>";
       //String StartXMLTag1 = "<Code>";
       //String EndXMLTag1 = "</Code>";
        AbstractTrace trace;
        private Map param = null;
        public void setParameter(Map param) {
            this.param = param;
        public void execute(InputStream in, OutputStream out) {
            trace =
                (AbstractTrace) param.get(
                    StreamTransformationConstants.MAPPING_TRACE);
            trace.addInfo("Process Started");
            try {
                StringBuffer strbuffer = new StringBuffer();
                byte[] b = new byte[4096];
                for (int n;(n = in.read(b)) != -1;) {
                    strbuffer.append(new String(b, 0, n));
                strXML = strbuffer.toString();
            } catch (Exception e) {
                System.out.println("Exception Occurred");
            String outputPayload =
                StartXMLTag
             + "<![CDATA["
             + strXML
             + "]]>"
             + EndXMLTag;
            try {
                out.write(outputPayload.getBytes());
             trace.addInfo("Process Completed");;
            } catch (Exception e) {
                trace.addInfo("Process Terminated: Error in writing out payload");;

  • Changing the XML Structure in "Submit as XML"

    Dear all,
    We have two PDF Templates which are submitted via a WebService using Submit as XML. For both templates we need the same structured XML output.
    Form 1 has the hierarchy like this (all subforms):
    Company
    Subsdiary
    Responsibles
    Footer
    so the xml looks like
    <creditrequest>
    <company>...</company>
    <subsdiary>...</subsdiary>
    <responsible>...</responsible>
    <footer>...</footer>
    </creditrequest>
    Form 2 has the hiearchy like this (all subforms):
    Responsibles
    Subsidiary
    Company
    Footer
    and the xml looks like
    <creditrequest>
    <responsible>...</responsible>
    <subsdiary>...</subsdiary>
    <company>...</company>
    <footer>...</footer>
    </creditrequest>
    So my question is how can influence the XML output order without changing the PDF hiearchy. This way I can change the XML output for Form 1 or Form 2 and both files would have the same XML structure to submit.
    I have checked the presubmit event and the javascript API to change XML string programmaticly but I couldn't find any possiblity to read/write the XML to submit.
    Thanks,
    Koray

    You can use JDOM and DOM. They are classes that load the XML File on memory and then you can modify it. I strongly recommend JDOM.

  • Missing images - "XML structure element, not in layout"

    I'm putting together handouts for several classes, which largely consists of copying and pasting text from Microsoft Word into InDesign CS5. Images I am placing manually. After re-organizing some of my files, one of my documents is now missing 118 links to images. However, none of these images are actually in my document - in the Links panel, each image says:
    "XML structure element, not in layout"
    Here's a screenshot of my links panel:
    These images are not supposed to be in the document at all. Clicking "Go To Link" does nothing. Is it possible that copy and pasting text from Word could have also copied the images in the Word document as well, without actually placing them on the pages? They now seem to be stuck in some kind of InDesign limbo.
    The only way I was able to get rid of them was to delete elements from the XML structure panel, however this deletes the content from my pages, which is not exactly helpful. Is there some way to just remove all of the missing image links from my document? Many thanks for any help!

    I was able to solve my problem. After displaying the Structure panel, I apparently had tons and tons of XML elements in the XML structure that were not placed in the document. I've never even seen the Structure panel before so this is totally new to me. I was able to delete all of the XML elements that were not placed in my document by checking their icons.

  • Order05 Idoc mapping in SRM XML Structure

    Hello All,
    I need to map Idoc order05 from ERP system into SAP provided SRM XML Structure.
    Anyone has done this sort of mapping before.
    Let me know the details as XML has got some 4800 fields and Idoc has some 800 fields and SRM XML seems to be superset of Idoc from ERP.
    Regards,Pankaj

    Hello,
    this is the java map code.just compile it and made a .zip file import it and use it Interface Mapping.
    import com.sap.aii.mapping.api.StreamTransformation;
    import com.sap.aii.mapping.api.AbstractTrace;
    import com.sap.aii.mapping.api.StreamTransformationConstants;
    import java.util.Map;
    import java.io.*;
    public class PayloadToXMLField1 implements StreamTransformation {
        String strXML = new String();
       //Declare the XML tag for your XML message
       String StartXMLTag = "<DocumentBody>";
       String EndXMLTag = "</DocumentBody>";
       //String StartXMLTag1 = "<Code>";
       //String EndXMLTag1 = "</Code>";
        AbstractTrace trace;
        private Map param = null;
        public void setParameter(Map param) {
            this.param = param;
        public void execute(InputStream in, OutputStream out) {
            trace =
                (AbstractTrace) param.get(
                    StreamTransformationConstants.MAPPING_TRACE);
            trace.addInfo("Process Started");
            try {
                StringBuffer strbuffer = new StringBuffer();
                byte[] b = new byte[4096];
                for (int n;(n = in.read(b)) != -1;) {
                    strbuffer.append(new String(b, 0, n));
                strXML = strbuffer.toString();
            } catch (Exception e) {
                System.out.println("Exception Occurred");
            String outputPayload =
                StartXMLTag
             + "<![CDATA["
             + strXML
             + "]]>"
             + EndXMLTag;
            try {
                out.write(outputPayload.getBytes());
             trace.addInfo("Process Completed");;
            } catch (Exception e) {
                trace.addInfo("Process Terminated: Error in writing out payload");;

  • Signer information does not match signer information of other classes

    I'm getting the exception "java.lang.SecurityException: class "javax.persistence.Cacheable"'s signer information does not match signer information of other classes in the same package". It appeared after upgrading to EclipseLink 1.2.0 - JPA 2.0 Preview. JPA 1.0 worked nicely, and I can also get the new version running by installing JPA through Eclipse. However, I want to have the JPA jar in C:\mydir\ and include it as any other jar-file. I have never signed an application before and this exception doesn't really tell me what to do next.
    Any help appreciated.
    SEVERE: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'forgotPwdController': Autowiring of fields failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private org.daisy.pipeonline.services.UserManager org.daisy.pipeonline.web.ForgotPwdController.userMan; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userManager' defined in URL [jar:file:/C:/Users/jostein.NLB/workspaces/pipeonline/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/pipeonline-web/WEB-INF/lib/pipeonline-core.jar!/META-INF/config/services-config.xml]: Cannot resolve reference to bean 'userDao' while setting bean property 'dao'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userDao': Injection of persistence fields failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in URL [jar:file:/C:/Users/jostein.NLB/workspaces/pipeonline/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/pipeonline-web/WEB-INF/lib/pipeonline-core.jar!/META-INF/config/datalayer-config.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: Exception [EclipseLink-28018] (Eclipse Persistence Services - 1.2.0.v20091016-r5565): org.eclipse.persistence.exceptions.EntityManagerSetupException
    Exception Description: Predeployment of PersistenceUnit [jpa] failed.
    Internal Exception: java.lang.SecurityException: class "javax.persistence.Cacheable"'s signer information does not match signer information of other classes in the same package
         at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessAfterInstantiation(AutowiredAnnotationBeanPostProcessor.java:243)
         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:959)
         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:472)
         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:409)
         at java.security.AccessController.doPrivileged(Native Method)
         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:380)
         at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:264)
         at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:221)
         at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:261)
         at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:185)
         at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:164)
         at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:429)
         at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:729)
         at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:381)
         at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:255)
         at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:199)
         at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:45)
         at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3934)
         at org.apache.catalina.core.StandardContext.start(StandardContext.java:4429)
         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
         at org.apache.catalina.core.StandardHost.start(StandardHost.java:722)
         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
         at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
         at org.apache.catalina.core.StandardService.start(StandardService.java:516)
         at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
         at org.apache.catalina.startup.Catalina.start(Catalina.java:583)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
         at java.lang.reflect.Method.invoke(Unknown Source)
         at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
         at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)

    I don't know. You said that you got the problem when you upgraded "EclipseLink 1.2.0 - JPA 2.0 Preview", so it's possible that you should ask the guys who did that package.

  • Indesign Comparing XML Structure

    Can Anyone help me ?????
    I have wasted a lot time in this query with no result please help me to achieve my desired output.
    i want to display all XmlAttributes of a xml structure in a TextFrame of indesign CS4 that match the following conditions :-
    1) for a selected Character Style ( KT), XmlAttribute of one document(i.e CHAPTER ) must have same value as other document(GLOSSARY) that is being compared. then keywords with same id & olinkend would be displayed in a text frame.
    snapshot 1 shows chapter with highlighted keyterm & its olinkend (which to be used for comparison).
    snapshot 2 shows Xml Structure of Glossary with highlighted glossentry & its id
    Snapshot 3 shows Xml Structure of chapter(containing keyterm its olinkend)
    Snapshot 4 shows Xml Structure of chapter(containing glossary)
    in above snapshot pathology,etiology,pathogenesis,infection and disease have same olinkend(keyterm in chapter) and id (glossentry in glossary) but Human Microbiome Project  do not have different id & olinkend so its not a keyterm. it should not be displayed in text frame with  keyterms but somehow it is tagged wrongly as KT .we dont want it to b displayed.
    my text frame displayed it as
    i want a javascript code to display only keyterms in a text frame( in active document i.e. chapter )where keyterm olinkend = glossentry id and finally save the data to excel file .
    i have taken this code from ADOBE FORUM plz modify this to achieve my output.
    var myDc =app.activeDocument;
    var mySty = myDc.characterStyles.everyItem().name;
    var myDia = app.dialogs.add({name:"Character Style Display Menu", canCancel:true});
         with(myDia.dialogColumns.add()){  
              with(borderPanels.add()){
                   with(dialogColumns.add()){staticTexts.add({staticLabel:"Select Character Style:  "});}
                        with(dialogColumns.add())
                                                                var SelSty = dropdowns.add({stringList:mySty, selectedIndex:0});}
    var myRes = myDia.show();
    if(myRes==true)
          var myChoice = mySty[SelSty.selectedIndex];
                myDia.destroy();
    else
    { exit();}
    app.findTextPreferences = app.changeTextPreferences = NothingEnum.nothing;
    app.findTextPreferences.appliedCharacterStyle = myChoice.toString();
    var myFind = app.findText(false).reverse();
    for(var a=myFind.length-1; a>=0; a--){
         var  myString= myFind[a];
         var myPg = myString.parentTextFrames[0].parent.name;
         var myCon = myString.contents;
         app.selection[0].insertionPoints[-1].contents = String(myCon+"\t"+myPg);
         app.selection[0].insertionPoints[-1].contents = "\r";
    app.findTextPreferences = app.changeTextPreferences = NothingEnum.nothing;
    if(myCon==null)
                                                      alert("Character Style not found");
    HOPE YOU WILL UNDERSTAND MY QUERY.
    THANX
    WAITING FOR REPLY.

    Could Peter or someone move this to the scripting forum, please?

  • OSB: Looping through XML Structure

    How could I loop through a WHOLE XML structure and check the contents of each node to determine whether it is a dateTime stamp?
    I attempted a for-each loop in OSB but I could not get my expected output
    A sample xml structure may look like this
    <ebo:CreateQuoteEBM >
        <ebo:DataArea>
          <ebo:CreateQuote>
            <ebo:Custom>
              <chubCommon:Quote>
                  <chubCommon:ItemDetail>
                         <chub:Name>Test</chub:Name>
                        <chub:Value>20130527T12:02:13<chub:Value>
                  </chubCommon:ItemDetail>
                  <chubCommon:Reference>
                      <chubCommon:ReferenceQualifier>Bid Submit Date</chubCommon:ReferenceQualifier>
                      <chubCommon:Value>20130527T12:02:13</chubCommon:Value>
                    </chubCommon:Reference>
              </chubCommon:Quote>
            </ebo:Custom>
          </ebo:CreateQuote>
        </ebo:DataArea>
      </ebo:CreateQuoteEBM>
    Bonus: If it is a dateTime stamp convert into a date
    Thanks!

    You can use FLOWR loop to loop though this, and then for each node check if conditon is (fn:data() is true and fn:matches()) to check if the node is of datetime type. fn:data() will give you the if the xml node has some data and then using fn:matches() you can compare it with the datetime pattern, You can use a regex pattern to compare 20130527T12:02:13 . For converting this date use fn:substring() get the data before "T" and use fucntion similar to this functx:mmddyyyy-to-date for converting to date.For converting to date you can also use substring to extract the data from node and then use below fucntion to convert to date.
    declare function functx:date
      ( $year as xs:anyAtomicType ,
      $month as xs:anyAtomicType ,
      $day as xs:anyAtomicType ) as xs:date {
      xs:date(
      concat(
      functx:pad-integer-to-length(xs:integer($year),4),'-',
      functx:pad-integer-to-length(xs:integer($month),2),'-',
      functx:pad-integer-to-length(xs:integer($day),2)))

  • Eyedropper for XML structure

    Is there way to use the Eyedropper (or some other tool that copies attributes) in the XML structure list (the left-hand pane in ID)? Or is there a third-party tool or plug-in that works with IDCS5.5 that can do this?
    I have a very long document (800-page book broken into 27 separate chapter files) that is being ported from ID to XML ultimately to be rendered online in a Drupal framework as a searchable website. We can easily apply named tags by mapping layout styles to tags, but then we have to differentiate tags with class attributes. That's where the Eyedropper tool would come in handy. But it has to work in the XML structure pane.
    Danke beaucoup, mes amigos

    Well, assuming you have valid XML, meaning a single root node, and are wanting to insert into multiple tables, then something like this should point you in the right direction
    [url http://odieweblog.wordpress.com/2012/05/10/how-to-load-xml-data-into-multiple-tables/]How To : Load XML data into multiple tables
    If you are just trying to insert multiple customers into a single table, then of course you can simplify that example greatly as it becomes a simple INSERT ... SELECT ... FROM ... XMLTABLE(...) setup

  • One Communication Channel for two XML-Structure

    Hi to all!
    i'm Newbee in XI.
    i register one Communication Channel to recieve two different XML-Structure and when i sent second structure there was a Mapping error, because XI waiting for first XML-Structure.
    I'd like to ask if there are any additional condition that i must tune up to make it possible or just it's impossible?

    Hi,
    Please refer below links
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/121b053d-0401-0010-539f-f9295efb7bad
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/3a913f71-0601-0010-7a83-dfd3208a9a0b
    how to find the URL of deployed Web services?
    Creating .NET Web service
    http://www.15seconds.com/issue/010430.htm
    Also refer SOAP Framework to generate the common wsdl for both the messages with single SOAP CC
    http://help.sap.com/saphelp_nw04s/helpdata/en/bb/ddb33d2ae46b3be10000000a114084/frameset.htm
    Thanks
    swarup

Maybe you are looking for

  • Imac unplugged affecting the mouse

    The power chord disconnected by mistake from the imac when it was turned on, shutting the computer down. When I turned it back on, the mouse became a lot jumpier. It no longer works as well as it used to. When I move it to a spot, it doesn't go direc

  • Cisco WLSE

    Hi, I am having problem configuring (managing) two devices with Cisco WLSE, after importing the file with AP IP address I get CDP Discovery completed, but I also get Number of devices (re)discovered 0. For all AP that I am able to configure(manage) I

  • Render File Offline; Project in a Loop

    I was rendering a complex part when FCX stopped and said a render file was offline or something. It was so many steps ago, I forget exactly. Eventually, I had to force quit FCX because it "froze up" on me. I went back to the autovault and got a sligh

  • SquirrelMail LDAP address book error

    Hello all - over the weekend I upgraded my OD Master/LDAP server and my Mail server (two separate boxes) to v10.5.5 of OS X server, and now my users are reporting that they can no longer use our LDAP-integrated address book in SquirrelMail... I tried

  • Anyone else getting errors when importing Music Library music into non-native apps?

    I have had a bunch of Music Production apps On my iPad for a long time and all the way through iOS four iOS 5 they worked just fine importing songs from my iPod library on my iPad and my iPhone however all of a sudden after the iOS six update they do