Packages
A reference to a JavaPackage object that represents the top node of the java.* package hierarchy.
A reference to a JavaPackage object that represents the top node of the netscape.* package hierarchy.
A reference to a JavaPackage object that represents the top node of the sun.* package hierarchy.
The Packages property is a "global" variable in JavaScript. It is a read-only reference to a JavaPackage object, and is defined as a property of all Window objects. Because the Packages property is the same for all Window objects, you can always refer to it simply as Packages, rather than explicitly accessing it through a particular Window object.
A JavaPackage object in JavaScript is an object that contains references to other JavaPackage objects and to JavaClass objects. Each JavaPackage object represents a node in the tree of package names. The Packages property refers to a JavaPackage object that is the root of this package name hierarchy.
The Packages JavaPackage object contains three properties--java, sun, and netscape--all of which refer to other JavaPackage objects representing the java.*, sun.*, and netscape.* Java packages.
The Window object also contains "global" properties named java, netscape, and sun, all of which are synonyms for the properties of the Packages object. So instead of writing Packages.java.lang.Math, for example, you can just write java.lang.Math.
file: /Techref/language/JAVA/SCRIPT/definitive/refp_289.htm, 6KB, , updated: 2019/10/14 15:00, local time: 2024/12/19 05:12,
3.137.165.119:LOG IN
|
©2024 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions? <A HREF="http://massmind.org/techref/language/JAVA/SCRIPT/definitive/refp_289.htm"> [Chapter 21] Reference: Packages</A> |
Did you find what you needed? |
Welcome to massmind.org! |
Welcome to massmind.org! |
.