C# Class Mosa.DeviceSystem.NetworkDevicePacketBuffer

Exibir arquivo Open project: tgiphil/MOSA-Project Class Usage Examples

Protected Properties

Property Type Description
countReceivePackets uint
countTransmitPackets uint
discardedReceivePackets uint
discardedTransmitPackets uint
maxReceiveQueue uint
maxTransmitQueue uint
networkDevice INetworkDevice
receiveLock SpinLock
receiveQueue LinkedList
transmitLock SpinLock
transmitQueue LinkedList

Public Methods

Method Description
GetPacketFromDevice ( ) : byte[]

Get packet from device.

NetworkDevicePacketBuffer ( INetworkDevice networkDevice ) : System.Collections.Generic

Initializes a new instance of the NetworkDevicePacketBuffer class.

NetworkDevicePacketBuffer ( INetworkDevice networkDevice, uint maxTransmitQueue, uint maxReceiveQueue ) : System.Collections.Generic

Initializes a new instance of the NetworkDevicePacketBuffer class.

Pulse ( ) : void

Pulse

QueuePacketForStack ( byte data ) : bool

Queues the packet for stack.

SendPacketToDevice ( byte data ) : bool

Sends the packet to device.

Protected Methods

Method Description
SendPackets ( ) : void

Sends the packets.

Method Details

GetPacketFromDevice() public method

Get packet from device.
public GetPacketFromDevice ( ) : byte[]
return byte[]

NetworkDevicePacketBuffer() public method

Initializes a new instance of the NetworkDevicePacketBuffer class.
public NetworkDevicePacketBuffer ( INetworkDevice networkDevice ) : System.Collections.Generic
networkDevice INetworkDevice The network device.
return System.Collections.Generic

NetworkDevicePacketBuffer() public method

Initializes a new instance of the NetworkDevicePacketBuffer class.
public NetworkDevicePacketBuffer ( INetworkDevice networkDevice, uint maxTransmitQueue, uint maxReceiveQueue ) : System.Collections.Generic
networkDevice INetworkDevice The network device.
maxTransmitQueue uint The max transmit queue.
maxReceiveQueue uint The max receive queue.
return System.Collections.Generic

Pulse() public method

Pulse
public Pulse ( ) : void
return void

QueuePacketForStack() public method

Queues the packet for stack.
public QueuePacketForStack ( byte data ) : bool
data byte The data.
return bool

SendPacketToDevice() public method

Sends the packet to device.
public SendPacketToDevice ( byte data ) : bool
data byte The data.
return bool

SendPackets() protected method

Sends the packets.
protected SendPackets ( ) : void
return void

Property Details

countReceivePackets protected_oe property

protected uint countReceivePackets
return uint

countTransmitPackets protected_oe property

protected uint countTransmitPackets
return uint

discardedReceivePackets protected_oe property

protected uint discardedReceivePackets
return uint

discardedTransmitPackets protected_oe property

protected uint discardedTransmitPackets
return uint

maxReceiveQueue protected_oe property

protected uint maxReceiveQueue
return uint

maxTransmitQueue protected_oe property

protected uint maxTransmitQueue
return uint

networkDevice protected_oe property

Network Device Packet Buffer
This class setups a transmit and receive between buffers between the Network Device and the TCP stack. Network devices will not have to setup their own in-memory buffers when hardware buffers become full.
protected INetworkDevice networkDevice
return INetworkDevice

receiveLock protected_oe property

protected SpinLock receiveLock
return SpinLock

receiveQueue protected_oe property

protected LinkedList receiveQueue
return LinkedList

transmitLock protected_oe property

protected SpinLock transmitLock
return SpinLock

transmitQueue protected_oe property

protected LinkedList transmitQueue
return LinkedList