public static String cat ( Object ... components ) { StringBuilder stringBuilder = new StringBuilder ( ) ; if ( components . length > 0 ) { stringBuilder . append ( components [ 0 ] ) ; for ( int i = 1 ; i < components . length ; ++ i ) { stringBuilder . append ( BagObject . PATH_SEPARATOR ) . append ( components [ i ] . toString ( ) ) ; } } return stringBuilder . toString ( ) ; }
Concatenate multiple string components to make a path