001 
002 /*
003  *  JScripter Standard 1.0 - To Script In Java
004  *  Copyright (C) 2008-2011  J.J.Liu<jianjunliu@126.com> <http://www.jscripter.org>
005  *  
006  *  This program is free software: you can redistribute it and/or modify
007  *  it under the terms of the GNU Affero General Public License as published by
008  *  the Free Software Foundation, either version 3 of the License, or
009  *  (at your option) any later version.
010  *  
011  *  This program is distributed in the hope that it will be useful,
012  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
013  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
014  *  GNU Affero General Public License for more details.
015  *  
016  *  You should have received a copy of the GNU Affero General Public License
017  *  along with this program.  If not, see <http://www.gnu.org/licenses/>.
018  */
019 
020 package js.user;
021 
022 import js.*;
023 import js.core.*;
024 
025 /**
026  * <p>An <b>opaque</b> class representing JavaScript client-side objects of the global 
027  * {@link JsClient#Navigator} class.</p>
028  * <p>An object of this class contains properties that describe the web browser in use. 
029  * You can use its properties to perform platform-specific customization. The name of 
030  * this object obviously refers to the Netscape Navigator browser, but all browsers that 
031  * implement JavaScript support this object as well. There is only a single instance of 
032  * {@link JsWindow#navigator} 
033  * property of any {@link JsWindow} object.</p>
034  * <p>Historically, the {@link JsNavigator} object has been used for "client sniffing" 
035  * to run different code depending on what browser was in use.</p>
036  *
037  * @author <a href="mailto:jianjunliu@126.com">J.J.Liu (Jianjun Liu)</a> at <a href="http://www.jscripter.org" target="_blank">http://www.jscripter.org</a>
038  * @see JsMimeType
039  * @see JsPlugin
040  *
041  * @javascript <b>Opaque</b> types can be resolved but no class objects for them can be
042  * generated into the target codes. Re-compilers must exit with error on the operations of
043  * accessing that kind of class objects.
044  * The <tt>checkcast</tt> operation to the class literal of this interface must be ignored
045  * and <tt>instanceof</tt> to it always <tt>true</tt>.
046  */
047 public class JsNavigator extends JsClient.Navigator.Prototype
048 {
049     /**
050      * <p>An <b>internal</b> class containing membership data for its enclosing
051      * opaque class.</p>
052      * <p>This class is only used inside of <b>opaque</b> or <b>internal</b> classes or
053      * class members.</p>
054      *
055      * @author <a href="mailto:jianjunliu@126.com">J.J.Liu (Jianjun Liu)</a> at <a href="http://www.jscripter.org" target="_blank">http://www.jscripter.org</a>
056      * 
057      * @javascript Re-compilers must report error on resolving an <b>internal</b> class.
058      */
059     protected static abstract class Members extends JsClient.Navigator.Prototype.Members
060     {
061         /**
062          * <p>An <b>internal</b> static field defining a member ID of the field name and
063          * used internally to define a member of the same name.</p>
064          * @since 1.0
065          * @see JsNavigator#appCodeName
066          * @see JsNavigator.Member#appCodeName
067          * @javascript Re-compilers must report error on accessing an <b>internal</b> field.
068          */
069         public final static Mid appCodeName   = id("appCodeName"  );
070         /**
071          * <p>An <b>internal</b> static field defining a member ID of the field name and
072          * used internally to define a member of the same name.</p>
073          * @since 1.0
074          * @see JsNavigator#appName
075          * @see JsNavigator.Member#appName
076          * @javascript Re-compilers must report error on accessing an <b>internal</b> field.
077          */
078         public final static Mid appName       = id("appName"      );
079         /**
080          * <p>An <b>internal</b> static field defining a member ID of the field name and
081          * used internally to define a member of the same name.</p>
082          * @since 1.0
083          * @see JsNavigator#appVersion
084          * @see JsNavigator.Member#appVersion
085          * @javascript Re-compilers must report error on accessing an <b>internal</b> field.
086          */
087         public final static Mid appVersion    = id("appVersion"   );
088         /**
089          * <p>An <b>internal</b> static field defining a member ID of the field name and
090          * used internally to define a member of the same name.</p>
091          * @since 1.0
092          * @see JsNavigator#cookieEnabled
093          * @see JsNavigator.Member#cookieEnabled
094          * @javascript Re-compilers must report error on accessing an <b>internal</b> field.
095          */
096         public final static Mid cookieEnabled = id("cookieEnabled");
097         /**
098          * <p>An <b>internal</b> static field defining a member ID of the field name and
099          * used internally to define a member of the same name.</p>
100          * @since 1.0
101          * @see JsNavigator#mimeTypes
102          * @see JsNavigator.Member#mimeTypes
103          * @javascript Re-compilers must report error on accessing an <b>internal</b> field.
104          */
105         public final static Mid mimeTypes     = id("mimeTypes"    );
106         /**
107          * <p>An <b>internal</b> static field defining a member ID of the field name and
108          * used internally to define a member of the same name.</p>
109          * @since 1.0
110          * @see JsNavigator#platform
111          * @see JsNavigator.Member#platform
112          * @javascript Re-compilers must report error on accessing an <b>internal</b> field.
113          */
114         public final static Mid platform      = id("platform"     );
115         /**
116          * <p>An <b>internal</b> static field defining a member ID of the field name and
117          * used internally to define a member of the same name.</p>
118          * @since 1.0
119          * @see JsNavigator#plugins
120          * @see JsNavigator.Member#plugins
121          * @javascript Re-compilers must report error on accessing an <b>internal</b> field.
122          */
123         public final static Mid plugins       = id("plugins"      );
124         /**
125          * <p>An <b>internal</b> static field defining a member ID of the field name and
126          * used internally to define a member of the same name.</p>
127          * @since 1.0
128          * @see JsNavigator#userAgent
129          * @see JsNavigator.Member#userAgent
130          * @javascript Re-compilers must report error on accessing an <b>internal</b> field.
131          */
132         public final static Mid userAgent     = id("userAgent"    );
133     }
134     /**
135      * <p>An <b>opaque</b> class representing members of its enclosing <b>opaque</b> type.</p>
136      * <p>Note that, this class is <b>opaque</b> but its constructors are all <b>internal</b>. 
137      * This class and the subclasses of this class are used to declare either <b>opaque</b> 
138      * <tt>public</tt> instance fields of the opaque type {@link js.Var.Member} or the 
139      * <b>opaque</b> <tt>public</tt> static fields of other <b>opaque</b> types while their 
140      * constructors are used to define the fields inside <b>opaque</b> classes. Under 
141      * either circumstance, the field names must be exactly same as the member names, as 
142      * the <b>opaque</b> fields of <b>opaque</b> types are resolved by re-compilers directly 
143      * based on the field names.</p>
144      *
145      * @author <a href="mailto:jianjunliu@126.com">J.J.Liu (Jianjun Liu)</a> at <a href="http://www.jscripter.org" target="_blank">http://www.jscripter.org</a>
146      * 
147      * @javascript <b>Opaque</b> types can be resolved but no class objects for them can be created
148      * in the target codes. Re-compilers must exit with error on operations accessing that kind 
149      * of class objects.
150      * Re-compilers must resolve an <b>opaque</b> instance field declared by this class in
151      * {@link js.Var.Member} or its subclasses to the JavaScript identifier: 
152      * <pre>q.m</pre>
153      * where <tt>m</tt> is the identifier of the field name and <tt>q</tt> is the identifier
154      * resolved from the instance of the enclosing member. Re-compilers must resolve an 
155      * <b>opaque</b> static field declared by this class in <b>opaque</b> types other than 
156      * {@link js.Var.Member} and its subclasses to the JavaScript identifier: 
157      * <pre>m</pre>
158      * where <tt>m</tt> is the identifier of the field name. And re-compilers must report
159      * error on the access to <b>opaque</b> fields declared by this class under any other 
160      * circumstances.
161      */
162     public static class Member extends JsClient.Navigator.Prototype.Member
163     {
164         /**
165          * <p>Internally constructs a member based on a qualifying member.</p>
166          * <p>This constructor is <b>internal</b> and only called inside of <b>opaque</b>
167          * or <b>internal</b> classes or class members.</p>
168          * <p>Note that, this constructor is <b>internal</b> but its declaring class is
169          * <b>opaque</b>. This constructor is used to define <b>opaque</b> instance fields 
170          * declared in the declaring class of this constructor itself or its subclasses. 
171          * Under this circumstance, the field names must be exactly same as the member 
172          * names, as the <b>opaque</b> instance fields of the <b>opaque</b> type 
173          * {@link js.Var.Member} or its subclasses are resolved by re-compilers directly
174          * to their names appending to the name resolved from the specified qualifying 
175          * member with a dot in between.</p>
176          * @param q A qualifying member
177          * @param mid The ID of the member to construct
178          * @since 1.0
179          * @javascript Re-compilers must report error on the invocation to an <b>internal</b> constructor.
180          */
181         public Member(JsObject.Member q, Mid mid) {
182             super(q, mid);
183         }
184         /**
185          * <p>Internally constructs a member without a qualifying member.</p>
186          * <p>This constructor is <b>internal</b> and only called inside of <b>opaque</b>
187          * or <b>internal</b> classes or class members.</p>
188          * <p>Note that, this constructor is <b>internal</b> but its declaring class is
189          * <b>opaque</b>. This constructor is used to define <b>opaque</b> static fields, 
190          * declared in <b>opaque</b> types other than the declaring class of this constructor 
191          * itself and its subclasses. Under this circumstance, the field names must be
192          * exactly same as the member names, as the <b>opaque</b> static fields of <b>opaque</b>
193          * types are generally resolved by re-compilers directly to identifiers of their names.</p>
194          * @param mid The ID of the member to construct
195          * @since 1.0
196          * @javascript Re-compilers must report error on the invocation to an <b>internal</b> constructor.
197          */
198         public Member(Mid mid) {
199             super(mid);
200         }
201         @Override
202         /**
203          * <p>Evaluates the property, represented by the current member instance, of the
204          * argument object.</p>
205          * @param o The argument object
206          * @return The value of the current member based on the object argument.
207          * @since 1.0
208          * @javascript Re-compilers must convert the instance invocation of this method into
209          * the JavaScript expression: 
210          * <pre>o.m</pre>
211          * where <tt>m</tt> is the identifier name resolved from the current member
212          * instance of the invocation.
213          */
214         public JsNavigator with(ObjectLike o) {
215             return new JsNavigator(super.with(o));
216         }
217         /**
218          * <p>Evaluates a property, represented by the current member instance, of the
219          * JavaScript global object, that is, evaluates the member to a global identifier.</p>
220          * @return The value of the current member based on the JavaScript global object.
221          * @since 1.0
222          * @javascript Re-compilers must convert the instance invocation of this method into
223          * the JavaScript expression: 
224          * <pre>m</pre>
225          * where <tt>m</tt> is the identifier name resolved from the current member
226          * instance of the invocation.
227          */
228         public JsNavigator with() {
229             return with(Js.win());
230         }
231         /**
232          * <p>An <b>opaque</b> instance field defining a sub-member that is named by the
233          * name of this field, qualified by the current member instance of the field, and 
234          * to access the property of the name on an object.</p>
235          * <p>The property, identified by this member, of a {@link JsNavigator} object 
236          * refers to a read-only string that specifies the code name of the browser. 
237          * In all browsers based on the Netscape code base (Netscape, Mozilla, Firefox), 
238          * this is "Mozilla". For compatibility, this property is "Mozilla" in Microsoft 
239          * browsers as well.</p> 
240          * @since 1.0
241          * @javascript Re-compilers must resolve the member of this instance field to the
242          * identifier of the field name appending to the identifier resolved from its 
243          * qualifying member with a dot in between.
244          */
245         public final Value.String.Member appCodeName = new Value.String.Member(this, Members.appCodeName);
246         /**
247          * <p>An <b>opaque</b> instance field defining a sub-member that is named by the
248          * name of this field, qualified by the current member instance of the field, and 
249          * to access the property of the name on an object.</p>
250          * <p>The property, identified by this member, of a {@link JsNavigator} object 
251          * refers to a read-only string that specifies the name of the browser. For 
252          * Netscape-based browsers, the value of the property is "Netscape". In IE, 
253          * the value of the property is "Microsoft Internet Explorer". Other browsers 
254          * may identify themselves correctly or spoof another browser for compatibility.</p> 
255          * @since 1.0
256          * @javascript Re-compilers must resolve the member of this instance field to the
257          * identifier of the field name appending to the identifier resolved from its 
258          * qualifying member with a dot in between.
259          */
260         public final Value.String.Member appName     = new Value.String.Member(this, Members.appName    );
261         /**
262          * <p>An <b>opaque</b> instance field defining a sub-member that is named by the
263          * name of this field, qualified by the current member instance of the field, and 
264          * to access the property of the name on an object.</p>
265          * <p>The property, identified by this member, of a {@link JsNavigator} object 
266          * refers to a read-only string that specifies version and platform information 
267          * for the browser. The first part of this string is a version number. Pass the 
268          * string to {@link Js#parseInt(Object)} to obtain only the major version number 
269          * or to {@link Js#parseFloat(Object)} to obtain the major and minor version 
270          * numbers as a floating-point value. The remainder of the string value of the 
271          * property provides other details about the browser version, including the 
272          * operating system it is running on. Unfortunately, however, the format of this 
273          * information varies widely from browser to browser.</p> 
274          * @since 1.0
275          * @javascript Re-compilers must resolve the member of this instance field to the
276          * identifier of the field name appending to the identifier resolved from its 
277          * qualifying member with a dot in between.
278          */
279         public final Value.String.Member appVersion  = new Value.String.Member(this, Members.appVersion );
280         /**
281          * <p>An <b>opaque</b> instance field defining a sub-member that is named by the
282          * name of this field, qualified by the current member instance of the field, and 
283          * to access the property of the name on an object.</p>
284          * <p>The property, identified by this member, of a {@link JsNavigator} object 
285          * refers to a read-only string that specifies the operating system and/or 
286          * hardware platform on which the browser is running. Although there is no 
287          * standard set of values for this property, some typical values are "Win32", 
288          * "MacPPC", and "Linux i586".</p> 
289          * @since 1.0
290          * @javascript Re-compilers must resolve the member of this instance field to the
291          * identifier of the field name appending to the identifier resolved from its 
292          * qualifying member with a dot in between.
293          */
294         public final Value.String.Member platform    = new Value.String.Member(this, Members.platform   );
295         /**
296          * <p>An <b>opaque</b> instance field defining a sub-member that is named by the
297          * name of this field, qualified by the current member instance of the field, and 
298          * to access the property of the name on an object.</p>
299          * <p>The property, identified by this member, of a {@link JsNavigator} object 
300          * refers to an array of {@link JsPlugin} objects, each of which represents one 
301          * plug-in that is installed in the browser. A {@link JsPlugin} object provides 
302          * information about the plug-in, including a list of MIME types it supports. 
303          * The array is defined by IE but is always empty because IE does not support 
304          * the {@link JsPlugin}.</p> 
305          * @since 1.0
306          * @javascript Re-compilers must resolve the member of this instance field to the
307          * identifier of the field name appending to the identifier resolved from its 
308          * qualifying member with a dot in between.
309          */
310         public final JsPlugin.Member plugins     = new JsPlugin.Member(this, Members.plugins);
311         /**
312          * <p>An <b>opaque</b> instance field defining a sub-member that is named by the
313          * name of this field, qualified by the current member instance of the field, and 
314          * to access the property of the name on an object.</p>
315          * <p>The property, identified by this member, of a {@link JsNavigator} object 
316          * refers to a read-only string that specifies the value the browser uses for 
317          * the user-agent header in HTTP requests. Typically, this is the value of 
318          * {@link #appCodeName} followed by a slash and the value of {@link #appVersion}.</p> 
319          * @since 1.0
320          * @javascript Re-compilers must resolve the member of this instance field to the
321          * identifier of the field name appending to the identifier resolved from its 
322          * qualifying member with a dot in between.
323          */
324         public final Value.String.Member userAgent   = new Value.String.Member(this, Members.userAgent  );
325 
326         /**
327          * <p>An <b>opaque</b> instance field defining a sub-member that is named by the
328          * name of this field, qualified by the current member instance of the field, and 
329          * to access the property of the name on an object.</p>
330          * <p>The property, identified by this member, of a {@link JsNavigator} object 
331          * refers to a read-only boolean value which is <tt>true</tt> if the browser 
332          * has cookies enabled and <tt>false</tt> if they are disabled.</p> 
333          * @since 1.0
334          * @javascript Re-compilers must resolve the member of this instance field to the
335          * identifier of the field name appending to the identifier resolved from its 
336          * qualifying member with a dot in between.
337          */
338         public final Value.Boolean.Member cookieEnabled = new Value.Boolean.Member(this, Members.cookieEnabled);
339         /**
340          * <p>An <b>opaque</b> instance field defining a sub-member that is named by the
341          * name of this field, qualified by the current member instance of the field, and 
342          * to access the property of the name on an object.</p>
343          * <p>The property, identified by this member, of a {@link JsNavigator} object 
344          * refers to an array of {@link JsMimeType} objects, each of which represents 
345          * one of the MIME types (e.g., "text/html" and "image/gif") supported by the 
346          * browser. This array may be indexed numerically or by the name of the MIME 
347          * type. The array is defined by IEr but is always empty because IE does not 
348          * support {@link JsMimeType}.</p> 
349          * @since 1.0
350          * @javascript Re-compilers must resolve the member of this instance field to the
351          * identifier of the field name appending to the identifier resolved from its 
352          * qualifying member with a dot in between.
353          */
354         public final JsArray.Member mimeTypes = new JsArray.Member(this, Members.mimeTypes);
355 
356     }
357 
358     /**
359      * <p>Casts an <b>opaque</b> object to the current <b>opaque</b> type by wrapping it
360      * with the wrapping constructor.</p>
361      * @param var The argument of an <b>opaque</b> object.
362      * @since 1.0
363      * @javascript Re-compilers must ignore the construction operation of this constructor,
364      * that is, replacing it with its only argument.
365      */
366     public JsNavigator(JsObject var) {
367         super(var);
368     }
369 
370     /**
371      * <p>An <b>opaque</b> static field defining a member that is named by the field name
372      * without a qualifying member and to access the property of the name on an object.</p>
373      * <p>The property, identified by this member, of a {@link JsNavigator} object 
374      * refers to a read-only string that specifies the code name of the browser. 
375      * In all browsers based on the Netscape code base (Netscape, Mozilla, Firefox), 
376      * this is "Mozilla". For compatibility, this property is "Mozilla" in Microsoft 
377      * browsers as well.</p> 
378      * @since 1.0
379      * @javascript Re-compilers must resolve the member of this static field to the
380      * identifier of the field name.
381      */
382     public static final Value.String.Member appCodeName = new Value.String.Member(Members.appCodeName);
383     /**
384      * <p>An <b>opaque</b> static field defining a member that is named by the field name
385      * without a qualifying member and to access the property of the name on an object.</p>
386      * <p>The property, identified by this member, of a {@link JsNavigator} object 
387      * refers to a read-only string that specifies the name of the browser. For 
388      * Netscape-based browsers, the value of the property is "Netscape". In IE, 
389      * the value of the property is "Microsoft Internet Explorer". Other browsers 
390      * may identify themselves correctly or spoof another browser for compatibility.</p> 
391      * @since 1.0
392      * @javascript Re-compilers must resolve the member of this static field to the
393      * identifier of the field name.
394      */
395     public static final Value.String.Member appName     = new Value.String.Member(Members.appName    );
396     /**
397      * <p>An <b>opaque</b> static field defining a member that is named by the field name
398      * without a qualifying member and to access the property of the name on an object.</p>
399      * <p>The property, identified by this member, of a {@link JsNavigator} object 
400      * refers to a read-only string that specifies version and platform information 
401      * for the browser. The first part of this string is a version number. Pass the 
402      * string to {@link Js#parseInt(Object)} to obtain only the major version number 
403      * or to {@link Js#parseFloat(Object)} to obtain the major and minor version 
404      * numbers as a floating-point value. The remainder of the string value of the 
405      * property provides other details about the browser version, including the 
406      * operating system it is running on. Unfortunately, however, the format of this 
407      * information varies widely from browser to browser.</p> 
408      * @since 1.0
409      * @javascript Re-compilers must resolve the member of this static field to the
410      * identifier of the field name.
411      */
412     public static final Value.String.Member appVersion  = new Value.String.Member(Members.appVersion );
413     /**
414      * <p>An <b>opaque</b> static field defining a member that is named by the field name
415      * without a qualifying member and to access the property of the name on an object.</p>
416      * <p>The property, identified by this member, of a {@link JsNavigator} object 
417      * refers to a read-only string that specifies the operating system and/or 
418      * hardware platform on which the browser is running. Although there is no 
419      * standard set of values for this property, some typical values are "Win32", 
420      * "MacPPC", and "Linux i586".</p> 
421      * @since 1.0
422      * @javascript Re-compilers must resolve the member of this static field to the
423      * identifier of the field name.
424      */
425     public static final Value.String.Member platform    = new Value.String.Member(Members.platform   );
426     /**
427      * <p>An <b>opaque</b> static field defining a member that is named by the field name
428      * without a qualifying member and to access the property of the name on an object.</p>
429      * <p>The property, identified by this member, of a {@link JsNavigator} object 
430      * refers to an array of {@link JsPlugin} objects, each of which represents one 
431      * plug-in that is installed in the browser. A {@link JsPlugin} object provides 
432      * information about the plug-in, including a list of MIME types it supports. 
433      * The array is defined by IE but is always empty because IE does not support 
434      * the {@link JsPlugin}.</p> 
435      * @since 1.0
436      * @javascript Re-compilers must resolve the member of this static field to the
437      * identifier of the field name.
438      */
439     public static final JsPlugin.Member plugins     = new JsPlugin.Member(Members.plugins);
440     /**
441      * <p>An <b>opaque</b> static field defining a member that is named by the field name
442      * without a qualifying member and to access the property of the name on an object.</p>
443      * <p>The property, identified by this member, of a {@link JsNavigator} object 
444      * refers to a read-only boolean value which is <tt>true</tt> if the browser 
445      * has cookies enabled and <tt>false</tt> if they are disabled.</p> 
446      * @since 1.0
447      * @javascript Re-compilers must resolve the member of this static field to the
448      * identifier of the field name.
449      */
450     public static final Value.String.Member userAgent   = new Value.String.Member(Members.userAgent  );
451 
452     /**
453      * <p>An <b>opaque</b> static field defining a member that is named by the field name
454      * without a qualifying member and to access the property of the name on an object.</p>
455      * <p>The property, identified by this member, of a {@link JsNavigator} object 
456      * refers to a read-only boolean value which is <tt>true</tt> if the browser 
457      * has cookies enabled and <tt>false</tt> if they are disabled.</p> 
458      * @since 1.0
459      * @javascript Re-compilers must resolve the member of this static field to the
460      * identifier of the field name.
461      */
462     public static final Value.Boolean.Member cookieEnabled = new Value.Boolean.Member(Members.cookieEnabled);
463     /**
464      * <p>An <b>opaque</b> static field defining a member that is named by the field name
465      * without a qualifying member and to access the property of the name on an object.</p>
466      * <p>The property, identified by this member, of a {@link JsNavigator} object 
467      * refers to an array of {@link JsMimeType} objects, each of which represents 
468      * one of the MIME types (e.g., "text/html" and "image/gif") supported by the 
469      * browser. This array may be indexed numerically or by the name of the MIME 
470      * type. The array is defined by IEr but is always empty because IE does not 
471      * support {@link JsMimeType}.</p> 
472      * @since 1.0
473      * @javascript Re-compilers must resolve the member of this static field to the
474      * identifier of the field name.
475      */
476     public static final JsArray.Member mimeTypes = new JsArray.Member(Members.mimeTypes);
477 
478     @Override
479     /**
480      * <p>Returns the primitive value associated with the current instance, if there is one.
481      * This invocation simply returns the instance itself for the current instance is an 
482      * object and there is no primitive value for it.</p>
483      * @return The current object itself.
484      * @since 1.0
485      * @javascript Re-compilers must convert the instance invocation of this method directly
486      * into a JavaScript invocation on its current object instance without changing the 
487      * method name, but expanding variable arguments, if any, into comma-separated values. 
488      */
489     public JsNavigator valueOf() {
490         return new JsNavigator((JsObject)var().valueOf());
491     }
492 
493     /**
494      * <p>Tests whether Java is supported and enabled in the current browser and can 
495      * therefore display applets.</p>
496      * @return <tt>true</tt> if Java is supported by and enabled on the current browser; 
497      * <tt>false</tt> otherwise.
498      * @since 1.0
499      * @javascript Re-compilers must convert the instance invocation of this method directly
500      * into a JavaScript invocation on its current object instance without changing the 
501      * method name, but expanding variable arguments, if any, into comma-separated values. 
502      */
503     public final Boolean javaEnabled() {
504         return call(javaEnabled);
505     }
506 }