NetSamples.Common.Net
Class Datagram

Class that represents a UDP datagram.

Field Summary
int available
byte[] data
System.Net.EndPoint endpoint

Constructor Summary
Datagram()
         Default constructor.
Datagram(byte[] data, System.Net.IPEndPoint endpoint)
         Constructor.

Property Summary
int Available
         The bytes available for this datagram. Always 0 unless the datagram is created as the result of a successful receive.
byte[] Data
         The data.
System.Net.IPEndPoint EndPoint
         The source / destination endpoint. When sending a datagram this property contains the target endpoint. When receiving a datagram, this property contains the source endpoint.

Methods inherited from class System.Object
Equals, Finalize, GetHashCode, GetType, MemberwiseClone, ToString


Field Detail

available

internal int available


data

internal byte[] data


endpoint

internal System.Net.EndPoint endpoint

Constructor Detail

Datagram

public Datagram()

Default constructor.


Datagram

public Datagram(byte[] data,
                System.Net.IPEndPoint endpoint)

Constructor.

Property Detail

Available

public int Available

The bytes available for this datagram. Always 0 unless the datagram is created as the result of a successful receive.


Data

public byte[] Data

The data.


EndPoint

public System.Net.IPEndPoint EndPoint

The source / destination endpoint. When sending a datagram this property contains the target endpoint. When receiving a datagram, this property contains the source endpoint.