home *** CD-ROM | disk | FTP | other *** search
- !!Script
- // Copyright ⌐ 1997-2000 - Modelworks Software
-
- /**
- @Tool: listDestinationFiles~displays the list of files
- to be built.
- @EndTool:
- @Summary: listDestinationFiles~displays the list of files to be built
- */
-
- function DoCommand()
- {
- saveAll();
-
- var project = getCurrentProject();
-
- if (project)
- {
- var output = getOutput();
- output.clear();
- output.writeLine("Destination file list");
- var packageList = project.getPackageList();
- var position = packageList.getHeadPosition();
-
- if (!position.valid)
- {
- output.writeLine("\nNo packages are included in this project");
- }
-
- var count = 0;
- while (position && position.valid)
- {
- count += ListPackageInfo(packageList.getNext(position));
- }
-
- output.writeLine("Number of class files: " + count);
- output.writeLine("\nReport completed");
- }
- else
- {
- alert("A project must be open before you get project info");
- }
- }
-
- function ListPackageInfo(p)
- {
- var output = getOutput();
-
- if (p.name.length > 0)
- {
- output.writeLine("------ Package " + p.name);
- }
- else
- {
- output.writeLine("------ Package " + "Untitled");
- }
-
- var outOfDateFileList = p.getDestinationFileList();
- var position = outOfDateFileList.getHeadPosition();
- while (position.valid)
- {
- output.writeLine(outOfDateFileList.getNext(position).path);
- }
- return outOfDateFileList.count;
- }
-
-
- !!/Script
-