From d2be6574a7ab5db672279ad7f952ed6b8eb66e16 Mon Sep 17 00:00:00 2001
From: Matthew Jason Benson <fileset/>
caught.
We want to use the Java API. Because we donīt want always typing the package signature +
We want to use the Java API. Because we don't want always typing the package signature
we do an import. Rhino knows two different methods for import statements: one for packages
and one for a single class. By default only the java packages are available, so
java.lang.System can be directly imported with importClass/importPackage
.
-For other packages you have to prefix the full classified name with Package.
-For example antīs FileUtil class can be imported with
-importClass(Package.org.apache.tools.ant.util.FileUtils)
+For other packages you have to prefix the full classified name with Packages.
+For example Ant's FileUtils class can be imported with
+importClass(Packages.org.apache.tools.ant.util.FileUtils)
The <script>
task populates the Project instance under
the name project, so we can use that reference. Another way is to use its given name