Funzione WdfCommonBufferGetLength (wdfcommonbuffer.h)

[Si applica solo a KMDF]

Il metodo WdfCommonBufferGetLength restituisce la lunghezza di un buffer comune specificato.

Sintassi

size_t WdfCommonBufferGetLength(
  [in] WDFCOMMONBUFFER CommonBuffer
);

Parametri

[in] CommonBuffer

Handle a un oggetto buffer comune ottenuto da una chiamata precedente a WdfCommonBufferCreate.

Valore restituito

WdfCommonBufferGetLength restituisce la lunghezza, in byte, del buffer associato al buffer comune specificato dal parametro CommonBuffer .

Un controllo di bug si verifica se il driver fornisce un handle di oggetti non valido.

Commenti

Per altre informazioni sui buffer comuni, vedere Uso di buffer comuni

Esempio

Nell'esempio di codice seguente viene ottenuta la lunghezza di un buffer comune specificato.

size_t bufferLength;

bufferLength = WdfCommonBufferGetLength(DevExt->CommonBuffer); 

Requisiti

Requisito Valore
Piattaforma di destinazione Universale
Versione KMDF minima 1.0
Intestazione wdfcommonbuffer.h (include WdfCommonBuffer.h)
Libreria Wdf01000.sys (vedere Framework Library Versioning).
IRQL <= DISPATCH_LEVEL
Regole di conformità DDI DriverCreate(kmdf), KmdfIrql(kmdf), KmdfIrql2(kmdf), KmdfIrqlExplicit(kmdf)

Vedi anche

WdfCommonBufferCreate