Examples of exportDocumentView()


Examples of javax.jcr.Session.exportDocumentView()

      final String fullPath = "/" + EXO_REGISTRY + "/" + entryPath;
      Session session = session(sessionProvider, repositoryService.getCurrentRepository());
      try
      {
         ByteArrayOutputStream out = new ByteArrayOutputStream();
         session.exportDocumentView(fullPath, out, true, false);
         return RegistryEntry.parse(out.toByteArray());
      }
      catch (IOException e)
      {
         throw new RepositoryException("Can't export node " + fullPath + " to XML representation " + e);
View Full Code Here

Examples of javax.jcr.Session.exportDocumentView()

        tmpFile.deleteOnExit();

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

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

Examples of javax.jcr.Session.exportDocumentView()

      final String fullPath = "/" + EXO_REGISTRY + "/" + entryPath;
      Session session = session(sessionProvider, repositoryService.getCurrentRepository());
      try
      {
         ByteArrayOutputStream out = new ByteArrayOutputStream();
         session.exportDocumentView(fullPath, out, true, false);
         return RegistryEntry.parse(out.toByteArray());
      }
      catch (IOException e)
      {
         throw new RepositoryException("Can't export node " + fullPath + " to XML representation " + e);
View Full Code Here

Examples of javax.jcr.Session.exportDocumentView()

      final String fullPath = "/" + EXO_REGISTRY + "/" + entryPath;
      Session session = session(sessionProvider, repositoryService.getCurrentRepository());
      try
      {
         ByteArrayOutputStream out = new ByteArrayOutputStream();
         session.exportDocumentView(fullPath, out, true, false);
         return RegistryEntry.parse(out.toByteArray());
      }
      catch (IOException e)
      {
         throw new RepositoryException("Can't export node " + fullPath + " to XML representation " + e);
View Full Code Here

Examples of javax.jcr.Session.exportDocumentView()

      final String fullPath = "/" + EXO_REGISTRY + "/" + entryPath;
      Session session = session(sessionProvider, repositoryService.getCurrentRepository());
      try
      {
         ByteArrayOutputStream out = new ByteArrayOutputStream();
         session.exportDocumentView(fullPath, out, true, false);
         return RegistryEntry.parse(out.toByteArray());
      }
      catch (IOException e)
      {
         throw new RepositoryException("Can't export node " + fullPath + " to XML representation " + e);
View Full Code Here

Examples of javax.jcr.Session.exportDocumentView()

      final String fullPath = "/" + EXO_REGISTRY + "/" + entryPath;
      Session session = session(sessionProvider, repositoryService.getCurrentRepository());
      try
      {
         ByteArrayOutputStream out = new ByteArrayOutputStream();
         session.exportDocumentView(fullPath, out, true, false);
         return RegistryEntry.parse(out.toByteArray());
      }
      catch (IOException e)
      {
         throw new RepositoryException("Can't export node " + fullPath + " to XML representation " + e);
View Full Code Here

Examples of javax.jcr.Session.exportDocumentView()

         bos = new ByteArrayOutputStream();
         if (viewType != null && (viewType.equalsIgnoreCase("system") || viewType.equalsIgnoreCase("sys")))
            session.exportSystemView(path(repoPath), bos, false, false);
         else
            session.exportDocumentView(path(repoPath), bos, false, false);

      }
      catch (LoginException e)
      {
         return Response.status(HTTPStatus.FORBIDDEN).entity(e.getMessage()).build();
View Full Code Here

Examples of javax.jcr.Session.exportDocumentView()

      final String fullPath = "/" + EXO_REGISTRY + "/" + entryPath;
      Session session = session(sessionProvider, repositoryService.getCurrentRepository());
      try
      {
         ByteArrayOutputStream out = new ByteArrayOutputStream();
         session.exportDocumentView(fullPath, out, true, false);
         return RegistryEntry.parse(out.toByteArray());
      }
      catch (IOException e)
      {
         throw new RepositoryException("Can't export node " + fullPath + " to XML representation " + e);
View Full Code Here

Examples of javax.jcr.Session.exportDocumentView()

         bos = new ByteArrayOutputStream();
         if (viewType != null && (viewType.equalsIgnoreCase("system") || viewType.equalsIgnoreCase("sys")))
            session.exportSystemView(path(repoPath), bos, false, false);
         else
            session.exportDocumentView(path(repoPath), bos, false, false);

      }
      catch (LoginException e)
      {
         return Response.status(HTTPStatus.FORBIDDEN).entity(e.getMessage()).build();
View Full Code Here

Examples of javax.jcr.Session.exportDocumentView()

      assertTrue("BEFORE EXPORT/IMPORT. Binary content must be same", checkBinaryEquals(etalonData, storedData));

      File outputFile = File.createTempFile("jcr_bin_test", ".tmp");
      outputFile.deleteOnExit();

      session2.exportDocumentView(testNode.getPath(), new FileOutputStream(outputFile), false, false);

      testNode.remove();
      session2.save();

      try
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.