if ( path.length == 1 ) {
listPackages( repository,
result );
} else if ( path.length == 2 && checkPackagePermission( path[1],
RoleTypes.PACKAGE_READONLY ) ) {
String[] snaps = repository.listPackageSnapshots( path[1] );
return snaps;
} else if ( path.length == 3 && checkPackagePermission( path[1],
RoleTypes.PACKAGE_READONLY ) ) {
Iterator<AssetItem> it = repository.loadPackageSnapshot( path[1],
path[2] ).getAssets();