private static VirtualFile[] toVirtualFiles(File[] files){
  if (files == null)   return null;
  List<VirtualFile> vFiles=new ArrayList<VirtualFile>(files.length);
  for (int i=0; i < files.length; i++) {
    if (files[i] != null)     vFiles.add(new LocalFile(files[i]));
  }
  return vFiles.toArray(new VirtualFile[vFiles.size()]);
}

private static VirtualFile [ ] toVirtualFiles ( File [ ] files ) { if ( files == null ) return null ; List < VirtualFile > vFiles = new ArrayList < VirtualFile > ( files . length ) ; for ( int i = 0 ; i < files . length ; i ++ ) { if ( files [ i ] != null ) vFiles . add ( new LocalFile ( files [ i ] ) ) ; } return vFiles . toArray ( new VirtualFile [ vFiles . size ( ) ] ) ; }
converts a list of file ( s ) into a list of virtualfile ( s ) . the virtualfile implementation is flex2 . compiler . io . localfile .
