Funzione AcxStreamAddConnections (acxstreams.h)
La funzione AcxStreamAddConnections aggiunge connessioni esplicite a un nuovo flusso ACX durante EvtAcxCircuitCreateStream
Sintassi
NTSTATUS AcxStreamAddConnections(
ACXSTREAM Stream,
PACX_CONNECTION Connections,
ULONG ConnectionsCount
);
Parametri
Stream
Oggetto flusso ACXSTREAM esistente. Per altre informazioni, vedere ACX - Riepilogo degli oggetti ACX.
Connections
Struttura ACX_CONNECTION che contiene informazioni sulle connessioni da aggiungere al flusso.
ConnectionsCount
Numero di connessioni presenti nel flusso. Si tratta di un conteggio basato su 1.
Valore restituito
Restituisce STATUS_SUCCESS
se la chiamata ha avuto esito positivo. In caso contrario, restituisce un codice di errore appropriato. Per altre informazioni, vedere Uso di valori NTSTATUS.
Osservazioni
Se il driver non chiama AcxStreamAddConnections durante EvtAcxCircuitCreateStream, il framework ACX assegnerà automaticamente le connessioni tra tutti gli oggetti ACXELEMENT aggiunti a ACXSTREAM.
Esempio
Di seguito è riportato un esempio di utilizzo.
//
// Explicitly connect the elements of the stream. Note that the driver doesn't
// need to perform this step when elements are connected in the same order
// as they were added to the stream.
//
const int numElements = 2;
const int numConnections = numElements + 1;
ACXSTREAM Stream;
ACX_CONNECTION connections[numConnections];
ACX_CONNECTION_INIT(&connections[0], Stream, Elements[ElementCount - 2]);
ACX_CONNECTION_INIT(&connections[1], Elements[ElementCount - 2], Elements[ElementCount - 1]);
ACX_CONNECTION_INIT(&connections[2], Elements[ElementCount - 1], Stream);
//
// Add the connections linking stream to elements.
//
status = AcxStreamAddConnections(Stream, connections, SIZEOF_ARRAY(connections));
Requisiti ACX
versione minima di ACX: 1.0
Per altre informazioni sulle versioni di ACX, vedere panoramica della versione ACX.
Fabbisogno
Requisito | Valore |
---|---|
intestazione | acxstreams.h |
IRQL | PASSIVE_LEVEL |