⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 setnamespace.bsh

📁 用java 编写的源码开放的文本编辑器。有很多有用的特性
💻 BSH
字号:
/**	Set the namespace (context) of the current scope.	<p/>The following example illustrates swapping the current namespace.<p/><pre>fooState = object(); barState = object(); print(this.namespace);setNameSpace(fooState.namespace);print(this.namespace);a=5;setNameSpace(barState.namespace);print(this.namespace);a=6;setNameSpace(fooState.namespace);print(this.namespace);print(a);  // 5setNameSpace(barState.namespace);print(this.namespace);print(a); // 6</pre><p/>You could use this to creats the effect of a static namespace for amethod by explicitly setting the namespace upon entry.<p/>*/bsh.help.setNameSpace =	"usage: setNameSpace( bsh.NameSpace )";setNameSpace( ns ) {	// Set the namespace at depth one (our caller) to the specified namespace.	this.callstack.set( 1, ns );}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -