-- Autogenerated by MSIL2Ada v. 2
-- By: Martin C. Carlisle
--     Department of Computer Science
--     US Air Force Academy
--     carlislem@acm.org
pragma Extensions_Allowed(On);
with MSSyst.Object;
with MSIL_Types;
use MSIL_Types;
with type MSSyst.IDisposable.Ref is access;
with type MSSyst.IAsyncResult.Ref is access;
with type MSSyst.AsyncCallback.Ref is access;
with type MSSyst.Object.Ref is access;
with type MSSyst.Net.EndPoint.Ref is access;
with MSSyst.Net.Sockets.SocketFlags;
with type MSSyst.Net.EndPoint.Ref_addrof is access;
with MSSyst.Net.Sockets.AddressFamily;
with type MSSyst.IntPtr.Valuetype is tagged;
with MSSyst.Net.Sockets.ProtocolType;
with MSSyst.Net.Sockets.SocketType;
with MSSyst.Net.Sockets.SocketOptionLevel;
with MSSyst.Net.Sockets.SocketOptionName;
with type MSSyst.Type_k.Ref is access;
with MSSyst.Net.Sockets.SelectMode;
with type MSSyst.Collections.IList.Ref is access;
with MSSyst.Net.Sockets.SocketShutdown;
with type MSSyst.String.Ref is access;
with MSSyst.Object;
package MSSyst.Net.Sockets.Socket is
   type Typ;
   type Ref is access all Typ'Class;
   type Ref_addrof is access all Ref;
   type Ref_Arr is array(Natural range <>) of Ref;
   type Ref_Array is access all Ref_Arr;
   type Ref_Array_addrof is access all Ref_Array;
   type Typ(
         I_IDisposable : MSSyst.IDisposable.Ref
      ) is new MSSyst.Object.Typ with record
      null;
   end record;
   function new_Socket(
      This : Ref := null;
      addressFamily : MSSyst.Net.Sockets.AddressFamily.Valuetype;
      socketType : MSSyst.Net.Sockets.SocketType.Valuetype;
      protocolType : MSSyst.Net.Sockets.ProtocolType.Valuetype) return Ref;
   function Accept_k(
      This : access Typ) return MSSyst.Net.Sockets.Socket.Ref;
   function BeginAccept(
      This : access Typ;
      callback : MSSyst.AsyncCallback.Ref;
      state : MSSyst.Object.Ref) return MSSyst.IAsyncResult.Ref;
   function BeginConnect(
      This : access Typ;
      remoteEP : MSSyst.Net.EndPoint.Ref;
      callback : MSSyst.AsyncCallback.Ref;
      state : MSSyst.Object.Ref) return MSSyst.IAsyncResult.Ref;
   function BeginReceive(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      offset : Integer;
      size : Integer;
      socketFlags : MSSyst.Net.Sockets.SocketFlags.Valuetype;
      callback : MSSyst.AsyncCallback.Ref;
      state : MSSyst.Object.Ref) return MSSyst.IAsyncResult.Ref;
   function BeginReceiveFrom(
      This : access Typ;
      readBuffer : MSIL_Types.unsigned_int8_Arr;
      index : Integer;
      size : Integer;
      flags : MSSyst.Net.Sockets.SocketFlags.Valuetype;
      EP : MSSyst.Net.EndPoint.Ref_addrof;
      callback : MSSyst.AsyncCallback.Ref;
      state : MSSyst.Object.Ref) return MSSyst.IAsyncResult.Ref;
   function BeginSend(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      offset : Integer;
      size : Integer;
      socketFlags : MSSyst.Net.Sockets.SocketFlags.Valuetype;
      callback : MSSyst.AsyncCallback.Ref;
      state : MSSyst.Object.Ref) return MSSyst.IAsyncResult.Ref;
   function BeginSendTo(
      This : access Typ;
      writeBuffer : MSIL_Types.unsigned_int8_Arr;
      index : Integer;
      size : Integer;
      flags : MSSyst.Net.Sockets.SocketFlags.Valuetype;
      remoteEP : MSSyst.Net.EndPoint.Ref;
      callback : MSSyst.AsyncCallback.Ref;
      state : MSSyst.Object.Ref) return MSSyst.IAsyncResult.Ref;
   procedure Bind(
      This : access Typ;
      localEP : MSSyst.Net.EndPoint.Ref);
   procedure Close(
      This : access Typ);
   procedure Connect(
      This : access Typ;
      remoteEP : MSSyst.Net.EndPoint.Ref);
   function EndAccept(
      This : access Typ;
      asyncResult : MSSyst.IAsyncResult.Ref) return MSSyst.Net.Sockets.Socket.Ref;
   procedure EndConnect(
      This : access Typ;
      asyncResult : MSSyst.IAsyncResult.Ref);
   function EndReceive(
      This : access Typ;
      asyncResult : MSSyst.IAsyncResult.Ref) return Integer;
   function EndReceiveFrom(
      This : access Typ;
      asyncResult : MSSyst.IAsyncResult.Ref;
      endPoint : MSSyst.Net.EndPoint.Ref_addrof) return Integer;
   function EndSend(
      This : access Typ;
      asyncResult : MSSyst.IAsyncResult.Ref) return Integer;
   function EndSendTo(
      This : access Typ;
      asyncResult : MSSyst.IAsyncResult.Ref) return Integer;
   function get_AddressFamily(
      This : access Typ) return MSSyst.Net.Sockets.AddressFamily.Valuetype;
   function get_Available(
      This : access Typ) return Integer;
   function get_Blocking(
      This : access Typ) return Standard.Boolean;
   function get_Connected(
      This : access Typ) return Standard.Boolean;
   function get_Handle(
      This : access Typ) return MSSyst.IntPtr.Valuetype;
   function get_LocalEndPoint(
      This : access Typ) return MSSyst.Net.EndPoint.Ref;
   function get_ProtocolType(
      This : access Typ) return MSSyst.Net.Sockets.ProtocolType.Valuetype;
   function get_RemoteEndPoint(
      This : access Typ) return MSSyst.Net.EndPoint.Ref;
   function get_SocketType(
      This : access Typ) return MSSyst.Net.Sockets.SocketType.Valuetype;
   function GetSocketOption(
      This : access Typ;
      optionLevel : MSSyst.Net.Sockets.SocketOptionLevel.Valuetype;
      optionName : MSSyst.Net.Sockets.SocketOptionName.Valuetype) return MSSyst.Object.Ref;
   procedure GetSocketOption(
      This : access Typ;
      optionLevel : MSSyst.Net.Sockets.SocketOptionLevel.Valuetype;
      optionName : MSSyst.Net.Sockets.SocketOptionName.Valuetype;
      optionValue : MSIL_Types.unsigned_int8_Arr);
   function GetSocketOption(
      This : access Typ;
      optionLevel : MSSyst.Net.Sockets.SocketOptionLevel.Valuetype;
      optionName : MSSyst.Net.Sockets.SocketOptionName.Valuetype;
      optionLength : Integer) return MSIL_Types.unsigned_int8_Array;
   function IOControl(
      This : access Typ;
      ioControlCode : Integer;
      optionInValue : MSIL_Types.unsigned_int8_Arr;
      optionOutValue : MSIL_Types.unsigned_int8_Arr) return Integer;
   procedure Listen(
      This : access Typ;
      backlog : Integer);
   function Poll(
      This : access Typ;
      microSeconds : Integer;
      mode : MSSyst.Net.Sockets.SelectMode.Valuetype) return Standard.Boolean;
   function Receive(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      flags : MSSyst.Net.Sockets.SocketFlags.Valuetype) return Integer;
   function Receive(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr) return Integer;
   function Receive(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      size : Integer;
      socketFlags : MSSyst.Net.Sockets.SocketFlags.Valuetype) return Integer;
   function Receive(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      offset : Integer;
      size : Integer;
      socketFlags : MSSyst.Net.Sockets.SocketFlags.Valuetype) return Integer;
   function ReceiveFrom(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      socketFlags : MSSyst.Net.Sockets.SocketFlags.Valuetype;
      remoteEP : MSSyst.Net.EndPoint.Ref_addrof) return Integer;
   function ReceiveFrom(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      remoteEP : MSSyst.Net.EndPoint.Ref_addrof) return Integer;
   function ReceiveFrom(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      size : Integer;
      socketFlags : MSSyst.Net.Sockets.SocketFlags.Valuetype;
      remoteEP : MSSyst.Net.EndPoint.Ref_addrof) return Integer;
   function ReceiveFrom(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      index : Integer;
      request : Integer;
      flags : MSSyst.Net.Sockets.SocketFlags.Valuetype;
      EP : MSSyst.Net.EndPoint.Ref_addrof) return Integer;
   procedure Select_k(
      checkRead : MSSyst.Collections.IList.Ref;
      checkWrite : MSSyst.Collections.IList.Ref;
      checkError : MSSyst.Collections.IList.Ref;
      microSeconds : Integer);
   function Send(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      offset : Integer;
      size : Integer;
      socketFlags : MSSyst.Net.Sockets.SocketFlags.Valuetype) return Integer;
   function Send(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr) return Integer;
   function Send(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      flags : MSSyst.Net.Sockets.SocketFlags.Valuetype) return Integer;
   function Send(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      size : Integer;
      socketFlags : MSSyst.Net.Sockets.SocketFlags.Valuetype) return Integer;
   function SendTo(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      flags : MSSyst.Net.Sockets.SocketFlags.Valuetype;
      remoteEP : MSSyst.Net.EndPoint.Ref) return Integer;
   function SendTo(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      remoteEP : MSSyst.Net.EndPoint.Ref) return Integer;
   function SendTo(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      index : Integer;
      size : Integer;
      flags : MSSyst.Net.Sockets.SocketFlags.Valuetype;
      remoteEP : MSSyst.Net.EndPoint.Ref) return Integer;
   function SendTo(
      This : access Typ;
      buffer : MSIL_Types.unsigned_int8_Arr;
      size : Integer;
      socketFlags : MSSyst.Net.Sockets.SocketFlags.Valuetype;
      remoteEP : MSSyst.Net.EndPoint.Ref) return Integer;
   procedure set_Blocking(
      This : access Typ;
      value : Standard.Boolean);
   procedure SetSocketOption(
      This : access Typ;
      optionLevel : MSSyst.Net.Sockets.SocketOptionLevel.Valuetype;
      optionName : MSSyst.Net.Sockets.SocketOptionName.Valuetype;
      optionValue : MSSyst.Object.Ref);
   procedure SetSocketOption(
      This : access Typ;
      optionLevel : MSSyst.Net.Sockets.SocketOptionLevel.Valuetype;
      optionName : MSSyst.Net.Sockets.SocketOptionName.Valuetype;
      optionValue : MSIL_Types.unsigned_int8_Arr);
   procedure SetSocketOption(
      This : access Typ;
      optionLevel : MSSyst.Net.Sockets.SocketOptionLevel.Valuetype;
      optionName : MSSyst.Net.Sockets.SocketOptionName.Valuetype;
      optionValue : Integer);
   procedure Shutdown(
      This : access Typ;
      how : MSSyst.Net.Sockets.SocketShutdown.Valuetype);
private
   pragma Convention(MSIL,Typ);
   pragma MSIL_Constructor(new_Socket);
   pragma Import(MSIL,Accept_k,"Accept");
   pragma Import(MSIL,BeginAccept,"BeginAccept");
   pragma Import(MSIL,BeginConnect,"BeginConnect");
   pragma Import(MSIL,BeginReceive,"BeginReceive");
   pragma Import(MSIL,BeginReceiveFrom,"BeginReceiveFrom");
   pragma Import(MSIL,BeginSend,"BeginSend");
   pragma Import(MSIL,BeginSendTo,"BeginSendTo");
   pragma Import(MSIL,Bind,"Bind");
   pragma Import(MSIL,Close,"Close");
   pragma Import(MSIL,Connect,"Connect");
   pragma Import(MSIL,EndAccept,"EndAccept");
   pragma Import(MSIL,EndConnect,"EndConnect");
   pragma Import(MSIL,EndReceive,"EndReceive");
   pragma Import(MSIL,EndReceiveFrom,"EndReceiveFrom");
   pragma Import(MSIL,EndSend,"EndSend");
   pragma Import(MSIL,EndSendTo,"EndSendTo");
   pragma Import(MSIL,get_AddressFamily,"get_AddressFamily");
   pragma Import(MSIL,get_Available,"get_Available");
   pragma Import(MSIL,get_Blocking,"get_Blocking");
   pragma Import(MSIL,get_Connected,"get_Connected");
   pragma Import(MSIL,get_Handle,"get_Handle");
   pragma Import(MSIL,get_LocalEndPoint,"get_LocalEndPoint");
   pragma Import(MSIL,get_ProtocolType,"get_ProtocolType");
   pragma Import(MSIL,get_RemoteEndPoint,"get_RemoteEndPoint");
   pragma Import(MSIL,get_SocketType,"get_SocketType");
   pragma Import(MSIL,GetSocketOption,"GetSocketOption");
   pragma Import(MSIL,IOControl,"IOControl");
   pragma Import(MSIL,Listen,"Listen");
   pragma Import(MSIL,Poll,"Poll");
   pragma Import(MSIL,Receive,"Receive");
   pragma Import(MSIL,ReceiveFrom,"ReceiveFrom");
   pragma Import(MSIL,Select_k,"Select");
   pragma Import(MSIL,Send,"Send");
   pragma Import(MSIL,SendTo,"SendTo");
   pragma Import(MSIL,set_Blocking,"set_Blocking");
   pragma Import(MSIL,SetSocketOption,"SetSocketOption");
   pragma Import(MSIL,Shutdown,"Shutdown");
end MSSyst.Net.Sockets.Socket;
pragma Extensions_Allowed(Off);
pragma Import(MSIL,MSSyst.Net.Sockets.Socket,
   ".ver 1:0:5000:0 .publickeytoken=( 96 9d b8 05 3d 33 22 ac )",
   "[System]System.Net.Sockets.Socket");
