Package org.springmodules.jcr

Examples of org.springmodules.jcr.JcrCallback


     */
    @Test
    public void testAddNodeIfDoesntExist() {
        assertNotNull("JCR Template is null.", template);

        template.execute(new JcrCallback() {
            public Object doInJcr(Session session) throws RepositoryException {
                Node root = session.getRootNode();

                logger.debug("Starting from root node.  node={}", root);

View Full Code Here


     * Adds file to repository.
     */
    @Test
    public void testAddFileIfDoesntExist() {
        @SuppressWarnings("unused")
        Node node = (Node) template.execute(new JcrCallback() {
            @SuppressWarnings("unchecked")
            public Object doInJcr(Session session) throws RepositoryException,
                    IOException {
                Node resultNode = null;

View Full Code Here

    /**
     * Recurses through all nodes processing the callback
     * when a matching node is found.
     */
    public void recurse(final JcrNodeCallback callback) {
        template.execute(new JcrCallback() {
            public Object doInJcr(Session session) throws RepositoryException,
                    IOException {
                Node root = session.getRootNode();
                JcrConstants jcrConstants = new JcrConstants(session);
               
View Full Code Here

TOP

Related Classes of org.springmodules.jcr.JcrCallback

Copyright © 2018 www.massapicom. 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.