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


Java DojoResource類代碼示例

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


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

示例1: getDojoResource

import com.ibm.xsp.minifier.DojoResource; //導入依賴的package包/類
@Override
public DojoResource getDojoResource(String name, DojoLibrary dojoLibrary) {
    Map<String,DojoResource> dojoResources = (Map<String,DojoResource>)dojoLibrary.getDojoResources();
    
    DojoResource r = dojoResources.get(name);
    if(r==null) {
        synchronized(this) {
            r = dojoResources.get(name);
            if(r==null) {
                r = loadDojoResource(name,dojoLibrary);
                if(r!=null) {
                    dojoResources.put(name, r);
                }
            }
        }
    }
    return r;
}
 
開發者ID:OpenNTF,項目名稱:XPagesExtensionLibrary,代碼行數:19,代碼來源:DWALoader.java

示例2: getDojoResource

import com.ibm.xsp.minifier.DojoResource; //導入依賴的package包/類
@Override
public DojoResource getDojoResource(String name, DojoLibrary dojoLibrary) {
	Map<String,DojoResource> dojoResources = getDojoResources(dojoLibrary);
   	
	DojoResource r = dojoResources.get(name);
	if(r==null) {
		synchronized(this) {
			r = dojoResources.get(name);
			if(r==null) {
				r = loadDojoResource(name,dojoLibrary);
				if(r!=null) {
					dojoResources.put(name, r);
				}
			}
		}
	}
	return r;
}
 
開發者ID:OpenNTF,項目名稱:XPagesExtensionLibrary,代碼行數:19,代碼來源:ExtLibLoader.java

示例3: loadDojoResource

import com.ibm.xsp.minifier.DojoResource; //導入依賴的package包/類
protected DojoResource loadDojoResource(String name, DojoLibrary dojoLibrary) {
    if(name.startsWith("extlib.")) { //$NON-NLS-1$
        List<ExtLibLoaderExtension> extensions = ExtLibLoaderExtension.getExtensions();
	    int size = extensions.size();
	    for(int i=0; i<size; i++) {
	        DojoResource r = loadDojoResource(name, dojoLibrary, extensions.get(i));
	        if(r!=null) {
	            return r;
	        }
	    }
	    return null;
    }
    // Look for resources...
    if( name.startsWith("!extlib.")) { // $NON-NLS-1$
        return new ExtLibDojoLocaleResource(dojoLibrary,name,ExtlibResourceProvider.BUNDLE_RES_PATH);
    }
    
    return null;
}
 
開發者ID:OpenNTF,項目名稱:XPagesExtensionLibrary,代碼行數:20,代碼來源:ExtLibLoader.java

示例4: getDojoResource

import com.ibm.xsp.minifier.DojoResource; //導入依賴的package包/類
@Override
public DojoResource getDojoResource(String name, DojoLibrary dojoLibrary) throws IOException {
	@SuppressWarnings("unchecked")
	Map<String, DojoResource> dojoResources = (Map<String, DojoResource>) dojoLibrary.getDojoResources();

	DojoResource r = dojoResources.get(name);
	if (r == null) {
		synchronized (this) {
			r = dojoResources.get(name);
			if (r == null) {
				r = loadDojoResource(name, dojoLibrary);
				if (r != null) {
					dojoResources.put(name, r);
				}
			}
		}
	}
	return r;

}
 
開發者ID:OpenNTF,項目名稱:XPagesToolkit,代碼行數:21,代碼來源:AbstractResourceLoader.java

示例5: loadDojoResource

import com.ibm.xsp.minifier.DojoResource; //導入依賴的package包/類
protected DojoResource loadDojoResource(String name, DojoLibrary dojoLibrary) {
    if(name.startsWith("dwa.")) { // $NON-NLS-1$
        String dojoName = name;
        String path = ExtlibResourceProvider.DWA_RES_PATH+StringUtil.replace(dojoName, '.', '/')+".js"; // $NON-NLS-1$
        URL u = ExtLibUtil.getResourceURL(DominoPluginActivator.instance.getBundle(), path);
        if(u!=null) {
            return new UrlDojoResource(dojoLibrary,name,u);
        }
    }
    // Look for resources...
    if( name.startsWith("!dwa.")) { // $NON-NLS-1$
        return new DWADojoLocaleResource(dojoLibrary,name,ExtlibResourceProvider.DWA_RES_PATH);
    }
    return null;
}
 
開發者ID:OpenNTF,項目名稱:XPagesExtensionLibrary,代碼行數:16,代碼來源:DWALoader.java

示例6: getDojoResources

import com.ibm.xsp.minifier.DojoResource; //導入依賴的package包/類
@SuppressWarnings("unchecked") //$NON-NLS-1$
private Map<String, DojoResource> getDojoResources(DojoLibrary dojoLibrary) {
    return dojoLibrary.getDojoResources();
}
 
開發者ID:OpenNTF,項目名稱:XPagesExtensionLibrary,代碼行數:5,代碼來源:ExtLibLoader.java


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