use of org.netbeans.lib.cvsclient.file.FileObject in project intellij-community by JetBrains.
the class FileStateRequestsProgressHandler method requestSent.
public void requestSent(IRequest request) {
if (!(request instanceof AbstractFileStateRequest)) {
return;
}
final AbstractFileStateRequest fileStateRequest = (AbstractFileStateRequest) request;
final FileObject fileObject = fileStateRequest.getFileObject();
if (!fileObjects.remove(fileObject)) {
return;
}
count++;
notifyProgress(count, maxCount, progressViewer);
}
use of org.netbeans.lib.cvsclient.file.FileObject in project intellij-community by JetBrains.
the class FileSystemScanner method scanDirectory.
private List<DirectoryObject> scanDirectory(DirectoryObject directoryObject, CvsFiles cvsFiles) throws IOException {
if (!clientEnvironment.getLocalFileReader().exists(directoryObject, clientEnvironment.getCvsFileSystem())) {
return Collections.emptyList();
}
cvsFiles.add(CvsFile.createCvsDirectory(directoryObject));
final Set<String> subDirectoryNames = new HashSet<>();
final LocalFiles localFiles = new LocalFiles(directoryObject, clientEnvironment);
// get all the entries we know about, and process them
final Collection<Entry> entries = clientEnvironment.getAdminReader().getEntries(directoryObject, clientEnvironment.getCvsFileSystem());
for (final Entry entry : entries) {
if (entry.isDirectory()) {
subDirectoryNames.add(entry.getFileName());
} else {
final FileObject fileObject = FileObject.createInstance(directoryObject, entry.getFileName());
final boolean fileExists = clientEnvironment.getLocalFileReader().exists(fileObject, clientEnvironment.getCvsFileSystem());
cvsFiles.add(CvsFile.createCvsFileForEntry(fileObject, entry, fileExists));
localFiles.removeFile(entry.getFileName());
}
}
for (final String fileName : localFiles.getFileNames()) {
cvsFiles.add(CvsFile.createCvsFileForExistingFile(FileObject.createInstance(directoryObject, fileName)));
}
final List<DirectoryObject> subDirectories = new ArrayList<>(subDirectoryNames.size());
for (final String directoryName : subDirectoryNames) {
subDirectories.add(DirectoryObject.createInstance(directoryObject, directoryName));
}
return subDirectories;
}
use of org.netbeans.lib.cvsclient.file.FileObject in project intellij-community by JetBrains.
the class UpdateMessageParser method processUnknown.
private void processUnknown(String fileName) {
final FileObject fileObject = cvsFileSystem.unixFileNameToFileObject(fileName);
ensureExistingFileInfoContainer(fileObject);
fileInfo.setType("?");
}
Aggregations