# Interface: com.pnfsoftware.jeb.core.units.code.IVisitResults
- Type Parameter: T extends `java.lang.Object`


Visit results interface for statement trees.

## Static Final Field: FLAG_RECORD_PARENTS
Type: `int`

Constant value: `1`
Description: Record the parents in a stack, made available when visiting a child. Parents recording is  seldom used, and disabled by default.

## Static Final Field: FLAG_SKIP_ASSIGN_DST
Type: `int`

Constant value: `2`
Description: Skip written \(defined\) elements. Note: the name of this flag is misleading, implementations  may skip more than simply the destination of assignments.

## Abstract Method: getValue
- return type: `int`

Description: Get the visit value.
return: visit value

## Abstract Method: interrupt
- parameter: `success`, type: `boolean`

Description: Notify the visitor that the visit of the tree should be stopped.
parameter: success: the result of the visit

## Abstract Method: interrupt
- parameter: `success`, type: `boolean`
- parameter: `forcedValue`, type: `int`

Description: Notify the visitor that the visit of the tree should be stopped.
parameter: success: visit result
parameter: forcedValue: optional return value, can be retrieved via [#getValue()](#getValue())

## Abstract Method: isInterruptedVisit
- return type: `boolean`

Description: Determine whether the visit was interrupted.
return: true if the visit was interrupted

## Abstract Method: isVisitedSuccessfully
- return type: `boolean`

Description: Determine whether the visit completed successfully.
return: true if the visit was successful

## Abstract Method: parent
- parameter: `index`, type: `int`
- return type: `T`

Description: This convenience method returns the i'th ancestor \(i=0 being the immediate parent\) of the  element. On error, the method returns null \(it never throws\).
parameter: index: parent index, negative indices are allowed \(\-1 means the highest ancestor\)
return: the requested parent or null

## Abstract Method: parentsIterator
- return type: `java.util.Iterator<T>`

Description: Optional iterator containing the parents; non\-null only if [#FLAG_RECORD_PARENTS](#FLAG_RECORD_PARENTS) was  used when creating the object. The first element provided by the iterator is the parent of  the currently visited element; the last element is the deepest ancestor.
return: parent iterator

## Abstract Method: setReplacedNode
- parameter: `newNode`, type: `T`

Description: Notify the visitor that the current node was replaced by the  [process](INodeVisitor#process(Object, Object, IVisitResults)) method.  

  Note: usage of this method is not mandatory in a DFS post\-order traversal.
parameter: newNode: the non\-null new node

## Abstract Method: setValue
- parameter: `value`, type: `int`

Description: Set the visit value.
parameter: value: visit value

## Abstract Method: setVisitResult
- parameter: `success`, type: `boolean`

Description: Saves the visit result \(do not stop the visitor: use [#interrupt(boolean)](#interrupt(boolean)) to stop the  process\)
parameter: success: visit result

## Abstract Method: skipChildren

Description: Used in DFS pre\-order to notify the visitor that the children of the currently visited node  should be skipped; the visitor will then proceed with the next cousin.  

  Note: this method is useless in DFS post\-order since children of a node are always processed  before their parent.

