Package org.apache.bcel.util
Class ClassStack
- java.lang.Object
-
- org.apache.bcel.util.ClassStack
-
public class ClassStack extends java.lang.Object
Utility class implementing a (typesafe) stack of JavaClass objects.- See Also:
Stack
-
-
Constructor Summary
Constructors Constructor Description ClassStack()Constructs a new ClassStack.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanempty()Checks if the stack is empty.JavaClasspop()Pops a JavaClass from the stack.voidpush(JavaClass clazz)Pushes a JavaClass onto the stack.JavaClasstop()Gets the top JavaClass from the stack without removing it.
-
-
-
Constructor Detail
-
ClassStack
public ClassStack()
Constructs a new ClassStack.
-
-
Method Detail
-
empty
public boolean empty()
Checks if the stack is empty.- Returns:
- true if the stack is empty.
-
pop
public JavaClass pop()
Pops a JavaClass from the stack.- Returns:
- The JavaClass from the top of the stack.
-
push
public void push(JavaClass clazz)
Pushes a JavaClass onto the stack.- Parameters:
clazz- The JavaClass to push.
-
-