當前位置: 首頁>>代碼示例>>Java>>正文


Java RunsInCurrentThread類代碼示例

本文整理匯總了Java中org.fest.swing.annotation.RunsInCurrentThread的典型用法代碼示例。如果您正苦於以下問題:Java RunsInCurrentThread類的具體用法?Java RunsInCurrentThread怎麽用?Java RunsInCurrentThread使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


RunsInCurrentThread類屬於org.fest.swing.annotation包,在下文中一共展示了RunsInCurrentThread類的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: validateFileToChoose

import org.fest.swing.annotation.RunsInCurrentThread; //導入依賴的package包/類
@RunsInCurrentThread
private static <FileObject> void validateFileToChoose(VFSJFileChooser<FileObject> fileChooser, FileObject file) {
    VFSJFileChooser.SELECTION_MODE mode = fileChooser.getFileSelectionMode();
    boolean isFolder = fileChooser.getFileSystemView().isDirectory(file);
    if (mode == VFSJFileChooser.SELECTION_MODE.FILES_ONLY && isFolder)
        throw cannotSelectFile(file, "the file chooser cannot open directories");
    if (mode == VFSJFileChooser.SELECTION_MODE.DIRECTORIES_ONLY && !isFolder)
        throw cannotSelectFile(file, "the file chooser can only open directories");
}
 
開發者ID:shevek,項目名稱:vfsjfilechooser,代碼行數:10,代碼來源:VFSJFileChooserSelectFileTask.java

示例2: isMatching

import org.fest.swing.annotation.RunsInCurrentThread; //導入依賴的package包/類
/** Returns true if the given tag is the one we seek */
@RunsInCurrentThread
protected abstract boolean isMatching(@NotNull XmlTag tag);
 
開發者ID:jskierbi,項目名稱:intellij-ce-playground,代碼行數:4,代碼來源:TagMatcher.java

示例3: isRectangleVisible

import org.fest.swing.annotation.RunsInCurrentThread; //導入依賴的package包/類
@RunsInCurrentThread
private static boolean isRectangleVisible(final VNumber vNumber, final Rectangle r)
{
	final Rectangle visible = vNumber.getVisibleRect();
	return visible.contains(r.x, r.y);
}
 
開發者ID:metasfresh,項目名稱:metasfresh,代碼行數:7,代碼來源:VNumberDriver.java


注:本文中的org.fest.swing.annotation.RunsInCurrentThread類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。