# Interface: com.pnfsoftware.jeb.core.units.code.java.IJavaCatchBlock

Interface to represent a catch\-block used by [IJavaTry](IJavaTry) AST elements.

## Method: addType
- parameter: `type`, type: `com.pnfsoftware.jeb.core.units.code.java.IJavaType`

Description: Add a caught type.
parameter: type: caught type

## Method: addTypes
- parameter: `types`, type: `java.util.Collection<com.pnfsoftware.jeb.core.units.code.java.IJavaType>`

Description: Add caught types.
parameter: types: caught types

## Method: canCatch
- parameter: `typestring`, type: `java.lang.String`
- return type: `boolean`

Description: Determine whether this block can catch a type.
parameter: typestring: type signature
return: true if the provided type can be caught

## Method: getAdditionalCaughtTypes
- return type: `java.util.List<com.pnfsoftware.jeb.core.units.code.java.IJavaType>`

Description: For multi\-catch \(java \>= 7\), retrieve additional caught types.
return: a list, possibly null

## Method: getBlock
- return type: `com.pnfsoftware.jeb.core.units.code.java.IJavaBlock`

Description: Retrieve the catch body block.
return: catch body block

## Method: getCaughtTypes
- return type: `java.util.List<com.pnfsoftware.jeb.core.units.code.java.IJavaType>`

Description: Retrieve a read\-only copy of the list of caught types.
return: caught types

## Method: getDefinition
- return type: `com.pnfsoftware.jeb.core.units.code.java.IJavaDefinition`

Description: Retrieve the catch variable definition.
return: catch variable definition

## Method: getIdentifier
- return type: `com.pnfsoftware.jeb.core.units.code.java.IJavaIdentifier`

Description: Retrieve the catch variable identifier.
return: catch variable identifier

## Method: getType
- return type: `com.pnfsoftware.jeb.core.units.code.java.IJavaType`

Description: Retrieve the primary caught type.
return: never null

## Method: setBlock
- parameter: `block`, type: `com.pnfsoftware.jeb.core.units.code.java.IJavaBlock`

Description: Set the catch body block.
parameter: block: catch body block

## Method: setDefifinition
- parameter: `def`, type: `com.pnfsoftware.jeb.core.units.code.java.IJavaDefinition`

Description: Set the catch variable definition.
parameter: def: catch variable definition

## Method: setIdentifier
- parameter: `ident`, type: `com.pnfsoftware.jeb.core.units.code.java.IJavaIdentifier`

Description: Set the catch variable identifier.
parameter: ident: catch variable identifier

## Method: setType
- parameter: `type`, type: `com.pnfsoftware.jeb.core.units.code.java.IJavaType`

Description: Set the primary caught type.
parameter: type: caught type

