PageRenderTime 41ms CodeModel.GetById 17ms RepoModel.GetById 0ms app.codeStats 0ms

/jEdit/tags/jedit-4-1-pre5/bsh/commands/setStrictJava.bsh

#
Unknown | 20 lines | 16 code | 4 blank | 0 comment | 0 complexity | cbed5be8a45ffc04c89553a631f1addd MD5 | raw file
Possible License(s): BSD-3-Clause, AGPL-1.0, Apache-2.0, LGPL-2.0, LGPL-3.0, GPL-2.0, CC-BY-SA-3.0, LGPL-2.1, GPL-3.0, MPL-2.0-no-copyleft-exception, IPL-1.0
  1. /**
  2. When strict Java mode is enabled BeanShell will:
  3. <p>
  4. <ol>
  5. <li>Require typed variable declarations, method arguments and return types.
  6. <li>Modify the scoping of variables to look for the variable
  7. declaration first in the parent namespace, as in a java method inside
  8. a java class. e.g. if you can write a method called incrementFoo() that
  9. will do the expected thing without referring to "super.foo".
  10. </ul>
  11. */
  12. void setStrictJava( boolean val )
  13. {
  14. import bsh.Interpreter;
  15. Interpreter.strictJava = val;
  16. }