本文整理汇总了Java中org.eclipse.jdt.internal.ui.text.java.IProblemRequestorExtension.setIsHandlingTemporaryProblems方法的典型用法代码示例。如果您正苦于以下问题:Java IProblemRequestorExtension.setIsHandlingTemporaryProblems方法的具体用法?Java IProblemRequestorExtension.setIsHandlingTemporaryProblems怎么用?Java IProblemRequestorExtension.setIsHandlingTemporaryProblems使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.eclipse.jdt.internal.ui.text.java.IProblemRequestorExtension
的用法示例。
在下文中一共展示了IProblemRequestorExtension.setIsHandlingTemporaryProblems方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: enableHandlingTemporaryProblems
import org.eclipse.jdt.internal.ui.text.java.IProblemRequestorExtension; //导入方法依赖的package包/类
/**
* Switches the state of problem acceptance according to the value in the preference store.
*/
protected void enableHandlingTemporaryProblems() {
boolean enable= isHandlingTemporaryProblems();
for (Iterator<FileInfo> iter= getFileInfosIterator(); iter.hasNext();) {
FileInfo info= iter.next();
if (info.fModel instanceof IProblemRequestorExtension) {
IProblemRequestorExtension extension= (IProblemRequestorExtension) info.fModel;
extension.setIsHandlingTemporaryProblems(enable);
}
}
}
开发者ID:trylimits,项目名称:Eclipse-Postfix-Code-Completion,代码行数:14,代码来源:CompilationUnitDocumentProvider.java
示例2: enableHandlingTemporaryProblems
import org.eclipse.jdt.internal.ui.text.java.IProblemRequestorExtension; //导入方法依赖的package包/类
/**
* Switches the state of problem acceptance according to the value in the preference store.
*/
protected void enableHandlingTemporaryProblems() {
boolean enable = isHandlingTemporaryProblems();
for (Iterator<?> iter = getFileInfosIterator(); iter.hasNext();) {
FileInfo info = (FileInfo) iter.next();
if (info.fModel instanceof IProblemRequestorExtension) {
IProblemRequestorExtension extension = (IProblemRequestorExtension) info.fModel;
extension.setIsHandlingTemporaryProblems(enable);
}
}
}
示例3: createFileInfo
import org.eclipse.jdt.internal.ui.text.java.IProblemRequestorExtension; //导入方法依赖的package包/类
@Override
protected FileInfo createFileInfo(Object element) throws CoreException {
FileInfo info = super.createFileInfo(element);
IAnnotationModel requestor = info.fModel;
if (requestor instanceof IProblemRequestorExtension) {
IProblemRequestorExtension extension = (IProblemRequestorExtension) requestor;
extension.setIsActive(false);
extension.setIsHandlingTemporaryProblems(isHandlingTemporaryProblems());
}
return info;
}
示例4: createFileInfo
import org.eclipse.jdt.internal.ui.text.java.IProblemRequestorExtension; //导入方法依赖的package包/类
@Override
protected FileInfo createFileInfo(Object element) throws CoreException {
ICompilationUnit original= null;
if (element instanceof IFileEditorInput) {
IFileEditorInput input= (IFileEditorInput) element;
original= createCompilationUnit(input.getFile());
if (original == null)
return null;
}
FileInfo info= super.createFileInfo(element);
if (!(info instanceof CompilationUnitInfo))
return null;
if (original == null)
original= createFakeCompiltationUnit(element, false);
if (original == null)
return null;
CompilationUnitInfo cuInfo= (CompilationUnitInfo) info;
setUpSynchronization(cuInfo);
IProblemRequestor requestor= cuInfo.fModel instanceof IProblemRequestor ? (IProblemRequestor) cuInfo.fModel : null;
if (requestor instanceof IProblemRequestorExtension) {
IProblemRequestorExtension extension= (IProblemRequestorExtension) requestor;
extension.setIsActive(false);
extension.setIsHandlingTemporaryProblems(isHandlingTemporaryProblems());
}
IResource resource= original.getResource();
if (JavaModelUtil.isPrimary(original) && (resource == null || resource.exists()))
original.becomeWorkingCopy(requestor, getProgressMonitor());
cuInfo.fCopy= original;
if (cuInfo.fModel instanceof CompilationUnitAnnotationModel) {
CompilationUnitAnnotationModel model= (CompilationUnitAnnotationModel) cuInfo.fModel;
model.setCompilationUnit(cuInfo.fCopy);
}
if (cuInfo.fModel != null)
cuInfo.fModel.addAnnotationModelListener(fGlobalAnnotationModelListener);
return cuInfo;
}
开发者ID:trylimits,项目名称:Eclipse-Postfix-Code-Completion,代码行数:45,代码来源:CompilationUnitDocumentProvider.java