# Class: com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.COutputSink

This output sink is the recipient for the generation of a C\-like Abstract Syntax Tree \(AST\). The sink also contains configuration elements that will guide and determine how certain AST elements are to be generated. A sink receives the output for a class, a field, or a method element. 

 Generating an AST yields a special type of elements, called items, that a UI client may want to track to achieve higher level functions such as syntax coloration.

## Constructor: COutputSink
- parameter: `baseAnchorId`, type: `long`


## Constructor: COutputSink
- parameter: `baseAnchorId`, type: `long`
- parameter: `doc`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.CDocument`
- parameter: `decomp`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.INativeDecompilerUnit<?>`


## Method: appendKeyword
- parameter: `keyword`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.CKeyword`


## Method: astDepth
- return type: `int`


## Method: astPeekSafe
- parameter: `n`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICElement`


## Method: astPop
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICElement`


## Method: astPush
- parameter: `elt`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICElement`


## Method: getCurrentContainingClass
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICClass`


## Method: getCurrentContainingMethod
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICMethod`


## Method: getCurrentMethodIndex
- return type: `int`

Description: Get the method index of the method being generated
return: <0 if cannot be determined or invalid

## Method: getDecompilerUnit
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.INativeDecompilerUnit<?>`

Description: May be null

## Method: getDocument
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.CDocument`

Description: May be null

## Method: getDynamicContentManager
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.IDynamicContentManager`


## Method: getHideCasts
- return type: `boolean`


## Method: getHideTLNS
- return type: `boolean`


## Method: getMergeAdjacentDefinitions
- return type: `boolean`


## Method: getSourceCustomizer
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ISourceCustomizer`


## Method: getSpaceOutCompounds
- return type: `boolean`


## Method: getTopLevelClass
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICClass`


## Method: omitTypeForNextDefinitionPrinting
- return type: `boolean`


## Method: popContainingClass
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICClass`


## Method: popContainingMethod
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICMethod`


## Method: pushContainingClass
- parameter: `c`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICClass`


## Method: pushContainingMethod
- parameter: `m`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.ICMethod`


## Method: renderComment
- parameter: `coord`, type: `com.pnfsoftware.jeb.core.output.code.coordinates.ICodeCoordinates`
- parameter: `what`, type: `int`
- parameter: `appendEOL`, type: `boolean`


## Method: renderInlineComment
- parameter: `coord`, type: `com.pnfsoftware.jeb.core.output.code.coordinates.ICodeCoordinates`
- parameter: `appendEOL`, type: `boolean`


## Method: renderPreComment
- parameter: `coord`, type: `com.pnfsoftware.jeb.core.output.code.coordinates.ICodeCoordinates`

Description: note: EOL always appended

## Method: setCurrentMethodIndex
- parameter: `index`, type: `int`
- return type: `int`

Description: Set the method index of the method being generated
parameter: index: the current method index
return: the previous index

## Method: setDynamicContentManager
- parameter: `dcm`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.IDynamicContentManager`


## Method: setHideCasts
- parameter: `override`, type: `java.lang.Boolean`


## Method: setHideTLNS
- parameter: `override`, type: `java.lang.Boolean`


## Method: setMergeAdjacentDefinitions
- parameter: `override`, type: `java.lang.Boolean`


## Method: setOmitTypeForNextDefinitionPrinting
- parameter: `omitTypeForNextDefinitionPrinting`, type: `boolean`

Description: One shot deactivation of types printing in definition \(i.e. when set to true, it only works for the next printing\)

## Method: setSourceCustomizer
- parameter: `sourceCustomizer`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ISourceCustomizer`


## Method: setSpaceOutCompounds
- parameter: `override`, type: `java.lang.Boolean`


## Method: validate


