lispptr.java

来自「计算机代数系统」· Java 代码 · 共 43 行

JAVA
43
字号
package net.sf.yacas;/** class LispPtr. This class is a smart pointer type class to Lisp *  objects that can be inserted into linked lists. They do the actual *  reference counting, and consequent destruction of the object if *  nothing points to it. LispPtr is used in LispObject as a pointer *  to the next object, and in diverse parts of the built-in internal *  functions to hold temporary values. */class LispPtr {    public LispPtr()	{		iNext = null;	}    public LispPtr(LispPtr aOther)	{		iNext = aOther.iNext;	}    public LispPtr(LispObject aOther)	{		iNext = aOther;	}    public void Set(LispObject aNext)	{		iNext = aNext;	}    public LispObject Get()	{		return iNext;	}    public void GoNext()	{		iNext = iNext.iNext.iNext;	}    void DoSet(LispObject aNext)	{		iNext = aNext;	}    LispObject iNext;};

⌨️ 快捷键说明

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