XmlSerializationReader.ShrinkArray(Array, Int32, Type, Boolean) Método

Definição

Garante que uma determinada matriz ou uma cópia não seja maior que um tamanho especificado.

Esta API dá suporte à infraestrutura do produto e não deve ser usada diretamente do seu código.

protected:
 Array ^ ShrinkArray(Array ^ a, int length, Type ^ elementType, bool isNullable);
[System.Diagnostics.CodeAnalysis.RequiresDynamicCode("XML serializer relies on dynamic code generation which is not available with Ahead of Time compilation")]
protected Array? ShrinkArray(Array? a, int length, Type elementType, bool isNullable);
protected Array? ShrinkArray(Array? a, int length, Type elementType, bool isNullable);
protected Array ShrinkArray(Array a, int length, Type elementType, bool isNullable);
[<System.Diagnostics.CodeAnalysis.RequiresDynamicCode("XML serializer relies on dynamic code generation which is not available with Ahead of Time compilation")>]
member this.ShrinkArray : Array * int * Type * bool -> Array
member this.ShrinkArray : Array * int * Type * bool -> Array
Protected Function ShrinkArray (a As Array, length As Integer, elementType As Type, isNullable As Boolean) As Array

Parâmetros

a
Array

A matriz que está sendo verificada.

length
Int32

O comprimento máximo da matriz.

elementType
Type

Os Type elementos da matriz.

isNullable
Boolean

true se null for a matriz, se presente para a matriz de entrada, poderá ser retornada; caso contrário, uma matriz nova e menor.

Retornos

O existente Array, se já for pequeno o suficiente; caso contrário, uma matriz nova e menor que contém os elementos da matriz original até o tamanho de length.

Atributos

Comentários

Os membros protegidos do XmlSerializationReader destinam-se apenas ao uso por classes derivadas que são usadas internamente dentro da infraestrutura de serialização do .NET Framework XML.

Aplica-se a