use of org.netbeans.lib.cvsclient.command.log.LogInformation in project intellij-community by JetBrains.
the class CvsHistoryProvider method createRevisions.
private List<VcsFileRevision> createRevisions(final CvsEnvironment connectionSettings, final File lightweightFileForFile) {
final LocalPathIndifferentLogOperation logOperation = new LocalPathIndifferentLogOperation(connectionSettings);
logOperation.addFile(lightweightFileForFile);
final CvsOperationExecutor executor = new CvsOperationExecutor(myProject);
final ArrayList<VcsFileRevision> result = new ArrayList<>();
executor.performActionSync(new CommandCvsHandler(CvsBundle.message("operation.name.load.file.content"), logOperation), new DefaultCvsOperationExecutorCallback() {
@Override
public void executionFinishedSuccessfully() {
final LogInformation firstLogInformation = logOperation.getFirstLogInformation();
if (firstLogInformation != null) {
final List<Revision> revisionList = firstLogInformation.getRevisionList();
for (Revision revision : revisionList) {
result.add(new CvsFileRevisionImpl(revision, lightweightFileForFile, firstLogInformation, connectionSettings, myProject));
}
}
}
});
Collections.sort(result, Collections.reverseOrder(VcsFileRevisionComparator.INSTANCE));
return result;
}
use of org.netbeans.lib.cvsclient.command.log.LogInformation in project intellij-community by JetBrains.
the class LoadHistoryOperation method fileInfoGenerated.
public void fileInfoGenerated(Object info) {
super.fileInfoGenerated(info);
if (!(info instanceof LogInformation)) {
return;
}
final LogInformation logInfo = (LogInformation) info;
final LogInformationWrapper wrapper = LogInformationWrapper.wrap(myEnvironment.getRepository(), myModule, logInfo);
if (wrapper == null) {
return;
}
myConsumer.consume(wrapper);
}
Aggregations