public static String makePath ( String parent , String firstChild , String ... restChildren ) { StringBuilder path = new StringBuilder ( ) ; joinPath ( path , parent , firstChild ) ; if ( restChildren == null ) { return path . toString ( ) ; } else { for ( String child : restChildren ) { joinPath ( path , "" , child ) ; } return path . toString ( ) ; } }
Given a parent path and a list of children nodes create a combined full path