com.fasterxml.jackson.databind.type

## Class ClassStack

- java.lang.Object
- - com.fasterxml.jackson.databind.type.ClassStack

    public final class ClassStack
    extends Object

Simple helper class used to keep track of 'call stack' for classes being referenced (as well as unbound variables)

Since:
  2.7

### Field Summary

Fields
`protected Class<?>` `_current`
`protected ClassStack` `_parent`

### Constructor Summary

Constructors
Constructor and Description
`ClassStack(Class<?> rootType)`

### Method Summary

All Methods Instance Methods Concrete Methods
`void` `addSelfReference(ResolvedRecursiveType ref)` Method called to indicate that there is a self-reference from deeper down in stack pointing into type this stack frame represents.
`ClassStack` `child(Class<?> cls)`
`ClassStack` `find(Class<?> cls)`
`void` `resolveSelfReferences(JavaType resolved)` Method called when type that this stack frame represents is fully resolved, allowing self-references to be completed (if there are any)
`String` `toString()`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Field Detail

#### _parent

    protected final ClassStack _parent

#### _current

    protected final Class<?> _current

### Constructor Detail

#### ClassStack

    public ClassStack(Class<?> rootType)

### Method Detail

#### child

    public ClassStack child(Class<?> cls)

Returns:
  New stack frame, if addition is ok; null if not

#### addSelfReference

    public void addSelfReference(ResolvedRecursiveType ref)

Method called to indicate that there is a self-reference from deeper down in stack pointing into type this stack frame represents.

#### resolveSelfReferences

    public void resolveSelfReferences(JavaType resolved)

Method called when type that this stack frame represents is fully resolved, allowing self-references to be completed (if there are any)

#### find

    public ClassStack find(Class<?> cls)

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`