ControlFlowBuilder.AddCatchRegion(LabelHandle, LabelHandle, LabelHandle, LabelHandle, EntityHandle) Método

Definição

Adiciona a região catch.Adds catch region.

public:
 void AddCatchRegion(System::Reflection::Metadata::Ecma335::LabelHandle tryStart, System::Reflection::Metadata::Ecma335::LabelHandle tryEnd, System::Reflection::Metadata::Ecma335::LabelHandle handlerStart, System::Reflection::Metadata::Ecma335::LabelHandle handlerEnd, System::Reflection::Metadata::EntityHandle catchType);
public void AddCatchRegion (System.Reflection.Metadata.Ecma335.LabelHandle tryStart, System.Reflection.Metadata.Ecma335.LabelHandle tryEnd, System.Reflection.Metadata.Ecma335.LabelHandle handlerStart, System.Reflection.Metadata.Ecma335.LabelHandle handlerEnd, System.Reflection.Metadata.EntityHandle catchType);
member this.AddCatchRegion : System.Reflection.Metadata.Ecma335.LabelHandle * System.Reflection.Metadata.Ecma335.LabelHandle * System.Reflection.Metadata.Ecma335.LabelHandle * System.Reflection.Metadata.Ecma335.LabelHandle * System.Reflection.Metadata.EntityHandle -> unit
Public Sub AddCatchRegion (tryStart As LabelHandle, tryEnd As LabelHandle, handlerStart As LabelHandle, handlerEnd As LabelHandle, catchType As EntityHandle)

Parâmetros

tryStart
LabelHandle

Rótulo que marca a primeira instrução do bloco try.Label marking the first instruction of the try block.

tryEnd
LabelHandle

Rótulo que marca a instrução imediatamente após o bloco try.Label marking the instruction immediately following the try block.

handlerStart
LabelHandle

Rótulo que marca a primeira instrução do manipulador.Label marking the first instruction of the handler.

handlerEnd
LabelHandle

Rótulo que marca a instrução imediatamente após o manipulador.Label marking the instruction immediately following the handler.

catchType
EntityHandle

O tipo de exceção a ser detectado: TypeDefinitionHandle, TypeReferenceHandle ou TypeSpecificationHandle.The type of exception to be caught: TypeDefinitionHandle, TypeReferenceHandle or TypeSpecificationHandle.

Exceções

Um rótulo não foi definido por um codificador de instruções ao qual este construtor está associado.A label was not defined by an instruction encoder this builder is associated with.

- ou --or-

catchType não é um identificador de tipo válido.catchType is not a valid type handle.

Um rótulo tem valor padrão.A label has default value.

Aplica-se a