Examples of mapFileName()


Examples of org.apache.tools.ant.util.FileNameMapper.mapFileName()

    String[] list = scanner.getIncludedFiles();

    for (int i = 0; i<list.length; i++)
    {
      String[] dest = mapperImpl.mapFileName(list[i]);

      if (dest!=null)
        for (int j = 0; j<dest.length; j++)
        {
          log("Transforming "+list[i]+" to "+dest[j], Project.MSG_DEBUG);
View Full Code Here

Examples of org.apache.tools.ant.util.FileNameMapper.mapFileName()

    String[] list = scanner.getIncludedFiles();

    for (int i = 0; i<list.length; i++)
    {
      String[] dest = mapperImpl.mapFileName(list[i]);

      if (dest!=null)
        for (int j = 0; j<dest.length; j++)
        {
          log("Transforming "+list[i]+" to "+dest[j], Project.MSG_DEBUG);
View Full Code Here

Examples of org.apache.tools.ant.util.FileNameMapper.mapFileName()

                //calculate our destination directory; it is either the destDir
                //attribute, or the base dir of the fileset (for in situ updates)
                File toDir = hasDestDir ? destDir : fr.getBaseDir();

                //determine the destination filename via the mapper
                String[] destFilenames = destMapper.mapFileName(fr.getName());
                if (destFilenames == null || destFilenames.length != 1) {
                    //we only like simple mappers.
                    throw new BuildException(ERROR_BAD_MAP + fr.getFile());
                }
                File destFile = new File(toDir, destFilenames[0]);
View Full Code Here

Examples of org.apache.tools.ant.util.FileNameMapper.mapFileName()

            if (value != null) {
                // may be null if a system property has been added
                // after the project instance has been initialized
                if (m != null) {
                    //map the names
                    String[] newname = m.mapFileName(name);
                    if (newname != null) {
                        name = newname[0];
                    }
                }
                properties.setProperty(name, value);
View Full Code Here

Examples of org.apache.tools.ant.util.FileNameMapper.mapFileName()

                mapper = mapperElement.getImplementation();
            } else {
                mapper = new StyleMapper();
            }

            String[] outFileName = mapper.mapFileName(xmlFile);
            if (outFileName == null || outFileName.length == 0) {
                log("Skipping " + inFile + " it cannot get mapped to output.",
                    Project.MSG_VERBOSE);
                return;
            } else if (outFileName == null || outFileName.length > 1) {
View Full Code Here

Examples of org.apache.tools.ant.util.FileNameMapper.mapFileName()

        }
        String message = "Converting " + count + " file"
            + (count != 1 ? "s" : "") + " from ";
        log(message + srcDir + " to " + destDir);
        for (int i = 0; i < files.length; i++) {
            convert(files[i], m.mapFileName(files[i])[0]);
        }
    }

    /**
     * Convert a single file.
View Full Code Here

Examples of org.apache.tools.ant.util.FileNameMapper.mapFileName()

            if (mapper != null) {
                FileNameMapper impl = mapper.getImplementation();
                List ret = new ArrayList();
                for (int i = 0; i < elems.length; ++i) {
                    String[] mapped = impl.mapFileName(elems[i]);
                    for (int m = 0; mapped != null && m < mapped.length; ++m) {
                        ret.add(mapped[m]);
                    }
                }
                elems = (String[]) ret.toArray(new String[ret.size()]);
View Full Code Here

Examples of org.apache.tools.ant.util.FileNameMapper.mapFileName()

        }
        String message = "Converting " + count + " file"
            + (count != 1 ? "s" : "") + " from ";
        log(message + srcDir + " to " + destDir);
        for (int i = 0; i < files.length; i++){
            convert(files[i], m.mapFileName(files[i])[0]);
        }
    }

    /**
     * Convert a single file.
View Full Code Here

Examples of org.apache.tools.ant.util.FileNameMapper.mapFileName()

        }
        String message = "Converting " + count + " file"
            + (count != 1 ? "s" : "") + " from ";
        log(message + srcDir + " to " + destDir);
        for (int i = 0; i < files.length; i++) {
            convert(files[i], m.mapFileName(files[i])[0]);
        }
    }

    /**
     * Convert a single file.
View Full Code Here

Examples of org.apache.tools.ant.util.FileNameMapper.mapFileName()

        Properties properties = new Properties();
        for (Enumeration e = names.elements(); e.hasMoreElements();) {
            String name = (String) e.nextElement();
            String value = prj.getProperty(name);
            if (mapper != null) {
                String[] newname = mapper.mapFileName(name);
                if (newname != null) {
                    name = newname[0];
                }
            }
            properties.setProperty(name, value);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.