Create Linked List in AS3

允我心安 提交于 2019-12-04 16:00:52

You can use or take as an exmaple as3Commons linked list implementation. They provide very beautiful implementation with very good abstraction layer.

If you have access to the mx package, you could use mx.utils.LinkedList.

To construct the LinkedList you could repeatedly push or unshift items onto it.

var input:Array = getInput();
var myList:LinkedList = new LinkedList();
for each (var o:Object in input) {
    myList.push(o);
}
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!