⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 rmaengin.pas

📁 Delphi源码REAlRMSDK.rar
💻 PAS
📖 第 1 页 / 共 3 页
字号:

type
  IRMAUDPResponse = interface (IUnknown)
  ['{00000107-0901-11d1-8B06-00A024406D59}']

    function ReadDone(status: PN_RESULT; pBuffer: IRMABuffer; ulAddr: ULONG32; nPort: UINT16): HRESULT; stdcall;

  end;
  {$EXTERNALSYM IRMAUDPResponse}

(****************************************************************************
 *
 *  Interface:
 *
 *	IRMAUDPSocket
 *
 *  Purpose:
 *
 *	Provides the user with an asynchronous UDP networking interface.
 *
 *  IID_IRMAUDPSocket:
 *
 *	{00000108-0901-11d1-8B06-00A024406D59}
 *
 *)

const
  IID_IRMAUDPSocket: TGUID = '{00000108-0901-11d1-8B06-00A024406D59}';
  {$EXTERNALSYM IID_IRMAUDPSocket}

type
  IRMAUDPSocket = interface (IUnknown)
  ['{00000108-0901-11d1-8B06-00A024406D59}']

    function Init(ulAddr: ULONG32; nPort: UINT16; pUDPResponse: IRMAUDPResponse): HRESULT; stdcall;

    function Bind(ulLocalAddr: UINT32; nPort: UINT16): HRESULT; stdcall;

    function Read(Size: UINT16): HRESULT; stdcall;

    function Write(pBuffer: IRMABuffer): HRESULT; stdcall;

    function WriteTo(ulAddr: ULONG32; nPort: UINT16; pBuffer: IRMABuffer): HRESULT; stdcall;

    function GetLocalPort(var port: UINT16): HRESULT; stdcall;

    function JoinMulticastGroup(ulMulticastAddr: ULONG32; ulInterfaceAddr: ULONG32): HRESULT; stdcall;

    function LeaveMulticastGroup(ulMulticastAddr, ulInterfaceAddr: ULONG32): HRESULT; stdcall;

  end;
  {$EXTERNALSYM IRMAUDPSocket}

(****************************************************************************
 *
 *  Interface:
 *
 *	IRMAResolverResponse
 * 
 *  Purpose:
 * 
 *	This is the response interface for the asynchronous DNS hostname
 *	resolver.
 * 
 *  IID_IRMAResolverResponse:
 * 
 *	{0000010A-0901-11d1-8B06-00A024406D59}
 * 
 *)

const
  IID_IRMAResolverResponse: TGUID = '{0000010A-0901-11d1-8B06-00A024406D59}';
  {$EXTERNALSYM IID_IRMAResolverResponse}

type
  IRMAResolverResponse = interface (IUnknown)
  ['{0000010A-0901-11d1-8B06-00A024406D59}']

    function GetHostByNameDone(status: PN_RESULT; ulAddr: ULONG32): HRESULT; stdcall;

  end;
  {$EXTERNALSYM IRMAResolverResponse}

(****************************************************************************
 *
 *  Interface:
 *
 *	IRMAResolver
 * 
 *  Purpose:
 * 
 *	This interface allows you to asynchronously resolve hostnames.
 * 
 *  IID_IRMAResolver:
 * 
 *	{00000109-0901-11d1-8B06-00A024406D59}
 *
 *)

const
  IID_IRMAResolver: TGUID = '{00000109-0901-11d1-8B06-00A024406D59}';
  {$EXTERNALSYM IID_IRMAResolver}

type
  IRMAResolver = interface (IUnknown)
  ['{00000109-0901-11d1-8B06-00A024406D59}']

    function Init(pResponse: IRMAResolverResponse): HRESULT; stdcall;

    function GetHostByName(pHostName: PChar): HRESULT; stdcall;

  end;
  {$EXTERNALSYM IRMAResolver}

(****************************************************************************
 *
 *  Interface:
 *
 *	IRMANetworkServices
 *
 *  Purpose:
 *
 *	This is a factory interface for the various types of networking
 *	interfaces described above.
 *
 *  IID_IRMANetworkServices:
 *
 *	{00000106-0901-11d1-8B06-00A024406D59}
 *
 *)

