private static void exportSystemView(Session session, Node page) { try { // page at "content/geometrixx/en/services/banking"; File outputFile = new File(page.getName() + ".xml"); FileOutputStream out = new FileOutputStream(outputFile); session.exportSystemView(page.getPath(), out, false, false); } catch (PathNotFoundException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (RepositoryException e) { // TODO Auto-generated catch block e.printStackTrace(); } }
After run above code, and open the xml file, find no information export with folowing mark part:
[img]service.jpg[/img]
Anyone could know how to deal that?
Thanks in advance.
Solved! Go to Solution.
Views
Replies
Total Likes
That text is pulled in by reference. If you look at the generated XML, you should see something like this:
<sv:node sv:name="reference"> <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>nt:unstructured</sv:value> </sv:property> <sv:property sv:name="jcr:created" sv:type="Date"> <sv:value>2011-10-03T15:34:29.604+02:00</sv:value> </sv:property> <sv:property sv:name="jcr:createdBy" sv:type="String"> <sv:value>admin</sv:value> </sv:property> <sv:property sv:name="jcr:lastModified" sv:type="Date"> <sv:value>2011-10-03T15:36:07.429+02:00</sv:value> </sv:property> <sv:property sv:name="jcr:lastModifiedBy" sv:type="String"> <sv:value>admin</sv:value> </sv:property> <sv:property sv:name="path" sv:type="String"> <sv:value> /content/dam/geometrixx/documents/GeoMetrixx_Banking.indd/jcr:content/renditions/page/jcr:content/par/text_u167 </sv:value> </sv:property> <sv:property sv:name="sling:resourceType" sv:type="String"> <sv:value>foundation/components/reference</sv:value> </sv:property> </sv:node>
which corresponds to that block of text.
Views
Replies
Total Likes
That text is pulled in by reference. If you look at the generated XML, you should see something like this:
<sv:node sv:name="reference"> <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>nt:unstructured</sv:value> </sv:property> <sv:property sv:name="jcr:created" sv:type="Date"> <sv:value>2011-10-03T15:34:29.604+02:00</sv:value> </sv:property> <sv:property sv:name="jcr:createdBy" sv:type="String"> <sv:value>admin</sv:value> </sv:property> <sv:property sv:name="jcr:lastModified" sv:type="Date"> <sv:value>2011-10-03T15:36:07.429+02:00</sv:value> </sv:property> <sv:property sv:name="jcr:lastModifiedBy" sv:type="String"> <sv:value>admin</sv:value> </sv:property> <sv:property sv:name="path" sv:type="String"> <sv:value> /content/dam/geometrixx/documents/GeoMetrixx_Banking.indd/jcr:content/renditions/page/jcr:content/par/text_u167 </sv:value> </sv:property> <sv:property sv:name="sling:resourceType" sv:type="String"> <sv:value>foundation/components/reference</sv:value> </sv:property> </sv:node>
which corresponds to that block of text.
Views
Replies
Total Likes
Hi justin, thanks for your reply and i find the same reference part in the generated xml at my computer.
But is there any way to get that block of text with JCR API? Because i need to get the text then send to another server to translate.
Views
Replies
Total Likes
Sure, you can get an export of /content/dam/geometrixx/documents/GeoMetrixx_Banking.indd/jcr:content/renditions/page/jcr:content/par/text_u167
Views
Replies
Total Likes