Unsafe.BitCast<TFrom,TTo>(TFrom) Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Réinterpréte la valeur donnée de type TFrom en tant que valeur de type TTo.
public:
generic <typename TFrom, typename TTo>
where TFrom : value class where TTo : value class static TTo BitCast(TFrom source);
public static TTo BitCast<TFrom,TTo> (TFrom source) where TFrom : struct where TTo : struct;
static member BitCast : 'From -> 'o (requires 'From : struct and 'o : struct)
Public Shared Function BitCast(Of TFrom As Structure, TTo As Structure) (source As TFrom) As TTo
Paramètres de type
- TFrom
- TTo
Paramètres
- source
- TFrom
Retours
Valeur de type TTo.
Exceptions
La taille de TFrom et TTo ne sont pas identiques.