const
  IID_IRMANetworkServices: TGUID = '{00000106-0901-11d1-8B06-00A024406D59}';
  {$EXTERNALSYM IID_IRMANetworkServices}

type
  IRMANetworkServices = interface (IUnknown)
  ['{00000106-0901-11d1-8B06-00A024406D59}']

    (************************************************************************
     *	Method:
     *	    IRMANetworkServices::CreateTCPSocket
     *	Purpose:
     *	    Create a new TCP socket.
     *)

    function CreateTCPSocket(out ppTCPSocket: IRMATCPSocket): HRESULT; stdcall;

    (************************************************************************
     *	Method:
     *	    IRMANetworkServices::CreateUDPSocket
     *	Purpose:
     *	    Create a new UDP socket.
     *)

    function CreateUDPSocket(out ppUDPSocket: IRMAUDPSocket): HRESULT; stdcall;

    (************************************************************************
     *	Method:
     *	    IRMANetworkServices::CreateListenSocket
     *	Purpose:
     *	    Create a new TCP socket that will listen for connections on a
     *	    particular port.
     *)

    function CreateListenSocket(out ppListenSocket: IRMAListenSocket): HRESULT; stdcall;

    (************************************************************************
     *	Method:
     *	    IRMANetworkServices::CreateResolver
     *	Purpose:
     *	    Create a new resolver that can lookup host names
     *)

    function CreateResolver(out ppResolver: IRMAResolver): HRESULT; stdcall;

  end;
  {$EXTERNALSYM IRMANetworkServices}

(****************************************************************************
 *
 *  Interface:
 *
 *	IRMANetworkServices2
 *
 *  Purpose:
 *
 *	This is a factory interface for the various types of networking
 *	interfaces described above.
 *
 *  IID_IRMANetworkServices:
 *
 *	{17951551-5683-11d3-B6BA-00C0F031C237}
 *
 *)

const
  IID_IRMANetworkServices2: TGUID = '{17951551-5683-11d3-B6BA-00C0F031C237}';
  {$EXTERNALSYM IID_IRMANetworkServices2}

type
  IRMANetworkServices2 = interface (IRMANetworkServices)
  ['{17951551-5683-11d3-B6BA-00C0F031C237}']

    (************************************************************************
     *	Method:
     *	    IRMANetworkServices2::CreateLBoundTCPSocket
     *	Purpose:
     *	    Create a new local bound TCP socket.
     *)

    function CreateLBoundTCPSocket(out ppTCPSocket: IRMATCPSocket): HRESULT; stdcall;
    
  end;
  {$EXTERNALSYM IRMANetworkServices2}

(****************************************************************************
 *
 *  Interface:
 *
 *	IRMAInterruptSafe
 *
 *  Purpose:
 *
 *	This interface is used in Macintosh implementations of callback
 *	functions, renderers, etc... to determine if interrupt time execution
 *	is supported. If this interface is not implemented then it is assumed
 *	that interrupt time execution is NOT supported. There are restrictions
 *	on what may be executed at interrupt time; please consult the Macintosh
 *	Deferred Task Manager tech notes from Apple.
 *
 *  IID_IRMAInterruptSafe:
 *
 *	{0000010B-0901-11d1-8B06-00A024406D59}
 *
 *)

const
  IID_IRMAInterruptSafe: TGUID = '{0000010B-0901-11d1-8B06-00A024406D59}';
  {$EXTERNALSYM IID_IRMAInterruptSafe}

type
  IRMAInterruptSafe = interface (IUnknown)
  ['{0000010B-0901-11d1-8B06-00A024406D59}']

    (************************************************************************
     *	Method:
     *	    IRMAInterruptSafe::IsInterruptSafe
     *	Purpose:
     *	    This is the function that will be called to determine if
     *	    interrupt time execution is supported.
     *)

    function IsInterruptSafe: BOOL; stdcall;

  end;
  {$EXTERNALSYM IRMAInterruptSafe}

