Documentation ¶
Overview ¶
All you need to work with stackgo stacks
For an example usage visit http://github.com/alediaferia/stackgo
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Stack ¶
type Stack struct {
// contains filtered or unexported fields
}
func NewStack ¶
func NewStack() *Stack
NewStack Creates a new Stack object with an underlying default block allocation size. The current default allocation size is one page. If you want to use a different block size use
NewStackWithCapacity()
func NewStackWithCapacity ¶
NewStackWithCapacity makes it easy to specify a custom block size for inner slice backing the stack
func (*Stack) Pop ¶
func (s *Stack) Pop() (elem interface{})
Pop pops the top element from the stack If the stack is empty it returns nil
Click to show internal directories.
Click to hide internal directories.