/*++
Copyright (c) 1997 Microsoft Corporation
Module Name:
sample\ip\saminfo.h
Abstract:
Data structures exposed by the Sample Routing Protocol. These
include the Global and Interface Info and the structures needed
to query the MIB.
Revision History:
--*/
#ifndef __IPRTSAMP_H__
#define __IPRTSAMP_H__
typedef struct _NT_IF
{
LIST_ENTRY leNtIfLink;
DWORD dwNtIndex;
DWORD fNtState;
ULONG ulNumBindings;
PWCHAR pwszIfName;
DWORD dwType;
LIST_ENTRY leInternalIfHead;
}NT_IF, *PNT_IF;
#define NT_STATE_ENABLED_BIT 0x00000001
#define NT_STATE_BOUND_BIT 0x00000002
#define NT_STATE_ENABLED_BOUND (NT_STATE_ENABLED_BIT|NT_STATE_BOUND_BIT)
#define ClearNtState(X) \
((X)->fNtState |= 0x00000000)
#define SetNtEnabled(X) \
((X)->fNtState |= NT_STATE_ENABLED_BIT)
#define ClearNtEnabled(X) \
((X)->fNtState &= ~NT_STATE_ENABLED_BIT)
#define IsNtEnabled(X) \
((X)->fNtState | NT_STATE_ENABLED_BIT)
#define SetNtBound(X) \
((X)->fNtState |= NT_STATE_BOUND_BIT)
#define ClearNtBound(X) \
((X)->fNtState &= ~NT_STATE_BOUND_BIT)
#define IsNtBound(X) \
((X)->fNtState | NT_STATE_BOUND_BIT)
#define IsNtEnabledAndBound(X) \
(((X)->fNtState & NT_STATE_ENABLED_BOUND) == NT_STATE_ENABLED_BOUND)
typedef struct _INTRNL_IF
{
LIST_ENTRY leInternalIfLink;
DWORD dwAddress;
DWORD dwMask;
BOOL bEnabled;
DWORD dwState;
SOCKET sSocket;
}INTRNL_IF, *PINTRNL_IF;
typedef struct _MGR_MSG
{
LIST_ENTRY leMsgLink;
ROUTING_PROTOCOL_EVENTS rreEvent;
MESSAGE mResult;
}MGR_MSG, *PMGR_MSG;
#define MAX_PACKET_SIZE 512
typedef struct _RECEIVE_BUFFER
{
WSABUF wbBuffer;
BYTE rgbyData[MAX_PACKET_SIZE];
}RECEIVE_BUFFER, *PRECEIVE_BUFFER;
#endif