(****************************************************************************
 * 
 *  Interface:
 * 
 *	IRMAAsyncIOSelection
 * 
 *  Purpose:
 * 
 *      This interface is implemented by the server/player context on Unix
 *      platforms.  This interface allows your plugin to get callbacks based
 *      I/O events that are normally handled by select().  This interface
 *	allows you to setup callbacks which will be executed when a file
 *	descriptor is ready for reading, writing, or has an exception.
 * 
 *  IID_IRMAAsyncIOSelection:
 * 
 *	{0000010C-0901-11d1-8B06-00A024406D59}
 *
 *)

const
  IID_IRMAAsyncIOSelection: TGUID = '{0000010C-0901-11d1-8B06-00A024406D59}';
  {$EXTERNALSYM IID_IRMAAsyncIOSelection}

type
  IRMAAsyncIOSelection = interface (IUnknown)
  ['{0000010C-0901-11d1-8B06-00A024406D59}']

    (************************************************************************
     *	Method:
     *	    IRMAAsyncIOSelection::Add
     *	Purpose:
     *	    This function will allow you to receive a callback when the
     *	    given descriptor is ready for read, write, or has an
     *	    exception.  This function is only available on Unix, and is
     *	    intended to replace the functionality of select().
     *)

    function Add(pCallback: IRMACallback; lFileDescriptor: INT32; ulType: UINT32): HRESULT; stdcall;

    (************************************************************************
     *	Method:
     *	    IRMAAsyncIOSelection::Remove
     *	Purpose:
     *	    This function will allow you remove the callback associated
     *	    with the given descriptor from the event handler.
     *	    This function is only available on Unix, and is intended to
     *	    replace the functionality of select().
     *)

    function Remove(lFileDescriptor: INT32; ulType: UINT32): HRESULT; stdcall;
    
  end;
  {$EXTERNALSYM IRMAAsyncIOSelection}

(****************************************************************************
 *
 *  Interface:
 *
 *	IRMAUDPMulticastInit
 *
 *  Purpose:
 *
 *	Provides the user with a way to set the TTL for outgoing multicast
 *	UDP packets.  Usually shared with IRMAUDPSocket.
 * 
 *  IID_IRMAUDPMulticastInit:
 * 
 *	{0000010D-0901-11d1-8B06-00A024406D59}
 *
 *)

const
  IID_IRMAUDPMulticastInit: TGUID = '{0000010D-0901-11d1-8B06-00A024406D59}';
  {$EXTERNALSYM IID_IRMAUDPMulticastInit}

type
  IRMAUDPMulticastInit = interface (IUnknown)
  ['{0000010D-0901-11d1-8B06-00A024406D59}']

     (************************************************************************
     *	Method:
     *	    IRMAUDPMulticastInit::InitMulticast
     *	Purpose:
     *	    This function will set the TTL (time to live) for the UDP socket
     *      so it can be used as a multicast socket, sending packets across
     *      the number of routers specified in the ulTTL parameter.
     *)

    function InitMulticast(chTTL: UINT8): HRESULT; stdcall;

  end;
  {$EXTERNALSYM IRMAUDPMulticastInit}

(****************************************************************************
 *
 *  Interface:
 *
 *	IRMAInterruptState
 *
 *  Purpose:
 *
 *	This interface is used in Macintosh implementations to inform the
 *	the client engine when entering & leaving an interupt task. It is
 *	also used to determine if it is currently at interrupt time.
 *	Please consult the Macintosh Deferred Task Manager tech notes from Apple
 *	for information on interrupt tasks.
 *
 *  IID_IRMAInterruptState:
 *
 *	{0000010E-0901-11d1-8B06-00A024406D59}
 *
 *)

const
  IID_IRMAInterruptState: TGUID = '{0000010E-0901-11d1-8B06-00A024406D59}';
  {$EXTERNALSYM IID_IRMAInterruptState}

type
  IRMAInterruptState = interface (IUnknown)
  ['{0000010E-0901-11d1-8B06-00A024406D59}']

    (************************************************************************
     *	Method:
     *	    IRMAInterruptState::AtInterruptTime
     *	Purpose:
     *	    This function is called to determine if we are currently at
     *	    interrupt task time.
     *)

     function AtInterruptTime: BOOL; stdcall;

    (************************************************************************
     *	Method:
     *	    IRMAInterruptState::EnterInterruptState
     *	Purpose:
     *	    This function is called when starting a deferred/interrupt task
     *)

    function EnterInterruptState: HRESULT; stdcall;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -