ArrayedStack |
An arrayed stack. This is called a LIFO structure (Last In, First Out).
| ArrayedStack | An arrayed stack. |
| Functions and Properties | |
| ArrayedStack | Initializes a stack to match the given size. |
| maxSize | The stack’s maximum capacity. |
| peek | Indicates the top item. |
| push | Pushes data onto the stack. |
| pop | Pops data off the stack. |
| getAt | Reads an item at a given index. |
| setAt | Writes an item at a given index. |
| contains | @inheritDoc |
| clear | @inheritDoc |
| getIterator | @inheritDoc |
| size | @inheritDoc |
| isEmpty | @inheritDoc |
| toArray | @inheritDoc |
| toString | Prints out a string representing the current object. |
| dump | Prints out all elements (for debug/demo purposes). |
Initializes a stack to match the given size.
public function ArrayedStack( size: int )
The stack’s maximum capacity.
public function get maxSize():int
Indicates the top item.
public function peek():*
Pushes data onto the stack.
public function push( obj: * ):Boolean
Pops data off the stack.
public function pop():*
Reads an item at a given index.
public function getAt( i: int ):*
Writes an item at a given index.
public function setAt( i: int, obj: * ):void
@inheritDoc
public function contains( obj: * ):Boolean
@inheritDoc
public function clear():void
@inheritDoc
public function getIterator():Iterator
@inheritDoc
public function get size():int
@inheritDoc
public function isEmpty():Boolean
@inheritDoc
public function toArray():Array
Prints out a string representing the current object.
public function toString():String
Prints out all elements (for debug/demo purposes).
public function dump():String