Examples of exportSystemView()


Examples of javax.jcr.Session.exportSystemView()

      File exportFile = isSystemViewExport ? File.createTempFile("sys-export", ".xml") : File.createTempFile("doc-export", ".xml");
      exportFile.deleteOnExit();
     
      if (isSystemViewExport)
      {
         session1.exportSystemView(subRoot1.getPath(), new FileOutputStream(exportFile), false, false);
      }
      else
      {
         session1.exportDocumentView(subRoot1.getPath(), new FileOutputStream(exportFile), false, false);
      }
View Full Code Here

Examples of javax.jcr.Session.exportSystemView()

            random.nextBytes(data);
            test.setProperty("data", new ByteArrayInputStream(data));
            test.save();
            session.save();
            ByteArrayOutputStream out = new ByteArrayOutputStream();
            session.exportSystemView("/testBinary", out, false, false);
            byte[] output = out.toByteArray();
            Node test2 = root.addNode("testBinary2");
            Node test3 = root.addNode("testBinary3");
            session.save();
            session.importXML("/testBinary2", new ByteArrayInputStream(output), ImportUUIDBehavior.IMPORT_UUID_CREATE_NEW);
View Full Code Here

Examples of javax.jcr.Session.exportSystemView()

            random.nextBytes(data);
            test.setProperty("data", new ByteArrayInputStream(data));
            test.save();
            session.save();
            ByteArrayOutputStream out = new ByteArrayOutputStream();
            session.exportSystemView("/testBinary", out, false, false);
            byte[] output = out.toByteArray();
            Node test2 = root.addNode("testBinary2");
            Node test3 = root.addNode("testBinary3");
            session.save();
            session.importXML("/testBinary2", new ByteArrayInputStream(output), ImportUUIDBehavior.IMPORT_UUID_CREATE_NEW);
View Full Code Here

Examples of javax.jcr.Session.exportSystemView()

        tmpFile.deleteOnExit();

        // export system view of /p
        OutputStream out = new FileOutputStream(tmpFile);
        try {
            session.exportSystemView(p.getPath(), out, false, false);
        } finally {
            out.close();
        }

        // delete p and save
View Full Code Here

Examples of javax.jcr.Session.exportSystemView()

        tmpFile.deleteOnExit();

        // export system view of /a1/b1
        OutputStream out = new FileOutputStream(tmpFile);
        try {
            session.exportSystemView(b1.getPath(), out, false, false);
        } finally {
            out.close();
        }

        // and import again underneath /a3
View Full Code Here

Examples of org.brixcms.jcr.api.JcrSession.exportSystemView()

                            containerResponseOutputStream = containerResponse.getOutputStream();
                        }
                        catch (IOException e) {
                            throw new RuntimeException(e);
                        }
                        session.exportSystemView(brix.getRootPath(), containerResponseOutputStream, false, false);
                    }
                });
            }
        });
View Full Code Here

Examples of org.exoplatform.services.jcr.core.ExtendedSession.exportSystemView()

      if (isSystemView)
      {

         if (isStream)
         {
            extendedSession.exportSystemView(exportRootNode.getPath(), outStream, false, false);
         }
         else
         {
            SAXTransformerFactory saxFact = (SAXTransformerFactory)TransformerFactory.newInstance();
            TransformerHandler handler = saxFact.newTransformerHandler();
View Full Code Here

Examples of org.exoplatform.services.jcr.core.ExtendedSession.exportSystemView()

         else
         {
            SAXTransformerFactory saxFact = (SAXTransformerFactory)TransformerFactory.newInstance();
            TransformerHandler handler = saxFact.newTransformerHandler();
            handler.setResult(new StreamResult(outStream));
            extendedSession.exportSystemView(exportRootNode.getPath(), handler, false, false);
         }
      }
      else
      {
         if (isStream)
View Full Code Here

Examples of org.exoplatform.services.jcr.core.ExtendedSession.exportSystemView()

     FileOutputStream outStream = new FileOutputStream(file);

     if (isSystemView) {

       if (isStream) {
         extendedSession.exportSystemView(exportRootNode.getPath(), outStream, false, false);
       } else {
         SAXTransformerFactory saxFact = (SAXTransformerFactory) TransformerFactory.newInstance();
         TransformerHandler handler = saxFact.newTransformerHandler();
         handler.setResult(new StreamResult(outStream));
         extendedSession.exportSystemView(exportRootNode.getPath(), handler, false, false);
View Full Code Here

Examples of org.exoplatform.services.jcr.core.ExtendedSession.exportSystemView()

         extendedSession.exportSystemView(exportRootNode.getPath(), outStream, false, false);
       } else {
         SAXTransformerFactory saxFact = (SAXTransformerFactory) TransformerFactory.newInstance();
         TransformerHandler handler = saxFact.newTransformerHandler();
         handler.setResult(new StreamResult(outStream));
         extendedSession.exportSystemView(exportRootNode.getPath(), handler, false, false);
       }
     } else {
       if (isStream) {
         extendedSession.exportDocumentView(exportRootNode.getPath(), outStream, false, false);
       } else {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.