private Map < File , File > getDataMap ( int vcode , String [ ] dataDirs , String snapshotName ) { Map < File , File > map = new HashMap < File , File > ( ) ; Map < File , File [ ] > src = vcode == 0 ? getDataMap_1_0 ( dataDirs ) : getDataMap_1_1 ( dataDirs ) ; for ( File ks : src . keySet ( ) ) { File [ ] sn = src . get ( ks ) ; if ( sn != null ) { for ( int i = 0 ; i < sn . length ; i ++ ) { if ( snapshotName . equals ( sn [ i ] . getName ( ) ) ) { map . put ( ks , sn [ i ] ) ; break ; } } } } return map ; }
keyspace - dir - > snapshot - dir