public abstract class AbstractShortStack extends AbstractStack<Short> implements ShortStack
To create a type-specific stack, you need both object methods and primitive-type methods. However, if you inherit from this class you need just one (anyone).
Modifier and Type | Method and Description |
---|---|
Short |
peek(int i)
Delegates to the corresponding type-specific method.
|
short |
peekShort(int i)
Delegates to the corresponding generic method.
|
Short |
pop()
Delegates to the corresponding type-specific method.
|
short |
popShort()
Delegates to the corresponding generic method.
|
void |
push(short k)
Delegates to the corresponding generic method.
|
void |
push(Short o)
Delegates to the corresponding type-specific method.
|
Short |
top()
Delegates to the corresponding type-specific method.
|
short |
topShort()
Delegates to the corresponding generic method.
|
public void push(Short o)
public Short pop()
public Short top()
public Short peek(int i)
public void push(short k)
push
in interface ShortStack
Stack.push(Object)
public short popShort()
popShort
in interface ShortStack
Stack.pop()
public short topShort()
topShort
in interface ShortStack
Stack.top()
public short peekShort(int i)
peekShort
in interface ShortStack
Stack.peek(int)