TWiFiAdapter

From Ultibo.org
Jump to: navigation, search

Return to Unit WiFi


Description


To be documented

Class definitions



TWiFiAdapter = class(TNetworkAdapter)

constructor Create(AManager:TAdapterManager; ADevice:PNetworkDevice; const AName:String);  
private
FDefaultAddress:THardwareAddress;  
FHardwareAddress:THardwareAddress;  
FBroadcastAddress:THardwareAddress;  
FMulticastAddresses:TMulticastAddresses;  
 
function CheckReceiveFrame(APacket:PNetworkPacket; AStatus:PIEEE80211RXStatus):Boolean;  
 
function ReceiveHandler(APacket:PNetworkPacket; AStatus:PIEEE80211RXStatus):Boolean;  
 
function ScanReceiver(APacket:PNetworkPacket; AStatus:PIEEE80211RXStatus):Boolean;  
function DataReceiver(APacket:PNetworkPacket; AStatus:PIEEE80211RXStatus):Boolean;  
protected
procedure SetStatus(AStatus:Integer); override;  
public
function AddTransport(APacketType,AFrameType:Word; const APacketName:String; APacketHandler:TAdapterPacketHandler):THandle; override;  
function RemoveTransport(AHandle:THandle; APacketType:Word):Boolean; override;  
 
function GetMTU(AHandle:THandle):Word; override;  
 
function SendPacket(AHandle:THandle; ADest:Pointer; APacket:PPacketFragment; ASize:Integer):Boolean; override;  
 
function ClearStatistics(AHandle:THandle):Boolean; override;  
function GetStatistics(AHandle:THandle):TAdapterStatistics; override;  
 
function GetDefaultAddress(AHandle:THandle):THardwareAddress; override;  
function GetHardwareAddress(AHandle:THandle):THardwareAddress; override;  
function SetHardwareAddress(AHandle:THandle; const AAddress:THardwareAddress):Boolean; override;  
function GetBroadcastAddress(AHandle:THandle):THardwareAddress; override;  
function GetMulticastAddresses(AHandle:THandle):TMulticastAddresses; override;  
 
function AddMulticastAddress(AHandle:THandle; const AAddress:THardwareAddress):Boolean; override;  
function RemoveMulticastAddress(AHandle:THandle; const AAddress:THardwareAddress):Boolean; override;  
 
function StartAdapter:Boolean; override;  
function StopAdapter:Boolean; override;  
function ProcessAdapter:Boolean; override;  
function CompareDefault(AHandle:THandle; const AAddress:THardwareAddress):Boolean; override;  
function CompareHardware(AHandle:THandle; const AAddress:THardwareAddress):Boolean; override;  
function CompareBroadcast(AHandle:THandle; const AAddress:THardwareAddress):Boolean; override;  
function CompareMulticast(AHandle:THandle; const AAddress:THardwareAddress):Boolean; override;  


Function declarations



constructor TWiFiAdapter.Create(AManager:TAdapterManager; ADevice:PNetworkDevice; const AName:String);
Description: To be documented
Note None documented


function TWiFiAdapter.CheckReceiveFrame(APacket:PNetworkPacket; AStatus:PIEEE80211RXStatus):Boolean;
Description: Check if a received frame is valid to continue processing or should be dropped
Note should_drop_frame


function TWiFiAdapter.ReceiveHandler(APacket:PNetworkPacket; AStatus:PIEEE80211RXStatus):Boolean;
Description: To be documented
Note __ieee80211_rx_handle_packet / ieee80211_prepare_and_rx_handle


function TWiFiAdapter.ScanReceiver(APacket:PNetworkPacket; AStatus:PIEEE80211RXStatus):Boolean;
Description: To be documented
Note ieee80211_scan_rx


function TWiFiAdapter.DataReceiver(APacket:PNetworkPacket; AStatus:PIEEE80211RXStatus):Boolean;
Description: To be documented
Note ieee80211_prepare_and_rx_handle


procedure TWiFiAdapter.SetStatus(AStatus:Integer); 
Description: To be documented
Note None documented


function TWiFiAdapter.AddTransport(APacketType,AFrameType:Word; const APacketName:String; APacketHandler:TAdapterPacketHandler):THandle;
Description: To be documented
Note None documented


function TWiFiAdapter.RemoveTransport(AHandle:THandle; APacketType:Word):Boolean;
Description: To be documented
Note None documented


function TWiFiAdapter.GetMTU(AHandle:THandle):Word;
Description: To be documented
Note None documented


function TWiFiAdapter.SendPacket(AHandle:THandle; ADest:Pointer; APacket:PPacketFragment; ASize:Integer):Boolean;
Description: To be documented
Note None documented


function TWiFiAdapter.ClearStatistics(AHandle:THandle):Boolean;
Description: To be documented
Note None documented


function TWiFiAdapter.GetStatistics(AHandle:THandle):TAdapterStatistics;
Description: To be documented
Note None documented


function TWiFiAdapter.GetDefaultAddress(AHandle:THandle):THardwareAddress;
Description: To be documented
Note None documented


function TWiFiAdapter.GetHardwareAddress(AHandle:THandle):THardwareAddress;
Description: To be documented
Note None documented


function TWiFiAdapter.SetHardwareAddress(AHandle:THandle; const AAddress:THardwareAddress):Boolean;
Description: To be documented
Note None documented


function TWiFiAdapter.GetBroadcastAddress(AHandle:THandle):THardwareAddress;
Description: To be documented
Note None documented


function TWiFiAdapter.GetMulticastAddresses(AHandle:THandle):TMulticastAddresses;
Description: To be documented
Note None documented


function TWiFiAdapter.AddMulticastAddress(AHandle:THandle; const AAddress:THardwareAddress):Boolean;
Description: To be documented
Note None documented


function TWiFiAdapter.RemoveMulticastAddress(AHandle:THandle; const AAddress:THardwareAddress):Boolean;
Description: To be documented
Note None documented


function TWiFiAdapter.StartAdapter:Boolean;
Description: To be documented
Note None documented


function TWiFiAdapter.StopAdapter:Boolean;
Description: To be documented
Note None documented


function TWiFiAdapter.ProcessAdapter:Boolean;
Description: To be documented
Note ieee80211_rx


function TWiFiAdapter.CompareDefault(AHandle:THandle; const AAddress:THardwareAddress):Boolean;
Description: To be documented
Note None documented


function TWiFiAdapter.CompareHardware(AHandle:THandle; const AAddress:THardwareAddress):Boolean;
Description: To be documented
Note None documented


function TWiFiAdapter.CompareBroadcast(AHandle:THandle; const AAddress:THardwareAddress):Boolean;
Description: To be documented
Note None documented


function TWiFiAdapter.CompareMulticast(AHandle:THandle; const AAddress:THardwareAddress):Boolean;
Description: To be documented
Note None documented


Return to Unit Reference