当前位置: 首页>>代码示例>>Java>>正文


Java PatternSet.getIncludePatterns方法代码示例

本文整理汇总了Java中org.apache.tools.ant.types.PatternSet.getIncludePatterns方法的典型用法代码示例。如果您正苦于以下问题:Java PatternSet.getIncludePatterns方法的具体用法?Java PatternSet.getIncludePatterns怎么用?Java PatternSet.getIncludePatterns使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.apache.tools.ant.types.PatternSet的用法示例。


在下文中一共展示了PatternSet.getIncludePatterns方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: fixJarName

import org.apache.tools.ant.types.PatternSet; //导入方法依赖的package包/类
private String fixJarName(String prefixDir, String name) {
    if (prefixDir.endsWith("locale/") && baseFiles != null) {
        prefixDir = prefixDir.substring(0, prefixDir.length() - 7);
        PatternSet bf = (PatternSet)getProject().getReference(baseFiles);
        for (String p : bf.getIncludePatterns(getProject())) {
            if (p.startsWith(prefixDir)) {
                String realName = p.substring(prefixDir.length());
                if (realName.indexOf('/') != -1 || realName.indexOf('\\') != -1) {
                    continue;
                }
                int indx = realName.indexOf(name);
                if (indx == -1) {
                    continue;
                }
                return realName.substring(0, indx + name.length());
            }
        }
    }
    
    
    if (name.equals("autoupdate-ui_nb")) {
        return "org-netbeans-modules-autoupdate-ui_nb";
    }
    if (name.equals("options-api_nb")) {
        return "org-netbeans-modules-options-api_nb";
    }
    if (name.equals("uihandler_nb")) {
        return "org-netbeans-modules-uihandler_nb";
    }
    return name;
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:32,代码来源:LocFiles.java

示例2: setJars

import org.apache.tools.ant.types.PatternSet; //导入方法依赖的package包/类
/**
 * Setter for the "jars" attribute (required if no "jarfileset" is present)
 * 
 * @deprecated Use <jarfileset> and/or <jarfilelist> nested tasks instead. 
 * 
 * @param s A list of jar files or patternsets (space or comma seperated)
 */
public void setJars(String s) {
	PatternSet patset = new PatternSet();
	patset.setIncludes(s);

	String[] jarNames = patset.getIncludePatterns(getProject());

	for (int i = 0; i < jarNames.length; i++)
		mJarAttrs.add(getProject().resolveFile(jarNames[i]));
}
 
开发者ID:UltraMixer,项目名称:JarBundler,代码行数:17,代码来源:JarBundler.java

示例3: setExecs

import org.apache.tools.ant.types.PatternSet; //导入方法依赖的package包/类
/**
 * Setter for the "execs" attribute
 * 
 * @deprecated Use &lt;execfileset/&gt; or &lt;execfilelist/&gt; nested tasks instead.
 * 
 * @param s A list of files or patternsets (space or comma seperated)
 */
public void setExecs(String s) {
	PatternSet patset = new PatternSet();
	patset.setIncludes(s);

	String[] execNames = patset.getIncludePatterns(getProject());

	for (int i = 0; i < execNames.length; i++) {
		File f = new File(execNames[i]);
		mExecAttrs.add(f);
	}
}
 
开发者ID:UltraMixer,项目名称:JarBundler,代码行数:19,代码来源:JarBundler.java

示例4: setExtraclasspath

import org.apache.tools.ant.types.PatternSet; //导入方法依赖的package包/类
/**
 * Setter for the "extraclasspath" attribute (optional)
 * 
 * @param s A list of files or patternsets (space or comma seperated)
 */
public void setExtraclasspath(String s) {
	if (s == null || s.trim().equals("")) return;
	PatternSet patset = new PatternSet();
	patset.setIncludes(s);

	String[] cpNames = patset.getIncludePatterns(getProject());

	for (int i = 0; i < cpNames.length; i++) {
		File f = new File(cpNames[i]);
		mExtraClassPathAttrs.add(f);
	}
}
 
开发者ID:UltraMixer,项目名称:JarBundler,代码行数:18,代码来源:JarBundler.java

示例5: setJars

import org.apache.tools.ant.types.PatternSet; //导入方法依赖的package包/类
/**
 * Setter for the "jars" attribute (required if no "jarfileset" is present)
 */
public void setJars(String s) {
	PatternSet patset = new PatternSet();
	patset.setIncludes(s);

	String[] jarNames = patset.getIncludePatterns(getProject());

	for (int i = 0; i < jarNames.length; i++)
		mJarAttrs.add(getProject().resolveFile(jarNames[i]));
}
 
开发者ID:tofi86,项目名称:Jarbundler,代码行数:13,代码来源:JarBundler.java

示例6: setExecs

import org.apache.tools.ant.types.PatternSet; //导入方法依赖的package包/类
/**
 * Setter for the "execs" attribute (optional)
 */
public void setExecs(String s) {
	PatternSet patset = new PatternSet();
	patset.setIncludes(s);

	String[] execNames = patset.getIncludePatterns(getProject());

	for (int i = 0; i < execNames.length; i++) {
		File f = new File(execNames[i]);
		mExecAttrs.add(f);
	}
}
 
开发者ID:tofi86,项目名称:Jarbundler,代码行数:15,代码来源:JarBundler.java

示例7: setExtraclasspath

import org.apache.tools.ant.types.PatternSet; //导入方法依赖的package包/类
/**
 * Setter for the "extraclasspath" attribute (optional)
 */
public void setExtraclasspath(String s) {
	if (s == null || s.trim().equals("")) return;
	PatternSet patset = new PatternSet();
	patset.setIncludes(s);

	String[] cpNames = patset.getIncludePatterns(getProject());

	for (int i = 0; i < cpNames.length; i++) {
		File f = new File(cpNames[i]);
		mExtraClassPathAttrs.add(f);
	}
}
 
开发者ID:tofi86,项目名称:Jarbundler,代码行数:16,代码来源:JarBundler.java

示例8: hasPatterns

import org.apache.tools.ant.types.PatternSet; //导入方法依赖的package包/类
private boolean hasPatterns(PatternSet ps) {
    String[] includePatterns = ps.getIncludePatterns(getProject());
    String[] excludePatterns = ps.getExcludePatterns(getProject());
    return (includePatterns != null && includePatterns.length > 0)
        || (includePatterns != null && excludePatterns.length > 0);
}
 
开发者ID:apache,项目名称:ant,代码行数:7,代码来源:Files.java

示例9: getS3Scanner

import org.apache.tools.ant.types.PatternSet; //导入方法依赖的package包/类
/**
 * Returns a file scanner for an S3 repository.
 * 
 * @param bucket The bucket to scan
 * @param patterns The patterns to scan for
 * @param baseDirectory The 'directory' to start the scan at
 * @return An initialized scanner
 */
protected S3Scanner getS3Scanner(S3Bucket bucket, PatternSet patterns, String baseDirectory) {
    return new S3Scanner(bucket, baseDirectory, patterns.getIncludePatterns(this.project), patterns.getExcludePatterns(this.project));
}
 
开发者ID:spring-projects,项目名称:aws-ant,代码行数:12,代码来源:AbstractS3Operation.java


注:本文中的org.apache.tools.ant.types.PatternSet.getIncludePatterns方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。