public abstract class AbstractFloatStack extends AbstractStack<java.lang.Float> implements FloatStack
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 |
---|---|
java.lang.Float |
peek(int i)
Delegates to the corresponding type-specific method.
|
float |
peekFloat(int i)
Delegates to the corresponding generic method.
|
java.lang.Float |
pop()
Delegates to the corresponding type-specific method.
|
float |
popFloat()
Delegates to the corresponding generic method.
|
void |
push(float k)
Delegates to the corresponding generic method.
|
void |
push(java.lang.Float o)
Delegates to the corresponding type-specific method.
|
java.lang.Float |
top()
Delegates to the corresponding type-specific method.
|
float |
topFloat()
Delegates to the corresponding generic method.
|
public void push(java.lang.Float o)
public java.lang.Float pop()
public java.lang.Float top()
top
in interface Stack<java.lang.Float>
top
in class AbstractStack<java.lang.Float>
public java.lang.Float peek(int i)
peek
in interface Stack<java.lang.Float>
peek
in class AbstractStack<java.lang.Float>
i
- an index from the stop of the stack (0 represents the top).i
-th element on the stack.public void push(float k)
push
in interface FloatStack
Stack.push(Object)
public float popFloat()
popFloat
in interface FloatStack
Stack.pop()
public float topFloat()
topFloat
in interface FloatStack
Stack.top()
public float peekFloat(int i)
peekFloat
in interface FloatStack
Stack.peek(int)