Examples of subpath()


Examples of org.modeshape.jcr.value.Path.subpath()

            }
            Path path = nodeChange.getPath();
            if (path.size() < 2) {
                return true;
            }
            Name firstSegmentName = path.subpath(0, 1).getLastSegment().getName();
            boolean isSystemLockChange = JcrLexicon.SYSTEM.equals(firstSegmentName)
                                         && ModeShapeLexicon.LOCKS.equals(path.getParent().getLastSegment().getName());
            return !isSystemLockChange;
        }

Examples of org.uberfire.java.nio.file.Path.subpath()

        assertThat( path.getName( 1 ).toString() ).isEqualTo( "to" );

        assertThat( path.getName( 2 ) ).isNotNull().isEqualTo( path.getFileName() );

        assertThat( path.subpath( 0, 1 ) ).isNotNull();
        assertThat( path.subpath( 0, 1 ).toString() ).isEqualTo( "path" );

        assertThat( path.subpath( 1, 2 ) ).isNotNull();
        assertThat( path.subpath( 1, 2 ).toString() ).isEqualTo( "to" );

        assertThat( path.subpath( 0, 2 ) ).isNotNull();
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.